Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

How do I configure an RS-485 serial port to send 9-bit data packets?

I am developing a test application to communicate with a multiplexer device using modified RS-485.  The hardware device of choice is the PXI-8423, and I am developing in LabWindows. 
 
The physical layer is per the spec, but the communication uses 9 data bits (rather than the typical max 8), and operates at a non-standard speed (62.5 kbps).  The data packet looks like:
(1 Start Bit)(9 Data Bits)(1 parity bit)(1 stop bit).
 
I need to either:
a)  set serial port parameters for 9 data bits, odd comm speed (possible??)
--or--
b)  Write software to manually bit-bang, and build the packets myself.
 
How can I do one or the other??
0 Kudos
Message 1 of 2
(3,207 Views)

Hi Chris,

I am facing the same problem. I want to drive a RS-485 interface with a baudrate of 250K and also 9 bits with no parity. We have a special dedicated board for the normal (field) solution but I want to bypass this board for testing.

With your board you can't use a non standard baudrate. I use the PCI-8431/2 so the baudrate is solved but then the 9 bits.

In my application the 9th bit is used for the first byte in a frame. So one byte with the 9th bit as a '1' and the following bytes of that frame the 9th bit is '0'

I made a monitor for this interface using a fixed parity. This fixed parity is seen as the 9th bit. The monitor part was easy. Controlling this interface is the next step for me when I can find the time.

I think that your solution b) can be done with a digital I/O board and/or with a digital pattern generator with a conversion to the RS-485 interface.

Hope this helps a bit.

 

0 Kudos
Message 2 of 2
(3,198 Views)