03-16-2012 10:52 AM - edited 03-16-2012 10:55 AM
Hi !
I need to send a multiple binary to a multiplexer when i recieve a TTL signal, then, i need to read the signal for each sensor.
But my vi just send 1 them one after another :/, i've tried many things but i'm stuck.
edit : for info i'm using a ni pci6251 and labview 8.5
Here is a simplified version of my VI and and little draw i made for you.
Solved! Go to Solution.
03-16-2012 11:02 AM
So do you have 8 digital lines wired to your mux? Do you then want to send a series of digital outputs? If yes to both, set the DAQmx Write to 1Chan 1Samp, put it inside a for loop, and wire your U8 array through the loop.
03-19-2012 02:49 AM - edited 03-19-2012 02:49 AM
i'm worry that the for loop don't run fast enough to generate the samples but if there's no other solution...
03-19-2012 03:13 AM
for loops used properly dont impact performance as much as youd think and are needed in many applications, in one of my current jobs i am using a number of them (avoiding nesting them if i can) but using the paralelism and conditional terminals to keep performance up. on the block diagram right clock on the for loop and there are some optios conditional terminal (allowing you to end the for loop early) and configure paralel (runs a number of thefor loops in paralell, there are some constraints on doing this).
sorry for the spelling i have dyslexic fingers this morning
hope it helps
03-19-2012 04:24 AM
I put a for loop
i put the stop task outside the for loop, of course, the program just write me 1 sample after another after each TTL signal and labview is stuck on the writing VI at the 2nd for loop
grmbl...
03-19-2012 10:02 AM
Hi i somehow manage to make it wth generating a pulse train on the TTL signal and writing the samples on the pulse train.
I'll give u the VI once i'm sure it works
03-20-2012 04:46 AM
Hi Daparta,
I am not sure to have fully understodd what you wanted to do.
Could you try the .vi I attached.
regards
Romain DUVAL || RF & Semiconductor Staff System Engineer || CLA || CTA
National Instruments France
03-20-2012 08:26 AM - edited 03-20-2012 08:27 AM
u didn't fully understand what i want to do but u may have some other solution, anyway i managed to do succeed,
check the VI i atached, it works.
at each TTL i generate a pulse train, and the binary words are synchronised on the pulse train.