10-06-2013 05:31 AM
hi, I am new to labview, Instrumentation engineering student, first year.
I am trying to make a traffic light system in labview, which involves some counters and a few LED lights
but problem is I cant understand how to use a truth table in labview
In my problem, there will be 3 inputs LED (IR1, PS1, IR2) and one output counter (OC1) which will follow the table to give desired output.
I have attached the table to help understanding things better, please guide me.
10-06-2013 07:25 AM
Dear Argya,
There are several ways of doing this but I suggest you use State Machine Architecture to get the output when correspnding inputs go high in the manner given in table. Why don't you first reduce this table into simplified boolean expression?
Regards.
10-06-2013 07:31 AM
Sorry being a noob here but can you tell me please what is State Machine Architecture ?
also i couldn't divide this into simple boolean expression as this dont follow rule of any gate, like in one place the counter output will be 2
10-06-2013 08:05 AM
If doing without state machine, just use simple compound arithmetic block and select function.
10-06-2013 08:17 AM
looks like that will do,
can you please attach the vi file for me ?
regards
10-06-2013 08:51 AM
What version of LabVIEW are you running?
10-06-2013 08:58 AM
Just drag and drop this image into your block diagram window.
10-06-2013 08:58 AM
Labview 2010 I am using
10-06-2013 09:06 AM
I did, nothing is happening 😞
only the image link came there
10-06-2013 10:25 AM
Try recreating the image. It shouldn't take but a few minutes to wire up.
The reason you didn't get code was that the VI snippet was saved as a 2012 version. It would've needed to be saved as a 2010 version to drop into your LV 2010.