3 #define MSP_ELRS_FUNC 0x4578 // ['E','x']
5 #define MSP_SET_RX_CONFIG 45
6 #define MSP_VTX_CONFIG 88 //out message Get vtx settings - betaflight
7 #define MSP_SET_VTX_CONFIG 89 //in message Set vtx settings - betaflight
9 #define MSP_VTXTABLE_BAND 137 //out message vtxTable band/channel data
10 #define MSP_SET_VTXTABLE_BAND 227 //in message set vtxTable band/channel data (one band at a time)
12 #define MSP_VTXTABLE_POWERLEVEL 138 //out message vtxTable powerLevel data
13 #define MSP_SET_VTXTABLE_POWERLEVEL 228 //in message set vtxTable powerLevel data (one powerLevel at a time)
15 #define MSP_EEPROM_WRITE 250 //in message no param
17 // ELRS specific opcodes
18 #define MSP_ELRS_RF_MODE 0x06 // NOTIMPL
19 #define MSP_ELRS_TX_PWR 0x07 // NOTIMPL
20 #define MSP_ELRS_TLM_RATE 0x08 // NOTIMPL
21 #define MSP_ELRS_BIND 0x09
22 #define MSP_ELRS_MODEL_ID 0x0A
23 #define MSP_ELRS_REQU_VTX_PKT 0x0B
24 #define MSP_ELRS_SET_TX_BACKPACK_WIFI_MODE 0x0C
25 #define MSP_ELRS_SET_VRX_BACKPACK_WIFI_MODE 0x0D
26 #define MSP_ELRS_SET_RX_WIFI_MODE 0x0E
27 #define MSP_ELRS_SET_RX_LOAN_MODE 0x0F
28 #define MSP_ELRS_GET_BACKPACK_VERSION 0x10
30 #define MSP_ELRS_POWER_CALI_GET 0x20
31 #define MSP_ELRS_POWER_CALI_SET 0x21
33 // CRSF encapsulated msp defines
34 #define ENCAPSULATED_MSP_HEADER_CRC_LEN 4
35 #define ENCAPSULATED_MSP_MAX_PAYLOAD_SIZE 4
36 #define ENCAPSULATED_MSP_MAX_FRAME_LEN (ENCAPSULATED_MSP_HEADER_CRC_LEN + ENCAPSULATED_MSP_MAX_PAYLOAD_SIZE)
38 // ELRS backpack protocol opcodes
39 // See: https://docs.google.com/document/d/1u3c7OTiO4sFL2snI-hIo-uRSLfgBK4h16UrbA08Pd6U/edit#heading=h.1xw7en7jmvsj
40 #define MSP_ELRS_BACKPACK_GET_CHANNEL_INDEX 0x0300
41 #define MSP_ELRS_BACKPACK_SET_CHANNEL_INDEX 0x0301
42 #define MSP_ELRS_BACKPACK_GET_FREQUENCY 0x0302
43 #define MSP_ELRS_BACKPACK_SET_FREQUENCY 0x0303
44 #define MSP_ELRS_BACKPACK_GET_RECORDING_STATE 0x0304
45 #define MSP_ELRS_BACKPACK_SET_RECORDING_STATE 0x0305
46 #define MSP_ELRS_BACKPACK_GET_VRX_MODE 0x0306
47 #define MSP_ELRS_BACKPACK_SET_VRX_MODE 0x0307
48 #define MSP_ELRS_BACKPACK_GET_RSSI 0x0308
49 #define MSP_ELRS_BACKPACK_GET_BATTERY_VOLTAGE 0x0309
50 #define MSP_ELRS_BACKPACK_GET_FIRMWARE 0x030A
51 #define MSP_ELRS_BACKPACK_SET_BUZZER 0x030B
52 #define MSP_ELRS_BACKPACK_SET_OSD_ELEMENT 0x030C
53 #define MSP_ELRS_BACKPACK_SET_HEAD_TRACKING 0x030D
55 #define MSP_ELRS_BACKPACK_SET_PTR 0x0383