diff --git a/Multiprotocol/REALACC_nrf24l01.ino b/Multiprotocol/REALACC_nrf24l01.ino index 305980f..4209071 100644 --- a/Multiprotocol/REALACC_nrf24l01.ino +++ b/Multiprotocol/REALACC_nrf24l01.ino @@ -46,7 +46,7 @@ static void __attribute__((unused)) REALACC_send_packet() packet[11]= 0x00 // Flag2 | GET_FLAG(CH7_SW, 0x01) // Calib | GET_FLAG(CH9_SW, 0x20) // Return - | GET_FLAG(CH10_SW,0x80); // Unknown + | GET_FLAG(CH10_SW,0x80); // Throttle cut packet[12]= 0x00 // Flag3 | GET_FLAG(CH5_SW, 0x01) // Flip | GET_FLAG(CH11_SW,0x02) // Rotating diff --git a/Multiprotocol/TRAXXAS_cyrf6936.ino b/Multiprotocol/TRAXXAS_cyrf6936.ino index 3f1fb69..04eade7 100644 --- a/Multiprotocol/TRAXXAS_cyrf6936.ino +++ b/Multiprotocol/TRAXXAS_cyrf6936.ino @@ -87,22 +87,15 @@ static void __attribute__((unused)) TRAXXAS_send_data_packet() memset(&packet[1],0x00,TRAXXAS_PACKET_SIZE-1); //Next RF channel ? 0x00 -> keep current, 0x0E change to F=15 //packet[1] = hopping_frequency[0] - 1; - //Steering - uint16_t ch = convert_channel_16b_nolimit(RUDDER,500,1000,false); - packet[2]=ch>>8; - packet[3]=ch; - //Throttle - ch = convert_channel_16b_nolimit(THROTTLE,500,1000,false); - packet[4]=ch>>8; - packet[5]=ch; - //AUX3 - ch = convert_channel_16b_nolimit(AILERON,500,1000,false); - packet[6]=ch>>8; - packet[7]=ch; - //AUX4??? - ch = convert_channel_16b_nolimit(ELEVATOR,500,1000,false); - packet[12]=ch>>8; - packet[13]=ch; + + //6 channels + uint16_t ch; + for(uint8_t i=0; i<6; i++) + { + ch = convert_channel_16b_nolimit(i,500,1000,false); + packet[2+i*2]=ch>>8; + packet[3+i*2]=ch; + } CYRF_SetPower(0x08); CYRF_WriteDataPacketLen(packet, TRAXXAS_PACKET_SIZE);