| | |
| | | #include "../defs.h" |
| | | #include "../jni_log.h" |
| | | #include "../common/serial_port.h" |
| | | #include "../rtk_platform/platform.h" |
| | | |
| | | #define DEBUG(fmt, args...) LOGD("<mcu_if> <%s>: " fmt, __func__, ##args) |
| | | |
| | |
| | | static int dfuTryCnt = 0; |
| | | const int DFU_MAX_TRY = 3; |
| | | const int DFU_FILE_BLOCK_SIZE = 896; |
| | | |
| | | |
| | | static void *UartThread1(void *p); |
| | | static void ParseMcuTimeout(union sigval sig); |
| | |
| | | break; |
| | | case ID_MC_CAR_INFO: { |
| | | DEBUG("ID_MC_CAR_INFO %d", lenth); |
| | | char ver[64] = {0}; |
| | | |
| | | memcpy(ver, data, 32); |
| | | |
| | | DEBUG("ID_MC_CAR_INFO %s", ver); |
| | | |
| | | if (lenth > 0) |
| | | PlatformStatusChanged(MCU_UPDATE_EVT, data, lenth); |
| | | break; |
| | | } |
| | | case ID_MC_RTK_DATA: |