mirror of
https://github.com/pascallanger/DIY-Multiprotocol-TX-Module.git
synced 2025-12-22 01:03:15 +00:00
New feature: end bind
This new feature is available: - in serial mode and when binding from the GUI. As soon as the Bind window is closed = serial bind bit was set and cleared, the current bind operation will be terminated. - if the bind was initiated from the Bind on channel feature (bind channel goes high) then as soon as the bind channel goes low the current bind operation will be terminated. Tested on ersky9x which does open a bind window, not sure about OpenTX... Some protocols (Hubsan, Assan, FY326, Shenqi...) which are waiting for model/RX to reply will stay in bind mode.
This commit is contained in:
@@ -319,12 +319,12 @@ uint16_t symax_callback()
|
||||
return SYMAX_FIRST_PACKET_DELAY;
|
||||
break;
|
||||
case SYMAX_BIND2:
|
||||
counter = SYMAX_BIND_COUNT;
|
||||
bind_counter = SYMAX_BIND_COUNT;
|
||||
phase = SYMAX_BIND3;
|
||||
SYMAX_send_packet(1);
|
||||
break;
|
||||
case SYMAX_BIND3:
|
||||
if (counter == 0)
|
||||
if (bind_counter == 0)
|
||||
{
|
||||
symax_init2();
|
||||
phase = SYMAX_DATA;
|
||||
@@ -333,7 +333,7 @@ uint16_t symax_callback()
|
||||
else
|
||||
{
|
||||
SYMAX_send_packet(1);
|
||||
counter--;
|
||||
bind_counter--;
|
||||
}
|
||||
break;
|
||||
case SYMAX_DATA:
|
||||
|
||||
Reference in New Issue
Block a user