LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

fpga vi with two loop timer possible ?

Hi I have a question about a FPGA vi. I try to create a  bit pattern 0-7 and give at the  dio output on my FPGA Card.  The first 7 pattern should  have a duration of 2 us and the last pattern should have a duration of 6 us. For this  I use a loop timer in a for loop. If I say I want all pattern to have the same duration this works fine. For the other solution I made two for loops each with own loop timer, but this doesn't work properly. Is it allowed to use several loop timer??  Or has anyone another idea how to solve this Problem??

Thanks...

Download All
0 Kudos
Message 1 of 5
(2,720 Views)
You could use an array of durations (with the first seven elements the same) and have your For Loop auto-index and feed the timer.
Jim
You're entirely bonkers. But I'll tell you a secret. All the best people are. ~ Alice
For he does not know what will happen; So who can tell him when it will occur? Eccl. 8:7

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

Just a quick addition: Using array constants on an FPGA wastes a lot of gates. For better FPGA usage you should try to avoid arrays as much as possible (e. g. by using the onboard memory or by calculating values on the fly).

 

Regards,

Jochen

0 Kudos
Message 3 of 5
(2,687 Views)

Hi

 

with the time array it works fine.

 

Jochen, thank you also for your advise. I'm new working with FPGA programming. Are there some examples using the onborad memory for such a question??

 

Regards, Irina

0 Kudos
Message 4 of 5
(2,682 Views)

Hi Irina,

 

for a small amount of data an array is not critical, but if you plan to use more data or if your FPGA runs really low of gates, you should consider using block memory access.

Here is a tutorial that covers this topic. An example is attached at the bottom of the document.

 

Kind regards,

Jochen Klier

National Instruments

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