From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How to tranfer menu ring selection from host vi to FPGA vi?

I'm using 7830R to generate pulse signals from multiple DIOs.  In the FPGA vi, I added a menu ring which has two states, default is to run a pulse generation code in a for loop and stopped after the certain number of signals have been generated; while the 1 state is to run this pulse generation code in a while loop continously until I hit the stop buttion.  Running the FPGA vi itself is OK as I expected.

 

The problem is how to put this menu ring selection in the host vi, so that whatever I choose from the front panel@ host vi can be transferred to the FPGA vi and do the job?

 

I tried to use the same menu ring in host vi, and add this "acquistion mode" element in the read/write control where I also input the pulse width, duty cycle etc in the host Vi.  However, by doing this, I was only be able to get the default fixed view mode work, when I chose "continous", it only give me one pulse.

 

Searched around but found no answer, so I have to ask here.  Please excuse me for this newbie question. Thanks.

0 Kudos
Message 1 of 2
(2,181 Views)

Mr.

 

It sounds like the two modes are being selected ok, but there may be something wrong in the logic of your code.  I have used enum's and menu rings before to specify values between host and FPGA. 

 

Some thoughts.  You need to expose the menu ring selector by placing it on your FPGA front-panel.  You can then use the "Read Write Control.vi" on the FPGA interface menu to set the value of the control from the host.  Also, if you have modified the menu ring in the host but not on the FPGA, you will have problems as the host will be able to select items that don't exist on the FPGA.  You should probably make a type def from your control so that modifications are properly propogated between targets.

  

Can you post your host and FPGA code, or a trimmed-down version of what you are trying to do? 

 

-cb

0 Kudos
Message 2 of 2
(2,146 Views)