mirror of
https://github.com/betaflight/betaflight-configurator.git
synced 2025-07-18 22:05:13 +03:00
Added disabling of arming when connected to the configurator.
This commit is contained in:
parent
7672fcf064
commit
8246b0728d
4 changed files with 76 additions and 36 deletions
|
@ -1153,6 +1153,9 @@ MspHelper.prototype.process_data = function(dataHandler) {
|
|||
case MSPCodes.MSP_COPY_PROFILE:
|
||||
console.log('Copy profile');
|
||||
break;
|
||||
case MSPCodes.MSP_ARMING_DISABLE:
|
||||
console.log('Arming disable');
|
||||
break;
|
||||
default:
|
||||
console.log('Unknown code detected: ' + code);
|
||||
} else {
|
||||
|
@ -1512,9 +1515,17 @@ MspHelper.prototype.crunch = function(code) {
|
|||
case MSPCodes.MSP_COPY_PROFILE:
|
||||
buffer.push8(COPY_PROFILE.type)
|
||||
.push8(COPY_PROFILE.dstProfile)
|
||||
.push8(COPY_PROFILE.srcProfile)
|
||||
.push8(COPY_PROFILE.srcProfile);
|
||||
break;
|
||||
case MSPCodes.MSP_ARMING_DISABLE:
|
||||
var value;
|
||||
if (CONFIG.arming_disabled) {
|
||||
value = 1;
|
||||
} else {
|
||||
value = 0;
|
||||
}
|
||||
buffer.push8(value);
|
||||
break;
|
||||
|
||||
default:
|
||||
return false;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue