LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

NI sbRIO9631 Generate Sine wave on analog output pin.

Solved!
Go to solution

Hello,

I am using NI sbRIO-9631 to generate a sine wave on one of on board analog output pin (ModB/AO0) and read the same signal on analog input pin (ModA/AI0) by connecting AO0 to AI0 physically. I have created a FPGA Target Sine Wave.vi to implement same functionality. Also am trying to read the analog values from AI0 pin and plot it on a waveform chart.

Now I want to understand, how to validate the generated analog data on both analog input and output pin? Attached are the screenshots of project structure, target VIs etc.

I am new to LabVIEW FPGA so need help to check whether the VIs are correctly implemented or NOT? Suggestions from NI community are most welcome!

Thanks.

0 Kudos
Message 1 of 5
(3,035 Views)
Solution
Accepted by topic author Ravi@arav

Hi Ravi,

 

some thoughts:

- your "ReadAnalogVoltage.vi" should be placed in the sbRIO target (in the RT target)

- right now you output a constant value on AO0: the output of that sine function will NEVER change

- I don't know how fast those AI/AO pins are on your sbRIO, but I would place a small wait inside the FPGA loop…

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 2 of 5
(3,011 Views)

Hi GerdW,

Thanks for sharing your thoughts. So based on that, I created an another project but this time i used a sine wave generator express VI in FPGA Target. The functionality is same as the previous one and now i can see same values being read by ModA/AI0 as per the indicator to ModB/AO0. It seems like the data is valid.

But when I Run "Read Analog RT.vi", The sbRIO9631 gets hanged up and show a message that the target is now disconnected. I tried by configuring  FPGA VI and also with the generate Bitfile (Sine Wave2 Vi) option as shown in screenshot "Configure_FPGA_Target_VI_in_Analog_Read_RT_VI.png". Sometimes it shows an error saying NI rt.vi or similar file got corrupted. After these errors, its hard to connect and run VIs on sbRIO. Only option remain is power on/off the device. 

Can you help to understand why its behaving like this?

I have attached the screenshots for same.

0 Kudos
Message 3 of 5
(3,003 Views)

Hi Ravi,

 

unfortunately I cannot help with your current issues…

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 4 of 5
(2,997 Views)

oh...well may i know any particular reason? or any other suggestion if you have?  🙂

0 Kudos
Message 5 of 5
(2,991 Views)