How about Serial.setup({databits:7,stopbits:2}) - you could add this to JshUSARTInfo in jshardware.h pretty easily, and it'd be nice and compatible with anything that didn't support it (or that supported other modes).
Maybe just add the following in jshardware:
if (databits==7 && stopbits==2) ...
else if (databits==8 && stopbits==1) ...
else jsWarn("Specified combination of stop and data bits is not available");
Espruino is a JavaScript interpreter for low-power Microcontrollers. This site is both a support community for Espruino and a place to share what you are working on.
Great, let me know how it goes!
How about
Serial.setup({databits:7,stopbits:2})
- you could add this toJshUSARTInfo
injshardware.h
pretty easily, and it'd be nice and compatible with anything that didn't support it (or that supported other modes).Maybe just add the following in jshardware:
does that sound ok?