Added board command to host protocol

This commit is contained in:
Mark Qvist 2022-01-22 22:34:03 +01:00
parent c4f7767b4f
commit 9bb6d34ef4
4 changed files with 14 additions and 4 deletions

View File

@ -4,7 +4,7 @@
#define CONFIG_H #define CONFIG_H
#define MAJ_VERS 0x01 #define MAJ_VERS 0x01
#define MIN_VERS 0x19 #define MIN_VERS 0x20
#define PLATFORM_AVR 0x90 #define PLATFORM_AVR 0x90
#define PLATFORM_ESP32 0x80 #define PLATFORM_ESP32 0x80

View File

@ -27,6 +27,7 @@
#define CMD_BLINK 0x30 #define CMD_BLINK 0x30
#define CMD_RANDOM 0x40 #define CMD_RANDOM 0x40
#define CMD_BOARD 0x47
#define CMD_PLATFORM 0x48 #define CMD_PLATFORM 0x48
#define CMD_MCU 0x49 #define CMD_MCU 0x49
#define CMD_FW_VERSION 0x50 #define CMD_FW_VERSION 0x50

View File

@ -615,6 +615,8 @@ void serialCallback(uint8_t sbyte) {
kiss_indicate_platform(); kiss_indicate_platform();
} else if (command == CMD_MCU) { } else if (command == CMD_MCU) {
kiss_indicate_mcu(); kiss_indicate_mcu();
} else if (command == CMD_BOARD) {
kiss_indicate_board();
} else if (command == CMD_CONF_SAVE) { } else if (command == CMD_CONF_SAVE) {
eeprom_conf_save(); eeprom_conf_save();
} else if (command == CMD_CONF_DELETE) { } else if (command == CMD_CONF_DELETE) {

View File

@ -429,6 +429,13 @@ void kiss_indicate_platform() {
Serial.write(FEND); Serial.write(FEND);
} }
void kiss_indicate_board() {
Serial.write(FEND);
Serial.write(CMD_BOARD);
Serial.write(BOARD_MODEL);
Serial.write(FEND);
}
void kiss_indicate_mcu() { void kiss_indicate_mcu() {
Serial.write(FEND); Serial.write(FEND);
Serial.write(CMD_MCU); Serial.write(CMD_MCU);