From 11fcf242581f19f0949f19bc95cbf78ebbafa15d Mon Sep 17 00:00:00 2001 From: NightHawk32 Date: Mon, 23 Nov 2015 01:47:09 -0500 Subject: [PATCH] Fixed bug with profile selector: It updates now on every status request. --- js/msp.js | 1 + js/serial_backend.js | 10 ++++------ 2 files changed, 5 insertions(+), 6 deletions(-) diff --git a/js/msp.js b/js/msp.js index cfde7dc0..6d5e81f3 100644 --- a/js/msp.js +++ b/js/msp.js @@ -227,6 +227,7 @@ var MSP = { CONFIG.activeSensors = data.getUint16(4, 1); CONFIG.mode = data.getUint32(6, 1); CONFIG.profile = data.getUint8(10); + $('select[name="profilechange"]').val(CONFIG.profile); sensor_status(CONFIG.activeSensors); $('span.i2c-error').text(CONFIG.i2cError); diff --git a/js/serial_backend.js b/js/serial_backend.js index fd8024fe..704c114c 100755 --- a/js/serial_backend.js +++ b/js/serial_backend.js @@ -260,7 +260,8 @@ function onConnect() { var dataflash = $('#dataflash_wrapper'); dataflash.show(); - + + MSP.send_message(MSP_codes.MSP_STATUS, false, false); // TEST code for dataflash status in header MSP.send_message(MSP_codes.MSP_DATAFLASH_SUMMARY, false, false); @@ -313,13 +314,10 @@ function onConnect() { - // testing dataflash change END - + // testing dataflash change END - - - } +} function onClosed(result) { if (result) { // All went as expected