10-14-2019 02:37 AM
Hello,
I am writing a program of water valve opening and closing by user input. The software program work good, but when I want to use for switching leby digital module , it create problem.
Please help me out with this.
I attach both the program and looking forward to your kind reply.
One more thing is that i am using NI 9401 two channels for led switching.
Kindly check and give a solution for it. I am new to LabView.
Thanks
Best Regards
Faisal
10-14-2019 03:38 AM
Hi faisal,
@faisal_08 wrote:
The software program work good, but when I want to use for switching leby digital module , it create problem.
So the software is ok, but you got problems?
Which problems did you get?
How can we help when the problem is with your hardware (in case the software "works good")?
10-14-2019 05:23 AM
Hello,
Thanks for you reply Sir. The thing is that you see my software when I press switch on front panel then led blink. So the same I wanted for my Led Blink on hardware.
Problem is that I take two channels for LED but when I do DAQ and connect according to the condition only one LED blink on hardware, with open/right or may close/left.
I again attach the hardware loop also, please let me know how to resolve it.
Thanks BEst Regards
Faisal
10-14-2019 05:36 AM
10-14-2019 06:24 AM
Sir,
This the picture of system , I am using H-Bridge and adruino is just use to give power 5V to H-Bridge and NI module NI 9401.
Sir, I think you understand what my software do, please specify is it correct or not. The Same led of /on i want on the led light.
10-14-2019 07:45 AM
Hi faisal,
@faisal_08 wrote:
Sir,
This the picture of system , I am using H-Bridge and adruino is just use to give power 5V to H-Bridge and NI module NI 9401.
Still no electronic schematic. How should we know about your copper wiring from looking at that image?
@faisal_08 wrote:
Sir, I think you understand what my software do, please specify is it correct or not. The Same led of /on i want on the led light.
No, I cannot open LV2019 VIs right now. I'm using LV2017…
10-14-2019 08:06 AM
Hello Sir,
I attached the schematic wiring diagram of all the equipment and Sir, if possible please see the VIs also.
Kindly looking for your reply and also thankful to your help and support.
Best Regards
faisal
10-14-2019 08:20 AM - edited 10-14-2019 08:21 AM
Hi Faisal,
your schematic hides the most parts…
Are the LEDs connect in the right direction? (They are diodes…)
How is this resistor connected?
What is the input of your H bridge? What are the output pins?
Why do you need an Arduino as power supply? Does it provide enough power to drive your H bridge and LEDs?
Does the H bridge work correctly when you connect their input pins directly with needed signals (either +5V or GND)?
10-14-2019 08:44 AM
Sir,
The connection are
1. H-Bridge is connected to 5V and one wire to ground from arduino. Arduino is use for giving supply of 5V to H-Bridge.
2. Problem is that when I press switch than one channel work fine and one LED is ON for given time according to program but other LED does not operate when I press other switch, the software shows the LED ON in front panel but not on board.
3. Input of the H_Bridge is given by user from front panel through NI 9401 and output is goes to LED.
4. If possible please check the both VI sir then it will be clear sir.
Thank you so much for your support sir.
Best regards,
Faisal
10-14-2019 02:10 PM - edited 10-14-2019 02:13 PM
Hi Faisal,
now I could look at your VI:
Why has the "Right" button no label?
Why don't you use AutoCleanup?
Why is the event structure excluded from AutoCleanup?
What is the purpose of all those BuildArray/Search1DArray/IndexArray operations inside the event cases? Why not just use a Select node to determine the output values???
Why do you set a timeout value for the tiemout event and also use the WaitUntilMultiple in the loop?
Why do you wire the millisecond timer value as TimeTarget into the ElapsedTime ExpressVI?
Why do you open and close that DO task in each iteration???
Did you examine any example VIs from example finder?
Problem is that when I press switch than one channel work fine and one LED is ON for given time according to program but other LED does not operate when I press other switch, the software shows the LED ON in front panel but not on board.
That's why I ask for a electronics schematic all the time: is that other LED wired correctly?
You still aren't able to show such a schematic…