diff --git a/js/wizard_save_framework.js b/js/wizard_save_framework.js index 71cbdd338..30620a440 100644 --- a/js/wizard_save_framework.js +++ b/js/wizard_save_framework.js @@ -31,7 +31,7 @@ var wizardSaveFramework = (function () { serialPortHelper.set(config.value.port, 'GPS', config.value.baud); mspHelper.saveSerialPorts(function () { - features.execute(callback); + features.execute(self.enableVirtulaPitot(config, callback)); }); break; case 'gpsProtocol': @@ -43,6 +43,14 @@ var wizardSaveFramework = (function () { } }; + self.enableVirtulaPitot = function (config, callback) { + if (config.value.port != '-1') { + mspHelper.setSetting('pitot_hardware', "VIRTUAL", callback); + } else { + callback(); + } + }; + self.handleSetting = function (configs, finalCallback) { if (configs.length > 0) {