LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

how do I use the Out_Byte_To_port function in labWindows?

trying to send a byte to the parallel port, what port number shall I use and how do I write the byte in characters?
0 Kudos
Message 1 of 2
(2,851 Views)
I used the outp() function to write to the serial port that way:

char string[10];

strcpy (string, "TEST");

for (i = 0; i < 4; i++) {
outp (0x3F8, *(string + i));
for (x = 0; x < 10; x++); //Very little delay
}

I found the port number in the Control Panel>>System>>Peripherals>>Ports. Double click the desired port: the Resources tab gives you the port number (called I/O address or similar; I'm sorry if the terminology is not the right one: I'm translating on the fly from an italian version on Windows). The previous example is for writing to COM1.

I haven't tried to write to the parallel port, maybe it's similar to writing to the serial one.

Roberto


Proud to use LW/CVI from 3.1 on.

My contributions to the Developer Community
________________________________________
If I have helped you, why not giving me a kudos?
Message 2 of 2
(2,851 Views)