润和联网
This commit is contained in:
parent
5d075743ae
commit
0820ac658c
BIN
entry/src/.DS_Store
vendored
Normal file
BIN
entry/src/.DS_Store
vendored
Normal file
Binary file not shown.
BIN
entry/src/main/.DS_Store
vendored
Normal file
BIN
entry/src/main/.DS_Store
vendored
Normal file
Binary file not shown.
@ -16,7 +16,7 @@ import promptAction from '@ohos.promptAction';
|
|||||||
import errorMsgDialog from './compontents/errorMsgDialog';
|
import errorMsgDialog from './compontents/errorMsgDialog';
|
||||||
import GetDistance from '../common/utils/GetDistance';
|
import GetDistance from '../common/utils/GetDistance';
|
||||||
import UdpEvent from '../common/utils/UdpEvent';
|
import UdpEvent from '../common/utils/UdpEvent';
|
||||||
import { delPic } from '../common/service/videoService';
|
// import { delPic } from '../common/service/videoService';
|
||||||
import imageBtn from './compontents/imageBtn';
|
import imageBtn from './compontents/imageBtn';
|
||||||
import VoiceAnnounce from './judgeSDK/utils/voiceAnnouncements';
|
import VoiceAnnounce from './judgeSDK/utils/voiceAnnouncements';
|
||||||
|
|
||||||
@ -395,8 +395,8 @@ struct Index {
|
|||||||
console.log('syssyssyssys')
|
console.log('syssyssyssys')
|
||||||
// this.delLoading=true
|
// this.delLoading=true
|
||||||
// globalThis.param854Str=sys.v_value
|
// globalThis.param854Str=sys.v_value
|
||||||
delPic(Number(sys.v_value), 1)
|
// delPic(Number(sys.v_value), 1)
|
||||||
delPic(Number(sys.v_value), 2)
|
// delPic(Number(sys.v_value), 2)
|
||||||
// this.delLoading=false
|
// this.delLoading=false
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -618,12 +618,12 @@ struct Index {
|
|||||||
getTCP()
|
getTCP()
|
||||||
this.deviceId = globalThis.carInfo.carNo
|
this.deviceId = globalThis.carInfo.carNo
|
||||||
await setCurrentTime();
|
await setCurrentTime();
|
||||||
if (!globalThis.distanceClass) {
|
// if (!globalThis.distanceClass) {
|
||||||
const distanceClass = new GetDistance(globalThis.context)
|
// const distanceClass = new GetDistance(globalThis.context)
|
||||||
await distanceClass.initFolder()
|
// await distanceClass.initFolder()
|
||||||
globalThis.distanceClass = distanceClass
|
// globalThis.distanceClass = distanceClass
|
||||||
console.info('surenjun', 'distanceClass=>初始化完成')
|
// console.info('surenjun', 'distanceClass=>初始化完成')
|
||||||
}
|
// }
|
||||||
this.carNum = globalThis.carInfo.plateNo;
|
this.carNum = globalThis.carInfo.plateNo;
|
||||||
this.version = globalThis.version;
|
this.version = globalThis.version;
|
||||||
this.hasAuth = globalThis.hasAuth;
|
this.hasAuth = globalThis.hasAuth;
|
||||||
|
|||||||
@ -542,7 +542,7 @@ struct Index {
|
|||||||
globalThis.carInfo.examSubject = this.examSubject
|
globalThis.carInfo.examSubject = this.examSubject
|
||||||
this.singlePlay = beginDataObj.exam == 0;
|
this.singlePlay = beginDataObj.exam == 0;
|
||||||
this.carName = initDataObj.name;
|
this.carName = initDataObj.name;
|
||||||
globalThis.singlePlay = beginDataObj.exam == 0;
|
// globalThis.singlePlay = beginDataObj.exam == 0;
|
||||||
await this.initSystemParam(initDataObj.systemparm)
|
await this.initSystemParam(initDataObj.systemparm)
|
||||||
await this.initMarkRules(initDataObj.mark);
|
await this.initMarkRules(initDataObj.mark);
|
||||||
await this.initSysset(initDataObj.sysset);
|
await this.initSysset(initDataObj.sysset);
|
||||||
|
|||||||
@ -1,6 +1,7 @@
|
|||||||
import { GPSData, SignalData } from '../mock';
|
import { GPSData, SignalData } from '../mock';
|
||||||
import { SignalDataType } from '../model';
|
import { SignalDataType } from '../model';
|
||||||
import signDisplayCom from './compontents/signDisplayCom';
|
import signDisplayCom from './compontents/signDisplayCom';
|
||||||
|
import TopLogo from './compontents/TopLogo';
|
||||||
|
|
||||||
@Entry
|
@Entry
|
||||||
@Component
|
@Component
|
||||||
@ -18,6 +19,7 @@ export default struct Index {
|
|||||||
// @State gpsList: Array<any> = []
|
// @State gpsList: Array<any> = []
|
||||||
build() {
|
build() {
|
||||||
Column() {
|
Column() {
|
||||||
|
TopLogo({ outFlag: $outFlag }).margin({ bottom: 25.5 * this.ratio })
|
||||||
signDisplayCom({
|
signDisplayCom({
|
||||||
showBack: true
|
showBack: true
|
||||||
})
|
})
|
||||||
|
|||||||
@ -37,7 +37,7 @@ export default struct SignDisplayCom {
|
|||||||
Column() {
|
Column() {
|
||||||
Flex({ justifyContent: FlexAlign.SpaceBetween }) {
|
Flex({ justifyContent: FlexAlign.SpaceBetween }) {
|
||||||
Row() {
|
Row() {
|
||||||
Image($r('app.media.signal_logoS')).width(30 * this.ratio).height(24 * this.ratio)
|
// Image($r('app.media.signal_logoS')).width(30 * this.ratio).height(24 * this.ratio)
|
||||||
Row() {
|
Row() {
|
||||||
Text('PLC信号').fontColor(this.active == 0 ? '#FFAD33' : '#e7cba3').fontSize(20 * this.ratio)
|
Text('PLC信号').fontColor(this.active == 0 ? '#FFAD33' : '#e7cba3').fontSize(20 * this.ratio)
|
||||||
}
|
}
|
||||||
@ -51,7 +51,7 @@ export default struct SignDisplayCom {
|
|||||||
|
|
||||||
})
|
})
|
||||||
|
|
||||||
if (this.showTrajectory) {
|
if (this.showTrajectory||true) {
|
||||||
Row() {
|
Row() {
|
||||||
Text('实时轨迹').fontColor(this.active == 1 ? '#FFAD33' : '#e7cba3').fontSize(20 * this.ratio)
|
Text('实时轨迹').fontColor(this.active == 1 ? '#FFAD33' : '#e7cba3').fontSize(20 * this.ratio)
|
||||||
}
|
}
|
||||||
@ -82,20 +82,20 @@ export default struct SignDisplayCom {
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
Row() {
|
// Row() {
|
||||||
if (this.showBack) {
|
// if (this.showBack) {
|
||||||
Image($r('app.media.topB_back')).height('12.2%')
|
// Image($r('app.media.topB_back')).height('12.2%')
|
||||||
.onClick(() => {
|
// .onClick(() => {
|
||||||
router.back()
|
// router.back()
|
||||||
// this.url='back'
|
// // this.url='back'
|
||||||
// this.vocObj.playAudio({
|
// // this.vocObj.playAudio({
|
||||||
// type: 1,
|
// // type: 1,
|
||||||
// name: 'media_button.wav'
|
// // name: 'media_button.wav'
|
||||||
// })
|
// // })
|
||||||
this.outFlag = true
|
// this.outFlag = true
|
||||||
})
|
// })
|
||||||
}
|
// }
|
||||||
}
|
// }
|
||||||
}.width(936 * this.ratio)
|
}.width(936 * this.ratio)
|
||||||
|
|
||||||
Column() {
|
Column() {
|
||||||
|
|||||||
@ -78,6 +78,7 @@ export default struct RealTime {
|
|||||||
.height(this.heightNumber)
|
.height(this.heightNumber)
|
||||||
.onLoad(() => {
|
.onLoad(() => {
|
||||||
libJudgeSdk.examJudgeMapSetDrawing(true); //停止绘制地图轨迹,false:表示结束绘制
|
libJudgeSdk.examJudgeMapSetDrawing(true); //停止绘制地图轨迹,false:表示结束绘制
|
||||||
|
|
||||||
})
|
})
|
||||||
.onDestroy(() => {
|
.onDestroy(() => {
|
||||||
libJudgeSdk.examJudgeMapSetDrawing(false); //停止绘制地图轨迹,false:表示结束绘制
|
libJudgeSdk.examJudgeMapSetDrawing(false); //停止绘制地图轨迹,false:表示结束绘制
|
||||||
|
|||||||
@ -64,7 +64,11 @@ export async function examJudgeSetRealExamCallback(fn){
|
|||||||
* @desc 设置轨迹图像回调函数
|
* @desc 设置轨迹图像回调函数
|
||||||
*/
|
*/
|
||||||
export async function examJudgeMapImageSetCallback(fn){
|
export async function examJudgeMapImageSetCallback(fn){
|
||||||
|
console.log('examJudgeMapexamJudgeMapImageSetCallbackStart')
|
||||||
|
|
||||||
const temp = libJudgeSdk.examJudgeMapImageSetCallback(fn);
|
const temp = libJudgeSdk.examJudgeMapImageSetCallback(fn);
|
||||||
|
console.log('examJudgeMapexamJudgeMapImageSetCallbackEnd')
|
||||||
|
|
||||||
return await handle(temp,'examJudgeMapImageSetCallback')
|
return await handle(temp,'examJudgeMapImageSetCallback')
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -105,7 +109,10 @@ export async function examJudgeArtificialItem(
|
|||||||
* @desc 设置地图轨迹图像绘制的开关
|
* @desc 设置地图轨迹图像绘制的开关
|
||||||
*/
|
*/
|
||||||
export async function examJudgeMapSetDrawing(fn){
|
export async function examJudgeMapSetDrawing(fn){
|
||||||
|
console.log('examJudgeMapexamJudgeMapSetDrawingStart')
|
||||||
const temp = libJudgeSdk.examJudgeMapSetDrawing(fn);
|
const temp = libJudgeSdk.examJudgeMapSetDrawing(fn);
|
||||||
|
console.log('examJudgeMapexamJudgeMapSetDrawingEnd')
|
||||||
|
|
||||||
return await handle(temp,'examJudgeMapSetDrawing')
|
return await handle(temp,'examJudgeMapSetDrawing')
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -151,7 +158,11 @@ export async function examJudgeDestroy(){
|
|||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
export async function examJudgeMapSetParam(width:number,height:number){
|
export async function examJudgeMapSetParam(width:number,height:number){
|
||||||
|
console.log('examJudgeMapSetstart')
|
||||||
|
|
||||||
const temp = libJudgeSdk.examJudgeMapSetParam(width,height );
|
const temp = libJudgeSdk.examJudgeMapSetParam(width,height );
|
||||||
|
console.log('examJudgeMapSetEnd')
|
||||||
|
|
||||||
return await handle(temp,'examJudgeMapSetParam')
|
return await handle(temp,'examJudgeMapSetParam')
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -160,7 +171,10 @@ export async function examJudgeMapSetParam(width:number,height:number){
|
|||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
export async function examJudgeMapSetScaling(scaling?:number){
|
export async function examJudgeMapSetScaling(scaling?:number){
|
||||||
|
console.log('examJudgeMapscanl')
|
||||||
const temp = libJudgeSdk.examJudgeMapSetScaling(scaling || 1);
|
const temp = libJudgeSdk.examJudgeMapSetScaling(scaling || 1);
|
||||||
|
console.log('examJudgeMapscanlend')
|
||||||
|
|
||||||
return await handle(temp,'examJudgeMapSetScaling')
|
return await handle(temp,'examJudgeMapSetScaling')
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -151,6 +151,7 @@ export default class Judge {
|
|||||||
}
|
}
|
||||||
//获取科目三的评判初始化配置
|
//获取科目三的评判初始化配置
|
||||||
getKm3JudgeInitConfig = async () => {
|
getKm3JudgeInitConfig = async () => {
|
||||||
|
console.log('modelsmodels00')
|
||||||
const {judgeUI,getModelData} = this;
|
const {judgeUI,getModelData} = this;
|
||||||
const {mapPointArr,mapPointItemArr} = judgeUI;
|
const {mapPointArr,mapPointItemArr} = judgeUI;
|
||||||
return {
|
return {
|
||||||
@ -702,6 +703,7 @@ export default class Judge {
|
|||||||
|
|
||||||
// 获取评判初始化数据
|
// 获取评判初始化数据
|
||||||
getJudgeInitData = async () => {
|
getJudgeInitData = async () => {
|
||||||
|
console.log('modelsmodels0000')
|
||||||
const {getModelData,getKm3JudgeInitConfig} = this
|
const {getModelData,getKm3JudgeInitConfig} = this
|
||||||
const carInfo = globalThis.carInfo;
|
const carInfo = globalThis.carInfo;
|
||||||
const { examSubject,plateNo,carId } = carInfo;
|
const { examSubject,plateNo,carId } = carInfo;
|
||||||
@ -721,6 +723,8 @@ export default class Judge {
|
|||||||
}
|
}
|
||||||
//获取版本号
|
//获取版本号
|
||||||
const sdkver = await examJudgeVersion();
|
const sdkver = await examJudgeVersion();
|
||||||
|
console.info(judgeTag, '3.1获取评判初始化数据完成')
|
||||||
|
|
||||||
const initInfo = {
|
const initInfo = {
|
||||||
sdkver,
|
sdkver,
|
||||||
appver: globalThis.version,
|
appver: globalThis.version,
|
||||||
@ -1640,8 +1644,10 @@ export default class Judge {
|
|||||||
|
|
||||||
// 获取模型数据
|
// 获取模型数据
|
||||||
getModelData = (modelName) => {
|
getModelData = (modelName) => {
|
||||||
|
console.log('modelsmodels0')
|
||||||
const modelPath = this.modelPath
|
const modelPath = this.modelPath
|
||||||
const fileModel = this.fileModel;
|
const fileModel = this.fileModel;
|
||||||
|
console.log('modelsmodels',modelPath,fileModel)
|
||||||
const modelData = fileModel.getModelContent(modelPath, modelName);
|
const modelData = fileModel.getModelContent(modelPath, modelName);
|
||||||
return modelData
|
return modelData
|
||||||
}
|
}
|
||||||
@ -1742,12 +1748,13 @@ export default class Judge {
|
|||||||
let strArr = [];
|
let strArr = [];
|
||||||
if (isTrajectoryOpen) {
|
if (isTrajectoryOpen) {
|
||||||
const folderPath = await this.fileUtil.initFolder(trajectoryPath);
|
const folderPath = await this.fileUtil.initFolder(trajectoryPath);
|
||||||
|
console.log('surenjun','folderPath',folderPath)
|
||||||
const str = await fileUtil.readFile(folderPath)
|
const str = await fileUtil.readFile(folderPath)
|
||||||
strArr = str.split('\n')
|
strArr = str.split('\n')
|
||||||
}
|
}
|
||||||
//日志回调
|
//日志回调
|
||||||
console.info(judgeTag, '1.进入评判入口')
|
console.info(judgeTag, '1.进入评判入口')
|
||||||
await examJudgeSetLogCallback(3, async (level, info, len) => {
|
await examJudgeSetLogCallback(6, async (level, info, len) => {
|
||||||
console.log('评判日志:' + info)
|
console.log('评判日志:' + info)
|
||||||
await fileLog.setExamJudgeLogData(info);
|
await fileLog.setExamJudgeLogData(info);
|
||||||
})
|
})
|
||||||
@ -1812,6 +1819,7 @@ export default class Judge {
|
|||||||
// }
|
// }
|
||||||
|
|
||||||
this.judgeUI.draw = true
|
this.judgeUI.draw = true
|
||||||
|
|
||||||
// 处理轨迹plc信息
|
// 处理轨迹plc信息
|
||||||
if (isTrajectoryOpen) {
|
if (isTrajectoryOpen) {
|
||||||
handleTrajectoryUdp(strArr);
|
handleTrajectoryUdp(strArr);
|
||||||
|
|||||||
@ -22,6 +22,7 @@ export default class FileModel{
|
|||||||
const {fileUtil} = this
|
const {fileUtil} = this
|
||||||
await fileUtil.initFolder(`/models/model_enc`);
|
await fileUtil.initFolder(`/models/model_enc`);
|
||||||
const folderPath = await fileUtil.initFolder(`/models`);
|
const folderPath = await fileUtil.initFolder(`/models`);
|
||||||
|
console.log('surenjun','modelsmodels',folderPath)
|
||||||
this.folderPath = folderPath;
|
this.folderPath = folderPath;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -1,21 +1,21 @@
|
|||||||
//考试回放开关
|
//考试回放开关
|
||||||
export const judgeConfig = {
|
export const judgeConfig = {
|
||||||
//本地目录开关
|
//本地目录开关
|
||||||
isTrajectoryOpen: false,
|
isTrajectoryOpen: true,
|
||||||
//是否开启拍照
|
//是否开启拍照
|
||||||
isPhotoOpen: true,
|
isPhotoOpen: false,
|
||||||
//扣分语音是否强制开启
|
//扣分语音是否强制开启
|
||||||
kfVoiceOpen: false,
|
kfVoiceOpen: false,
|
||||||
//忽略的考试项目
|
//忽略的考试项目
|
||||||
ignoreProjects:[],
|
ignoreProjects:[],
|
||||||
// 是否忽略考试前熄火、车门检查
|
// 是否忽略考试前熄火、车门检查
|
||||||
isCheckFireOpen: false,
|
isCheckFireOpen: true,
|
||||||
//轨迹回放是否开启Udp
|
//轨迹回放是否开启Udp
|
||||||
udpOpen:true,
|
udpOpen:true,
|
||||||
// 本地模型地址
|
// 本地模型地址
|
||||||
modelPath: 'models/model_enc',
|
modelPath: 'models/model_enc',
|
||||||
// 济南科目三
|
// 济南科目三
|
||||||
trajectoryPath: 'logs/2024_12_26/2024_12_26_14_12_51_2412505941910_370125200404041910_赵宇/judge_exam_data.txt',
|
trajectoryPath: 'logs/2024_10_12/2024_10_12_11_50_10_9999427676823_744299437502336256_隋统/judge_exam_data.txt',
|
||||||
//四合一画面配置
|
//四合一画面配置
|
||||||
fourInOneScreen:{
|
fourInOneScreen:{
|
||||||
//gps位数
|
//gps位数
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user