I’m having an issue with reconfiguring the UART.
const BAUD = 115200;
uart ← hardware.uartBCAW;
uart.configure(BAUD, 8, PARITY_EVEN, 1, NO_CTSRTS);
I’m currently trying to reconfigure this later with PARITY_NONE.
From research I see that it’s important to call uart.disable() prior to configuring it again. So I’m using a mix of solutions that I’ve found via the Imp forums. I’ve tried another supposedly working solution for reconfiguring with NO_RX and/or NO_TX and it’s not properly working.
function configureEncoder() { uart.disable(); uart.configure(BAUD, 8, PARITY_NONE, 1, NO_RX | NO_TX); uart.disable(); uart.configure(BAUD, 8, PARITY_NONE, 1, NO_CTSRTS); server.log("Encoder ready."); }