Page 1 of 1

ESP-32 UART component not supporting 9Bit Parity mode

Posted: Mon Jan 25, 2021 9:19 pm
by dvcam99
Hello Matrix Team,

below you will find a shorts ESP-32 UART 9Bit opperation test program. This will show the situation.

Very positive in this context is that manual baud rate is working!!

To be very honest this missing 9Bit opperation is at the moment a show stopper in order to purchase a FC professional 9 upgrade for me.
ESP32_UART_Parity_Test_V1.fcfx
(8.89 KiB) Downloaded 429 times
Maybe this is an easy fix for you brillant experts!! ;)

THX and BR
Dirk

Re: ESP-32 UART component not supporting 9Bit Parity mode

Posted: Tue Jan 26, 2021 8:18 am
by LeighM
Hi Dirk,
The ESP32 UART driver does not support 9 bit data,
so you will not be able to send for example 0x1f0 as in your program.
However, if 8 bit data plus parity is what you need, then please try this ...

Set the Flowcode UART property to 8 bit
and add this C code ...

Code: Select all

uart_set_parity(1, UART_PARITY_EVEN);

Re: ESP-32 UART component not supporting 9Bit Parity mode

Posted: Tue Jan 26, 2021 10:09 pm
by dvcam99
Many thanks Leigh,

it works fantastic!! It´s is much better compared against my PIC UARTS.

I got rid of my complicated old parity calculation!! :D

In case that sombody wants to activate two stop bits!! Below the syntax for ESP32 compiler:

uart_set_stop_bits(1,UART_STOP_BITS_2);

BR

Dirk

Re: ESP-32 UART component not supporting 9Bit Parity mode

Posted: Wed Jan 27, 2021 7:52 am
by LeighM
Hi Dirk,
Glad to hear, thanks for letting us know
Leigh