mirror of
https://github.com/iNavFlight/inav-configurator.git
synced 2025-07-13 11:29:53 +03:00
if unexpected data is received, throw an error instead of log, this will also attach a stack trace for easier debugging
This commit is contained in:
parent
37746bf3ed
commit
6dec7dfbc1
1 changed files with 1 additions and 1 deletions
|
@ -219,7 +219,7 @@ STM32_protocol.prototype.send = function (Array, bytes_to_read, callback) {
|
|||
// result = true/false
|
||||
STM32_protocol.prototype.verify_response = function (val, data) {
|
||||
if (val != data[0]) {
|
||||
console.log('STM32 Communication failed, wrong response, expected: ' + val + ' received: ' + data[0]);
|
||||
console.error('STM32 Communication failed, wrong response, expected: ' + val + ' received: ' + data[0]);
|
||||
GUI.log('STM32 Communication <span style="color: red">failed</span>, wrong response, expected: ' + val + ' received: ' + data[0]);
|
||||
|
||||
// disconnect
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue