Skip to content

Commit 4b10692

Browse files
authored
Update MT99xx_ccnrf.ino
Add SU35 protocol Pls add in the web page https://github.com/pascallanger/DIY-Multiprotocol-TX-Module/blob/master/Protocols_Details.md#MT99XX2---92 Sub_protocol SU35 Model: QF009 Su35, CH5 - mode -100% = 6G 100% = 3D, CH6 - LED, CH7 - LED Flash, CH8 - Invert, CH9 - Rate
1 parent af12b21 commit 4b10692

File tree

1 file changed

+19
-1
lines changed

1 file changed

+19
-1
lines changed

Multiprotocol/MT99xx_ccnrf.ino

+19-1
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
You should have received a copy of the GNU General Public License
1313
along with Multiprotocol. If not, see <http://www.gnu.org/licenses/>.
1414
*/
15-
// compatible with MT99xx, Eachine H7, Yi Zhan i6S and LS114/124
15+
// compatible with MT99xx, Eachine H7, Yi Zhan i6S, LS114/124, QF009 Su35
1616
// Last sync with Goebish mt99xx_nrf24l01.c dated 2016-01-29
1717

1818
#if defined(MT99XX_CCNRF_INO)
@@ -96,6 +96,16 @@ enum{
9696
FLAG_PA18_FLIP = 0x80,
9797
};
9898

99+
enum{
100+
// flags going to packet[6] (QF009 Su35)
101+
FLAG_SU35_6G = 0x00,
102+
FLAG_SU35_3D = 0x40,
103+
FLAG_SU35_HIRATE = 0x01,
104+
FLAG_SU35_LED = 0x02,
105+
FLAG_SU35_FLASH = 0x04,
106+
FLAG_SU35_INVERT = 0x08,
107+
};
108+
99109
const uint8_t h7_mys_byte[] = {
100110
0x01, 0x11, 0x02, 0x12, 0x03, 0x13, 0x04, 0x14,
101111
0x05, 0x15, 0x06, 0x16, 0x07, 0x17, 0x00, 0x10
@@ -271,6 +281,14 @@ static void __attribute__((unused)) MT99XX_send_packet()
271281
if(hopping_frequency_no == 0)
272282
packet[7] ^= 0x40;
273283
break;
284+
case SU35+8:
285+
packet[6] = FLAG_SU35_6G
286+
| GET_FLAG( CH5_SW, FLAG_SU35_3D )
287+
| GET_FLAG( !CH6_SW, FLAG_SU35_LED )
288+
| GET_FLAG( CH7_SW, FLAG_SU35_FLASH )
289+
| GET_FLAG( CH8_SW, FLAG_SU35_INVERT )
290+
| GET_FLAG( CH9_SW, FLAG_SU35_HIRATE );
291+
break;
274292
}
275293
uint8_t result=crc8;
276294
for(uint8_t i=0; i<8; i++)

0 commit comments

Comments
 (0)