| | |
| | | |
| | | tempQs.clear() |
| | | val list = WorkRoomDataBase.getWorkRoomDataBase(applicationContext).lightUseQuestionsDao.lightUseQuestionsNoLive() |
| | | val listQuests=WorkRoomDataBase.getWorkRoomDataBase(applicationContext).lightAllQuestionsDao.allLightQuestions |
| | | Log.i("AYJiaKao",list.size.toString()) |
| | | tempQs.add(QuestionBean(100, "下面将进行模拟夜间行驶场景灯光使用的考试,请按语音指令在5秒内做出相应的灯光操作"))//提示下面将进行灯光考试 |
| | | |
| | | if (list.size>5){ |
| | | var questbean = QuestionBean(list[0].id,list[0].question) |
| | | questbean.parseSolutionAndProcess(list[0].answer) |
| | | questbean.wrong_code = listQuests[list[0].id].wrong_code |
| | | tempQs.add(questbean) |
| | | val a = Utils.getRandomInts(4, list.size) |
| | | for (i in a.indices) { |
| | |
| | | Log.i("AYJiaKao",te.toString()) |
| | | var questbean = QuestionBean(te.id,te.question) |
| | | questbean.parseSolutionAndProcess(te.answer) |
| | | questbean.wrong_code = listQuests[te.id].wrong_code |
| | | tempQs.add(questbean) |
| | | |
| | | } |
| | |
| | | |
| | | var questbean = QuestionBean(list[i].id,list[i].question) |
| | | questbean.parseSolutionAndProcess(list[i].answer) |
| | | questbean.wrong_code = listQuests[i].wrong_code |
| | | tempQs.add(questbean) |
| | | } |
| | | } |
| | |
| | | |
| | | MyLog.i("开始发送灯光,考试项共有"+simulateNightBean.question.size) |
| | | MyLog.i("开始发送灯光,gson="+gson.toJson(simulateNightBean)) |
| | | // AYSdk.getInstance().sendCmd(0x8012, gson.toJson(simulateNightBean)) |
| | | AYSdk.getInstance().sendCmd(0x8012, gson.toJson(simulateNightBean)) |
| | | |
| | | //发送考试状态 |
| | | MyLog.i("查到的考试type=$examType") |