LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Why Does My Digital Read Interrupt My Digital Write When Using Easy DIO VIs?

I am using "Write to Digital Line.vi" to set the state of a digital line on my board, and then "Read from Digital Line.vi" to read the state of a different line on the same port of my board. It seems like when the READ executes, it does not maintain the state I set in the WRITE. How can I fix this?

Your help is greatly appreciated.
0 Kudos
Message 1 of 2
(2,407 Views)
The usual reason this happens is because the Easy DIO VIs reconfigure your board each time they run unless you wire in the iteration terminal. Reconfiguring your board resets lines. Even if you do wire in the iteration terminal, the first time an Easy DIO VI runs it configures the whole port as input or output - clearing your previous port configuration. If you are using traditional DAQ, the best thing to do is use three advanced VIs: DIO Port Config.vi, DIO Port Read.vi, and DIO Port Write.vi. You can find these on the advanced palette or on the diagram of the Easy DIO VIs. Call DIO Port config.vi only once and configure your individual lines as input or output (assuming your board supports individual line configuration).

Regards,
Doug Norman
0 Kudos
Message 2 of 2
(2,407 Views)