LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

FPGA basic advise

I currently have a crio with variouos modules available and would like to simulate an engines sensors with it. To begin with i would like to simulate the timing wheel signal (square wave with 3 pulses missing every 12). With very little knowledge of LabView i created two VI's, one for the fpga which simply had the ouput to the DIO module and the Host VI which simulated the signal and sent it to the FPGA VI.
 
 
The results were random.
 
Please could someone tell me what to read or give me some advise
 
Many Thanks.
0 Kudos
Message 1 of 6
(6,458 Views)
Hi ern
 
A few thoughts.  The code looks fine, however how have you got the system set up?
The 9401 requires that you connect up pin 14(DIO 0 and pin 1(COM).  Is that how you have connected the DIO module?
Do you get any signal off the module on this line?
What do you mean by "random"?
 
Thanx
 
AdamB
Applications Engineering Team Leader | National Instruments | UK & Ireland
Message 2 of 6
(6,444 Views)

Hi

Thanks fo looking at it, i have the IO correctly set up, if i manually toggle the output it works fine, when the program is run the ouput toggles reletively slowly ie around 0.5 second and randomly. There is a timing issue somewhere.

0 Kudos
Message 3 of 6
(6,436 Views)
Hey ern,
 
Well I had a look at this again and the timing issue could be something to do with the fact that you have the software controlling the speed of DIO changes.
I have attached a diagram and the code of a small VI that you could put on the FPGA that will do the timing for you.
All you need to do is to create a host (for the cRIO) vi that will calculate the delay in us between each edge for your crankshaft output whenever the revs control is changes.
(1/(Revs*12))^6 = us.
That should do it.
So compile the code onto the FPGA and create a HOST vi (needs to be on the cRIO target) that will controll just the revs.
 
Give that a go?
Get back to me if you need more information
Thanx
 
AdamB
 
Applications Engineering Team Leader | National Instruments | UK & Ireland
Download All
Message 4 of 6
(6,433 Views)

Hi ern,

Was this any help?

How's the application going?

AdamB

Applications Engineering Team Leader | National Instruments | UK & Ireland
Message 5 of 6
(6,413 Views)

Hi

Sorry i havnt had a chance yet, i am currently at the formula student event where we won the CRIO, thanks for you time i will let you know when i get back.

Cheers Erny

0 Kudos
Message 6 of 6
(6,407 Views)