Digital I/O

cancel
Showing results for 
Search instead for 
Did you mean: 

NI 6509 setting counter in C#

Solved!
Go to solution

Hello,

 

I am using a NI 6509 I/O card. I have to write in Visual C#  different lines on different port to drive Leds, Relay, Motors and so on ...

I have found in dotnet 2.0/example some examples written in C# to write digital ports set in output like "ReadDigPort".

I would like to know if code examples exist on "masking or Xoring" data in order to modify only a single  line of the port without

affecting the value of the other lines ?


Thnaks for your answers

 

 

0 Kudos
Message 1 of 3
(3,711 Views)
Solution
Accepted by topic author renacas

hi,

 

You can use  the function "WriteSingleSampleSingleLine" to write only one byte on the port or you can read, masking and write all the line with "WriteSingleSamplePort".

 

Regards,

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

Hi all,

 

Aurélien J. (National Instruments France) wrote :

***

You can use  the function "WriteSingleSampleSingleLine" to write only one byte on the port or you can read, masking and write all the line with "WriteSingleSamplePort"

***

can you please explain to me what "WriteSingleSampleSingleLine" function is, and where is it written ?

 

I write C++ code with Linux 2.6 OS and I am intersted in the possibility to address only one line in a port without masking bits as masking rewrites values on a port and generates glitches that may damage receivers (for 0V output glitch is +0.92V ~ -1.12V and my TTL only supports 0~+0.7V) .

 

Thanks in advance.

0 Kudos
Message 3 of 3
(3,006 Views)