Parity simulation for UART input in debug function

Hi all!

For example, I set disable parity generation and checking at UART0 Line Control Register.
Then I could write "S0IN = 0xAB" to simulate uart input, and it's ok.

But I neen to use UART with parity (even). How could I correct init S0IN? I tried "S0IN = 0xAB" and "S0IN = 0x1AB", anyway Keil say parity error.

Parents
  • You haven't said what chip you're using but, almost certainly, the SIN register comes after parity has been stripped - in just the same way that it does not contain the start & stop bits!

    You usually don't get to see the parity bit itself - just a status bit that tells you whether there was an error.

    You will have to study the documentation for the specific processor for details...

Reply
  • You haven't said what chip you're using but, almost certainly, the SIN register comes after parity has been stripped - in just the same way that it does not contain the start & stop bits!

    You usually don't get to see the parity bit itself - just a status bit that tells you whether there was an error.

    You will have to study the documentation for the specific processor for details...

Children
More questions in this forum