Serial1: Stop bit configuration for Xenon

I need to communicate with a device using 2 stopbits from my Xenon. I’ve set it up using:
Serial1.begin(9600,SERIAL_8N2);
Despite that, I can see in the oscilloscope that it is still using 8N1 for its output.
Google Photos

Is there another way that stopbits=2 should be set? Or is it not supported?

Something for @avtolstoy I guess.

That mode is not supported on Gen 3 devices at this time.

Pre-defined Serial configurations available:

  • SERIAL_8N1 - 8 data bits, no parity, 1 stop bit (default)
  • SERIAL_8E1 - 8 data bits, even parity, 1 stop bit

Other options, including odd parity, and 7 and 9 bit modes, are not available on the Xenon.

Here is a GitHub feature request “issue” for that

Thanks you for the help! I was hoping it was an option for the device since I noticed it is a configurable option in the Nordic nRF52840 the device uses.
I hope it becomes available soon. Unfortunately I can’t change the configuration on the other device to match it.
In the meantime I figured out I can use a 120us delay between bytes to make up for the missing stop bit. So far it has been robust, but It would definitely be nice to not need to use that hack.

1 Like