preparing some stuff for dongs
parent
a6fcdbdecf
commit
854a17e0f2
|
@ -294,6 +294,7 @@ GUI_control.prototype.tab_switch_cleanup = function(callback) {
|
|||
break;
|
||||
|
||||
case 'firmware_flasher':
|
||||
// this.interval_remove('factory_mode');
|
||||
PortHandler.flush_callbacks();
|
||||
|
||||
// unbind "global" events
|
||||
|
|
|
@ -68,6 +68,9 @@ var serial = {
|
|||
setControlSignals: function(signals, callback) {
|
||||
chrome.serial.setControlSignals(this.connectionId, signals, callback);
|
||||
},
|
||||
getControlSignals: function(callback) {
|
||||
chrome.serial.getControlSignals(this.connectionId, callback);
|
||||
},
|
||||
send: function(data, callback) {
|
||||
var self = this;
|
||||
self.output_buffer.push({'data': data, 'callback': callback});
|
||||
|
|
|
@ -245,6 +245,17 @@ function tab_initialize_firmware_flasher() {
|
|||
}
|
||||
*/
|
||||
|
||||
/*
|
||||
GUI.interval_add('factory_mode', function factory_mode() {
|
||||
serial.getControlSignals(function(result) {
|
||||
if (result.cts == true) {
|
||||
// Trigger regular Flashing sequence
|
||||
$('a.flash_firmware').click();
|
||||
}
|
||||
});
|
||||
}, 500);
|
||||
*/
|
||||
|
||||
$(document).keypress(function(e) {
|
||||
if (e.which == 13) { // enter
|
||||
// Trigger regular Flashing sequence
|
||||
|
|
Loading…
Reference in New Issue