mirror of
https://github.com/iNavFlight/inav.git
synced 2025-07-26 01:35:35 +03:00
Cleanup 4way interface
- implement cleaner interface into Cleanfligh - separate initialization and start - allow direct access to command processing, skipping BLHeli serial framing - remove mspPort_t dependency - refactor naming to CF style - use serial_4way_impl.h for internal interface to bootloader implementation - use uint16_t instead of hi/lo bytes ; use integer lengths instead of 0=256 encoding - fix buffer overflow in stkv2 code
This commit is contained in:
parent
19c4c07897
commit
aedeed0c36
8 changed files with 927 additions and 1081 deletions
|
@ -1568,7 +1568,7 @@ static bool processInCommand(void)
|
|||
// switch all motor lines HI
|
||||
// reply the count of ESC found
|
||||
headSerialReply(1);
|
||||
serialize8(Initialize4WayInterface());
|
||||
serialize8(esc4wayInit());
|
||||
// because we do not come back after calling Process4WayInterface
|
||||
// proceed with a success reply first
|
||||
tailSerialReply();
|
||||
|
@ -1579,7 +1579,7 @@ static bool processInCommand(void)
|
|||
// rem: App: Wait at least appx. 500 ms for BLHeli to jump into
|
||||
// bootloader mode before try to connect any ESC
|
||||
// Start to activate here
|
||||
Process4WayInterface(currentPort, writer);
|
||||
esc4wayProcess(currentPort->port);
|
||||
// former used MSP uart is still active
|
||||
// proceed as usual with MSP commands
|
||||
break;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue