LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Programming a board that requires serial or parallel communication on bit level

Hello,

I have purchased a matrix board that can cross 16 input with 16 outputs (www.chipcatalog.com/Analog/Datasheet/AD8113.htm ,See page 16 for information). This board can be controlled in 2 modes (serial or parallel). I would like to control this board from a PC using either serial or parallel port, runnig Labview.
In serial mode, the board expects data to be clocked in by the PC. However, I have searched through this forum and it seems to me that this is impossible with a standard RS232 port, as one can not control each individual pin from software. Correct or not ?

If serial is not possible, I was thinking of using this VI (http://forums.ni.com/ni/board/message?board.id=170&message.id=57732&query.id=14331#M57732) to control the board in parallel mode.

I run Win XP and Labview7.1

Thanks in advance

Paul
0 Kudos
Message 1 of 6
(3,439 Views)
Hi Paul,

In its true sense RS232 is an asynchronous port, which means that the data sent is not clocked but at a fixed rate which is the baud rate. You can use hand shake protocols or use Start pattern and end pattern to read the data in and out. All communication is ascii based.

Having said that, there is a way to assert or de-assert some of the lines on the serial Port. Drop a Property node then right click and Select Class->Visa->I/O Session->Serial Instr. Again right Click and Select Properties->Modem Line Settings and then you can see the lines available to you. You will have to do the assert and deassert this way. It can do some lines and logic is not TTL, so you will have to check your interface.

If I were you, I would instead choose the Parallel Port and use In and Out Port VI's. The parallel port has three address. Most common are 0x378 = Control, 0x379 = Status, 0x380 = Data. Using these ports you can read / Write data bit by bit Synchronously if you desire. With LV 7.1 this functionality is now standard as the CVI driver is included.

One suggestion, is if you use the parallel port, I suggested you put a simple buffer like an inverter (7404?) in between the PC Parallel Port and your Device. This is to protect, as well as have full TTL/CMOS capability to drive your device.

Currently I am using Parallel Port for I2C communication which is two wire Clock/Data lines and the information is transferred bit wise physically and byte wise in Software.

So you may use either, If you need more details, Please post with specific question and I am sure Someone here will be of help
Good Luck!

Mache
Message 2 of 6
(3,412 Views)
Dear Mache:
I am interested in the i2c case you said. Do you realize it by programming parallel port using lV??

Currently I am using Parallel Port for I2C communication which is two wire Clock/Data lines and the information is transferred bit wise physically and byte wise in Software.
0 Kudos
Message 3 of 6
(3,282 Views)
OOOppps,
I forgot to thank Mache for the answer. THANKS A LOT !

I will go for the solution with using paralell port communication, as this seems to be the easiest way out.
Does anyone know if there are some software examples out there, that I can use as a start (I have found some VI's that has some paralell port communication, but maybe someone know of software that are useful)?

Durden
0 Kudos
Message 4 of 6
(3,276 Views)
Attn: Mache
 
I am interested in a .vi to communicate with an I2C E2PROM connected directly to the LPT port.
Any help will be appreciated.
 
Thanks,
Sorin
0 Kudos
Message 5 of 6
(3,036 Views)
Hello!

AD8113   Softweare  
Demo version and limit 12Inputs-12 Outputs

www.albavill.uw.hu


0 Kudos
Message 6 of 6
(2,853 Views)