1
0
Fork 0
mirror of https://github.com/betaflight/betaflight-configurator.git synced 2025-07-15 20:35:23 +03:00

Move FC global vars inside FC object

This commit is contained in:
Miguel Angel Mulero Martinez 2020-07-06 08:05:27 +02:00
parent b9137a68e6
commit 24010a2e2a
32 changed files with 2799 additions and 2797 deletions

View file

@ -139,9 +139,9 @@ STM32_protocol.prototype.connect = function (port, baud, hex, options, callback)
var onConnectHandler = function () {
GUI.log(i18n.getMessage('apiVersionReceived', [CONFIG.apiVersion]));
GUI.log(i18n.getMessage('apiVersionReceived', [FC.CONFIG.apiVersion]));
if (semver.lt(CONFIG.apiVersion, "1.42.0")) {
if (semver.lt(FC.CONFIG.apiVersion, "1.42.0")) {
self.msp_connector.disconnect(function (disconnectionResult) {
@ -153,7 +153,7 @@ STM32_protocol.prototype.connect = function (port, baud, hex, options, callback)
MSP.send_message(MSPCodes.MSP_BOARD_INFO, false, false, function () {
var rebootMode = 0; // FIRMWARE
if (bit_check(CONFIG.targetCapabilities, FC.TARGET_CAPABILITIES_FLAGS.HAS_FLASH_BOOTLOADER)) {
if (bit_check(FC.CONFIG.targetCapabilities, FC.TARGET_CAPABILITIES_FLAGS.HAS_FLASH_BOOTLOADER)) {
// Board has flash bootloader
GUI.log(i18n.getMessage('deviceRebooting_flashBootloader'));
console.log('flash bootloader detected');