mirror of
https://github.com/iNavFlight/inav-configurator.git
synced 2025-07-13 19:40:22 +03:00
loosing up verification for interface init
This commit is contained in:
parent
83726bc392
commit
04ee01f057
1 changed files with 7 additions and 1 deletions
|
@ -337,12 +337,18 @@ STM32_protocol.prototype.upload_procedure = function(step) {
|
|||
switch (step) {
|
||||
case 1:
|
||||
// initialize serial interface on the MCU side, auto baud rate settings
|
||||
// we could probably use interval timer here to try 2-3 times and then fail afterwards
|
||||
self.send([0x7F], 1, function(reply) {
|
||||
if (self.verify_response(self.status.ACK, reply)) {
|
||||
if (reply[0] == self.status.ACK || reply[0] == self.status.NACK) {
|
||||
console.log('STM32 - Serial interface initialized on the MCU side');
|
||||
|
||||
// proceed to next step
|
||||
self.upload_procedure(2);
|
||||
} else {
|
||||
STM32.GUI_status('STM32 Communication with bootloader <span style="color: red">failed</span>');
|
||||
|
||||
// disconnect
|
||||
this.upload_procedure(99);
|
||||
}
|
||||
});
|
||||
break;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue