mirror of
https://github.com/pascallanger/DIY-Multiprotocol-TX-Module.git
synced 2025-12-18 22:54:44 +00:00
Core and all protocols have been updated
Lot of changes in this new master ChangeLog: - Core: LED flashing when an invalid protocol has been selected - Core: Channels 5 to 12 available as switches for all protocols: code and size optimization - Documentation (readme.md): fully updated, all protocols/sub protocols/channels described, models example, many improvements - All protocols have been updated in some way, here are some highlights: * Bayang: added picture, video and inverted channels * CG023->H8_3D: added light and calibration channels * CX10: added sub protocols Q282, JC3015_1, JC3015_2, MK33041 * ESky: added new protocol - untested * Hubsan: added compatibility with the new Hubsan Plus protocol * KN: fully rewritten protocol: added sub protocols WLTOYS and FEILUN, 11 channels support New version successfully tested on all my models: Flysky RX/F939/V911 protocol Flysky, Frsky RX protocol Frsky, Hubsan X4 protocol Hubsan, Hisky HCP100/HCP80 protocol Hisky, HK-3000/HK3100 RX protocol Hisky/HK310, XINXUN X39 protocol YD717/XINXUN, Symax X5C-1 protocol SymaX/SYMAX, Cheerson CX-10A protocol CX10/BLUE, Eachine 3D-X4 protocol CG023. To access new protocols from er9x/ersky9x, you need to build a version from this github repository https://github.com/pascallanger/mbtx based on the latest er9x r820 and ersky9x r218.
This commit is contained in:
@@ -140,19 +140,18 @@ void A7105_WriteID(uint32_t ida) {
|
||||
CS_on;
|
||||
}
|
||||
|
||||
void A7105_SetPower_Value(int power)
|
||||
/*
|
||||
static void A7105_SetPower_Value(int power)
|
||||
{
|
||||
/*
|
||||
Power amp is ~+16dBm so:
|
||||
TXPOWER_100uW = -23dBm == PAC=0 TBG=0
|
||||
TXPOWER_300uW = -20dBm == PAC=0 TBG=1
|
||||
TXPOWER_1mW = -16dBm == PAC=0 TBG=2
|
||||
TXPOWER_3mW = -11dBm == PAC=0 TBG=4
|
||||
TXPOWER_10mW = -6dBm == PAC=1 TBG=5
|
||||
TXPOWER_30mW = 0dBm == PAC=2 TBG=7
|
||||
TXPOWER_100mW = 1dBm == PAC=3 TBG=7
|
||||
TXPOWER_150mW = 1dBm == PAC=3 TBG=7
|
||||
*/
|
||||
//Power amp is ~+16dBm so:
|
||||
//TXPOWER_100uW = -23dBm == PAC=0 TBG=0
|
||||
//TXPOWER_300uW = -20dBm == PAC=0 TBG=1
|
||||
//TXPOWER_1mW = -16dBm == PAC=0 TBG=2
|
||||
//TXPOWER_3mW = -11dBm == PAC=0 TBG=4
|
||||
//TXPOWER_10mW = -6dBm == PAC=1 TBG=5
|
||||
//TXPOWER_30mW = 0dBm == PAC=2 TBG=7
|
||||
//TXPOWER_100mW = 1dBm == PAC=3 TBG=7
|
||||
//TXPOWER_150mW = 1dBm == PAC=3 TBG=7
|
||||
uint8_t pac, tbg;
|
||||
switch(power) {
|
||||
case 0: pac = 0; tbg = 0; break;
|
||||
@@ -167,6 +166,7 @@ void A7105_SetPower_Value(int power)
|
||||
};
|
||||
A7105_WriteReg(0x28, (pac << 3) | tbg);
|
||||
}
|
||||
*/
|
||||
|
||||
void A7105_SetPower()
|
||||
{
|
||||
@@ -196,6 +196,8 @@ const uint8_t PROGMEM FLYSKY_A7105_regs[] = {
|
||||
0x13, 0xc3, 0x00, 0xff, 0x00, 0x00, 0x3b, 0x00, 0x17, 0x47, 0x80, 0x03, 0x01, 0x45, 0x18, 0x00,
|
||||
0x01, 0x0f, 0xff
|
||||
};
|
||||
#define ID_NORMAL 0x55201041
|
||||
#define ID_PLUS 0xAA201041
|
||||
void A7105_Init(uint8_t protocol)
|
||||
{
|
||||
void *A7105_Regs;
|
||||
@@ -207,7 +209,7 @@ void A7105_Init(uint8_t protocol)
|
||||
}
|
||||
else
|
||||
{
|
||||
A7105_WriteID(0x55201041);
|
||||
A7105_WriteID(ID_NORMAL);
|
||||
A7105_Regs=(void *)HUBSAN_A7105_regs;
|
||||
}
|
||||
for (uint8_t i = 0; i < 0x33; i++){
|
||||
|
||||
Reference in New Issue
Block a user