Update V911S_ccnrf.ino to add 6G/Senior and light for XK A280 (#929)

This commit is contained in:
rdba2k 2024-01-18 03:07:34 -08:00 committed by GitHub
parent 8c2fe5f65e
commit 8e663f2531
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -35,6 +35,8 @@
// flags going to packet[2] // flags going to packet[2]
#define V911S_FLAG_CALIB 0x01 #define V911S_FLAG_CALIB 0x01
#define A220_FLAG_6G3D 0x04 #define A220_FLAG_6G3D 0x04
#define A280_FLAG_6GSENIOR 0x08
#define A280_FLAG_LIGHT 0x20
static void __attribute__((unused)) V911S_send_packet() static void __attribute__((unused)) V911S_send_packet()
{ {
@ -74,7 +76,9 @@ static void __attribute__((unused)) V911S_send_packet()
{ {
packet[ 1]=GET_FLAG(!CH6_SW,E119_FLAG_EXPERT) // short press on left button packet[ 1]=GET_FLAG(!CH6_SW,E119_FLAG_EXPERT) // short press on left button
|GET_FLAG( CH5_SW,E119_FLAG_CALIB); // short press on right button |GET_FLAG( CH5_SW,E119_FLAG_CALIB); // short press on right button
packet[ 2]=GET_FLAG( CH7_SW,A220_FLAG_6G3D); // short press on right button packet[ 2]=GET_FLAG( CH7_SW,A220_FLAG_6G3D) // short press on right button
|GET_FLAG( CH8_SW,A280_FLAG_6GSENIOR) // -100% - 6G, +100% - Senior mode (turn off gyro)
|GET_FLAG( CH9_SW,A280_FLAG_LIGHT); // cycle the light through on-flash-off when the CH9 value is changed from -100% to 100%
} }
//packet[3..6]=trims TAER signed //packet[3..6]=trims TAER signed