AnsweredAssumed Answered

Can't get UART to work with even/odd parity on K70

Question asked by Bilal Wasim on Oct 16, 2016
Latest reply on Apr 12, 2017 by Kerry Zhou

Hi people. I'm currently working on UART driver for K70 board. The driver seems to work correctly, and I'm able to transmit and receive data correctly. I'm using TX(polling), and RX(Interrupt). However, when I change the parity of the data transmission from none to odd/even, I only receive garbage data on the console. Register setting for enabling parity is :
i- set the C1[PE] = 1
ii- set the C1[PT] = 0(for even parity), and C1[PT] = 1(for odd parity).
This is how the configuration is supposed to be, but it doesn't work. I've checked this with teraterm, putty and realterm. Moreover, I've written a script in python as well, but they all show the same behavior.
I'm using 8 bit data with 1 stop bit, and 115200 bps as my baud rate. Someone told me that this is probably a known issue, and there are workarounds. Am I supposed to use 9 bit data when I'm enabling parity? Is this true? Can anyone guide me in the right direction here?