diff --git a/sim/state/analog.ts b/sim/state/analog.ts index 195c04cd..7122b4f1 100644 --- a/sim/state/analog.ts +++ b/sim/state/analog.ts @@ -48,19 +48,12 @@ namespace pxsim { let v = "vSIM" for (let i = 0; i < buf.data.length; ++i) buf.data[i] = v.charCodeAt(i) || 0 - console.log("analog read"); - console.log(buf.data); return buf.data.length }, write: buf => { - console.log("analog write"); - console.log(buf); return 2 }, ioctl: (id, buf) => { - console.log("analog ioctl"); - console.log(id); - console.log(buf); return 2; } }) diff --git a/sim/state/control.ts b/sim/state/control.ts index 2fd41ce4..54f8154c 100644 --- a/sim/state/control.ts +++ b/sim/state/control.ts @@ -85,7 +85,7 @@ namespace pxsim.control { } export function dmesg(s: string) { - console.log("DMESG: " + s) + //console.log("DMESG: " + s) } } diff --git a/sim/state/motor.ts b/sim/state/motor.ts index 308d2197..a453c344 100644 --- a/sim/state/motor.ts +++ b/sim/state/motor.ts @@ -35,21 +35,14 @@ namespace pxsim { let v = "vSIM" for (let i = 0; i < buf.data.length; ++i) buf.data[i] = v.charCodeAt(i) || 0 - console.log("motor read"); - console.log(buf.data); return buf.data.length }, write: buf => { if (buf.data.length == 0) return 2; const cmd = buf.data[0]; - console.log("motor write"); - console.log(buf); return 2 }, ioctl: (id, buf) => { - console.log("motor ioctl"); - console.log(id); - console.log(buf); return 2; } }); diff --git a/sim/state/output.ts b/sim/state/output.ts index f0229fe5..d884b3d5 100644 --- a/sim/state/output.ts +++ b/sim/state/output.ts @@ -38,7 +38,6 @@ namespace pxsim { switch (cmd) { case DAL.opProgramStart: { // init - console.log('init'); return 2; } case DAL.opOutputReset: { @@ -133,15 +132,9 @@ namespace pxsim { console.warn('unknown cmd: ' + cmd); break; } - - console.log("pwm write"); - console.log(buf); return 2 }, ioctl: (id, buf) => { - console.log("pwm ioctl"); - console.log(id); - console.log(buf); return 2; } }); diff --git a/sim/state/uart.ts b/sim/state/uart.ts index cc612b03..70247b9a 100644 --- a/sim/state/uart.ts +++ b/sim/state/uart.ts @@ -101,32 +101,28 @@ namespace pxsim { let v = "vSIM" // for (let i = 0; i < buf.data.length; ++i) // buf.data[i] = v.charCodeAt(i) || 0 - console.log("uart read"); - console.log(buf.data); return buf.data.length }, write: buf => { - console.log("uart write"); - console.log(buf); return 2 }, ioctl: (id, buf) => { switch (id) { case IO.UART_SET_CONN: { // Set mode - console.log("IO.UART_SET_CONN"); + //console.log("IO.UART_SET_CONN"); for (let port = 0; port < DAL.NUM_INPUTS; port++) { const connection = buf.data[DevConOff.Connection + port]; // CONN_NONE, CONN_INPUT_UART const type = buf.data[DevConOff.Type + port]; const mode = buf.data[DevConOff.Mode + port]; - console.log(`${port}, mode: ${mode}`) + //console.log(`${port}, mode: ${mode}`) const node = ev3board().getInputNodes()[port]; if (node) node.setMode(mode); } return 2; } case IO.UART_CLEAR_CHANGED: { - console.log("IO.UART_CLEAR_CHANGED") + //console.log("IO.UART_CLEAR_CHANGED") for (let port = 0; port < DAL.NUM_INPUTS; port++) { const connection = buf.data[DevConOff.Connection + port]; // CONN_NONE, CONN_INPUT_UART const type = buf.data[DevConOff.Type + port]; @@ -137,7 +133,7 @@ namespace pxsim { return 2; } case IO.UART_READ_MODE_INFO: { - console.log("IO.UART_READ_MODE_INFO") + //console.log("IO.UART_READ_MODE_INFO") const port = buf.data[UartCtlOff.Port]; const mode = buf.data[UartCtlOff.Mode]; const node = ev3board().getInputNodes()[port]; @@ -145,9 +141,6 @@ namespace pxsim { return 2; } } - console.log("uart ioctl"); - console.log(id); - console.log(buf); return 2; } })