--- In l..., "gen_4p" wrote:
> Question: have anybody tried to implement 9 bit uart
protocol on LPCs?
>
Hi Gennady,
Yes I have done this on an LPC2129, I believe the UART is the same in
the LPC23xx.
We use a half duplex RS485 link with the master sending a message with
the 9th bit set high. We use the parity interrupt to detect this start
byte. We run at a baud rate of 250kbaud.
Sending would be easier, you would just set the appropriate parity
mode transmit the first byte with the 9th bit set, then switch parity
modes. This means that you would have to switch the FIFO off :-(, at
least for the transmission of the first byte.
We currently turn the FIFO off.
Contact me if you want more specific information.
Regards
Martin Honeywill
9 bit uart
Started by ●November 20, 2006
Reply by ●November 21, 20062006-11-21
Reply by ●November 21, 20062006-11-21
Gennady Palitsky wrote:
>
> You mean using external uart, right?
> That's what I'm trying to avoid, otherwise I can use any 8 bit micro
> (like Philips 8 bit LPC line) for serial port processing.
>
NO, that is not what he means. Most of the 16C4x0 style of UARTs
capable of Forced Parity can do RS485 9 bit communications. You force
the parity to "0", when a 9 bit byte is received with the parity bit
"set" to "1", this causes a parity error. Hence, a parity error on a
byte means that you have the Address Mark.
Turning the Fifo off will avoid issues with transmitting a correct 9th
bit value when it must be changed. If you don't send the 9th bit set,
as some protocols will allow, you can leave the Fifo on and look for
recieve parity errors.
TomW
--
Tom Walsh - WN3L - Embedded Systems Consultant
http://openhardware.net http://cyberiansoftware.com http://openzipit.org
"Windows? No thanks, I have work to do..."
----------------
>
> You mean using external uart, right?
> That's what I'm trying to avoid, otherwise I can use any 8 bit micro
> (like Philips 8 bit LPC line) for serial port processing.
>
NO, that is not what he means. Most of the 16C4x0 style of UARTs
capable of Forced Parity can do RS485 9 bit communications. You force
the parity to "0", when a 9 bit byte is received with the parity bit
"set" to "1", this causes a parity error. Hence, a parity error on a
byte means that you have the Address Mark.
Turning the Fifo off will avoid issues with transmitting a correct 9th
bit value when it must be changed. If you don't send the 9th bit set,
as some protocols will allow, you can leave the Fifo on and look for
recieve parity errors.
TomW
--
Tom Walsh - WN3L - Embedded Systems Consultant
http://openhardware.net http://cyberiansoftware.com http://openzipit.org
"Windows? No thanks, I have work to do..."
----------------
Reply by ●November 22, 20062006-11-22
Thanks to everyone who responded to my 9 bit UART problem.
I think I have quite clear understanding of possibilities now.
So the only problem for me now is availability of Keil's MCB2300 board.
The say it will be available sometimes in December.
And - have anybody heard anything on LPC24xx release ?
Gennady
----- Original Message -----
From: Martin Honeywill
To: l...
Sent: Tuesday, November 21, 2006 7:25 AM
Subject: [lpc2000] Re: 9 bit uart - correction
--- In l..., "gen_4p" wrote:
> Question: have anybody tried to implement 9 bit uart protocol on LPCs?
>
Hi Gennady,
Yes I have done this on an LPC2129, I believe the UART is the same in
the LPC23xx.
We use a half duplex RS485 link with the master sending a message with
the 9th bit set high. We use the parity interrupt to detect this start
byte. We run at a baud rate of 250kbaud.
Sending would be easier, you would just set the appropriate parity
mode transmit the first byte with the 9th bit set, then switch parity
modes. This means that you would have to switch the FIFO off :-(, at
least for the transmission of the first byte.
We currently turn the FIFO off.
Contact me if you want more specific information.
Regards
Martin Honeywill
I think I have quite clear understanding of possibilities now.
So the only problem for me now is availability of Keil's MCB2300 board.
The say it will be available sometimes in December.
And - have anybody heard anything on LPC24xx release ?
Gennady
----- Original Message -----
From: Martin Honeywill
To: l...
Sent: Tuesday, November 21, 2006 7:25 AM
Subject: [lpc2000] Re: 9 bit uart - correction
--- In l..., "gen_4p" wrote:
> Question: have anybody tried to implement 9 bit uart protocol on LPCs?
>
Hi Gennady,
Yes I have done this on an LPC2129, I believe the UART is the same in
the LPC23xx.
We use a half duplex RS485 link with the master sending a message with
the 9th bit set high. We use the parity interrupt to detect this start
byte. We run at a baud rate of 250kbaud.
Sending would be easier, you would just set the appropriate parity
mode transmit the first byte with the 9th bit set, then switch parity
modes. This means that you would have to switch the FIFO off :-(, at
least for the transmission of the first byte.
We currently turn the FIFO off.
Contact me if you want more specific information.
Regards
Martin Honeywill
Reply by ●October 3, 20072007-10-03