|
@@ -26,7 +26,9 @@ object SerialPortUtils {
|
|
|
val serialPort =
|
|
|
SerialPort(File(serialPortPath), baudRate, dataBits, parity, stopBits, flags)
|
|
|
val dev2McuEventListener = Dev2McuEventListener { event: Dev2McuDataEvent ->
|
|
|
- Log.i("dev2mcu:", event.data)
|
|
|
+ if(!event.data.startsWith("7E07")){
|
|
|
+ Log.i("dev2mcu:", event.data)
|
|
|
+ }
|
|
|
val data = Converter.hexStringToBytes(event.data)
|
|
|
try {
|
|
|
serialPort.outputStream.write(data)
|