Updates and fixes
fix FEATURE_RX_SERIAL Delay for the hardware bind plug Bind code will only work on default NAZE serial port (document limitation)
This commit is contained in:
parent
c80090f39f
commit
3aaaa3f9f5
|
@ -151,7 +151,7 @@ void init(void)
|
|||
systemInit();
|
||||
|
||||
// Spektrum sattelite bind - ported from Baseflight
|
||||
if (feature(FEATURE_RX_MSP)) {
|
||||
if (feature(FEATURE_RX_SERIAL)) {
|
||||
switch (masterConfig.rxConfig.serialrx_provider) {
|
||||
case SERIALRX_SPEKTRUM1024:
|
||||
case SERIALRX_SPEKTRUM2048:
|
||||
|
|
|
@ -151,6 +151,7 @@ uint32_t rccReadBkpDr(void)
|
|||
|
||||
/* spektrumBind function ported from Baseflight. It's used to bind satellite receiver to TX.
|
||||
* Function must be called immediately after startup so that we don't miss satellite bind window.
|
||||
* It will only work for USART2, PA3 pin.
|
||||
* Known parameters. Tested with DSMX satellite and DX8 radio. Framerate (11ms or 22ms) must be selected from TX.
|
||||
* 9 = DSMX 11ms / DSMX 22ms
|
||||
* 5 = DSM2 11ms 2048 / DSM2 22ms 1024
|
||||
|
@ -173,6 +174,7 @@ void spektrumBind(rxConfig_t *rxConfig)
|
|||
gpio.pin = hwBindPin;
|
||||
gpio.mode = Mode_IPU;
|
||||
gpioInit(hwBindPort, &gpio);
|
||||
delayMicroseconds(10); // allow configuration to settle
|
||||
if (digitalIn(hwBindPort, hwBindPin))
|
||||
return;
|
||||
#endif
|
||||
|
|
Loading…
Reference in New Issue