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 // REMOVED
28 #define MSP_ELRS_GET_BACKPACK_VERSION 0x10
29 #define MSP_ELRS_BACKPACK_CRSF_TLM 0x11
31 #define MSP_ELRS_POWER_CALI_GET 0x20
32 #define MSP_ELRS_POWER_CALI_SET 0x21
34 #define MSP_ELRS_MAVLINK_TLM 0xFD
36 #define MSP_ELRS_BACKPACK_CONFIG 0x30
37 #define MSP_ELRS_BACKPACK_CONFIG_TLM_MODE 0x31
39 // CRSF encapsulated msp defines
40 #define ENCAPSULATED_MSP_HEADER_CRC_LEN 4
41 #define ENCAPSULATED_MSP_MAX_PAYLOAD_SIZE 4
42 #define ENCAPSULATED_MSP_MAX_FRAME_LEN (ENCAPSULATED_MSP_HEADER_CRC_LEN + ENCAPSULATED_MSP_MAX_PAYLOAD_SIZE)
44 // ELRS backpack protocol opcodes
45 // See: https://docs.google.com/document/d/1u3c7OTiO4sFL2snI-hIo-uRSLfgBK4h16UrbA08Pd6U/edit#heading=h.1xw7en7jmvsj
46 #define MSP_ELRS_BACKPACK_GET_CHANNEL_INDEX 0x0300
47 #define MSP_ELRS_BACKPACK_SET_CHANNEL_INDEX 0x0301
48 #define MSP_ELRS_BACKPACK_GET_FREQUENCY 0x0302
49 #define MSP_ELRS_BACKPACK_SET_FREQUENCY 0x0303
50 #define MSP_ELRS_BACKPACK_GET_RECORDING_STATE 0x0304
51 #define MSP_ELRS_BACKPACK_SET_RECORDING_STATE 0x0305
52 #define MSP_ELRS_BACKPACK_GET_VRX_MODE 0x0306
53 #define MSP_ELRS_BACKPACK_SET_VRX_MODE 0x0307
54 #define MSP_ELRS_BACKPACK_GET_RSSI 0x0308
55 #define MSP_ELRS_BACKPACK_GET_BATTERY_VOLTAGE 0x0309
56 #define MSP_ELRS_BACKPACK_GET_FIRMWARE 0x030A
57 #define MSP_ELRS_BACKPACK_SET_BUZZER 0x030B
58 #define MSP_ELRS_BACKPACK_SET_OSD_ELEMENT 0x030C
59 #define MSP_ELRS_BACKPACK_SET_HEAD_TRACKING 0x030D
61 #define MSP_ELRS_BACKPACK_SET_PTR 0x0383