2024-10-24 10:19 PM - last edited on 2024-10-25 12:47 AM by Andrew Neil
I want to send data from my STM32 to another micro controller and I want to enable space parity, there is no setting to enable it, the only settings are none, odd and even. For space parity i want the parity bit to always be 0. I am using 9 bit UART including parity bit. I have tried to maintain even parity meaning the data has even number of 1s so even parity is 0 always but that doesn't help. I am using Barry terminal to check the transmitted data in that when parity is set even or none then only data is received, with space parity settings its not received. Is there any way in which i can ensure that the parity bit is 0 always and I get the data with space parity settings?
Any help is appreciated. Thanks.
2024-10-24 10:28 PM - edited 2024-10-24 10:30 PM
Hi,
Just use 9 bit setting with parity disabled... Data bit 8 is your parity... (make sure you are using 16 bit transfers if you want to write to bit 8).
Kind regards
Pedro
2024-10-24 10:36 PM - edited 2024-10-24 10:43 PM
Hi,
I tried that but in that case parity setting as NONE is working. I want it to work with space parity . Here is the screen shot of the terminal. when i set parity as none only in that case I am getting the data not under space.
2024-10-24 10:47 PM
Hi,
What do you get if you select Mark parity?
Kind regards
Pedro
2024-10-24 10:54 PM
Hello, I do not get anything.
2024-10-24 11:04 PM
Hi,
Without an oscilloscope image of the TX data, I'm going to say you have a bug with your Terminal program...
Kind regards
Pedro
2024-10-24 11:11 PM
Actually, I don't think "standard" PC uarts can do Mark/ Space parity...
2024-10-24 11:45 PM
Actually ,I have an 8051 which will be on the receiving end, I have checked with it, I am able to transmit data from that and get the data when parity is set as space on PC . And due requirements I am not able to change this UART settings on 8051 (9 bit including parity where parity bit is 0).
2024-10-24 11:48 PM
Hi,
Then you'll need to post an oscilloscope view of the TX data...
Kind regards
Pedro
2024-10-25 12:32 AM
Hi, here it is, i am transmitting