10-14-2009 05:17 AM
Dear all,
I am using NI PXI FPGA module, PXI-7833R. Which is having 96 Digital IOs. In my application i want to synchronize all IOs, and generating PWM waveform with user diffined phase difference. I tried to run each IO in separate while loop but it is creating synchnonization problem. Is there any way i can synchronize and generate PWM out put with phase shift.
--Vishnu
10-14-2009 11:44 AM
put all of yor pwm generation code in the same loop so all the IO get written at the same time. I would write a subvi like the image below then put as many instances of this in the loop as you need. This example has phase control and a midpoint trigger (you may not need the trigger).
10-22-2009 12:50 AM
Dear Steven,
Thanks for help. One thing i would like to know that, this will be like parallel loop only, Is it? As i understand if we make subvi and use it in a single loop. It will work like parallel vi for each IO in a one parent loop.
Second thing i want to know that this scheme, can i use for simple Digital IO cards?
Thanks
--Vishnu
10-23-2009 12:55 PM
If you make this into a sub vi, set the vi properties to "reentrant execution". Then make a copy for as many channels of PWM you need. Then they will all run in parallel. you can place them all in side of one loop. Yes you can use a simple DIO module. The only limitation of course is the speed of the DIO module.
10-27-2009 12:09 AM
Thank you very much. Presently the system is in used. I will try this option and come to you again.
--Vishnu