NI Labs Discussions

cancel
Showing results for 
Search instead for 
Did you mean: 

LabVIEW FPGA Advanced Interface Tools Discussion

Welcome to the NI Labs LabVIEW FPGA Advanced Interface Tools project. This thread is intended to foster discussion about the project, so please post your questions, comments, suggestions and bug reports and I'll be happy to respond.

These tools provide two additional FPGA Host Interfaces that contain additional dynamic features to provide truly Dynamic Host Interfaces for LabVIEW FPGA. The host interfaces are open-source, written completely in LabVIEW with calls directly into the NI-RIO driver (NiFpga.dll), and are theoretically cross platform (no more need for C API on Linux or Mac OS X). To download and find out more details about the interfaces, please go to LabVIEW FPGA Advanced Interface Tools.


Mike Lyons

Staff Application Engineering Specialist

0 Kudos
Message 1 of 53
(23,718 Views)

Mike,

Seems to be LV2011 only, is that correct?  Any chance of a 2010 conversion, or are these dependent on something new in 2011?

Looks like a cool concept, hope I can try it out.

Thanks,

Mike

0 Kudos
Message 2 of 53
(5,605 Views)

Hi Mike,

There's nothing in the interface that made it 2011 specific. I originally created it in 2010, but I had a little more difficulty optimizing the VIs in 2010 for source only and inline. I've overcome those difficulties and included a single installer that will work for both 2010 and 2011. Since versions prior to 2010 do not support source only and inline, I do not have any intention of supporting versions prior to 2010 even though theoretically it could be done.

The new installer incorporates an error code file, examples (which are searchable in NI Example Finder), and a few random bug fixes which did not get tracked. Moving forward, bug fixes will be tracked in the document a bit better. In addition to the new installer, the document has been revamped with a lot more information on the reason and need for these types of interfaces. Hopefully in the future, I'll have to time to add some Getting Started and Example videos.

Regards,

Mike Lyons

0 Kudos
Message 3 of 53
(5,605 Views)

Hi

Some installation feedback for others:

To get this to install you need to decompress it first. Also the .zip contains some very long path lengths which Windows7 refused to decompress, so I decompressed it to C: first.

HTH

JC

(LV2011)

0 Kudos
Message 4 of 53
(5,605 Views)

Hi SuperDuperCooper,

Yes you will need to decompress the zip file before installing. I use a different zip utility than Windows, and it doesn't seem to have any problems with the file path.

I did confirm that Windows has difficulties with the file path length if extracting to a file path that is already somewhat long (my test case was extracting to LabVIEW's user.lib directory), but I didn''t have any difficulties in extracting to the desktop or the download directories.

Thank you for reporting this to the discussion forum.

Regards,

Mike Lyons

0 Kudos
Message 5 of 53
(5,605 Views)

Hi all,

I had no troubles unszipping in Win 7, but I got an installer error. After moving the Installer files to C:\National Instruments Downloads it installed without problems.

Andreas Stark
LabVIEW Lead @ Rocket Factory Augsburg
0 Kudos
Message 6 of 53
(5,605 Views)

Hi Mike,

Thanks for putting together such a wonderful tool.  You can't imagine how great this interface is to us ... we do LabVIEW FPGA programming all the time and we used to comb through all of our "Read/Write FPGA Control" elements by hand to link up our FPGA control and indicator references.  When you have 10 controls, this might not be significant.  But when you have over 100, yikes.  Thanks for saving our wrists.

One thing I did notice tho, I think in the Fully Dynamic example, the code can't seem to detect FXP controls or indicators from the FPGA code.  Looking into your FPGA Read by name polymorphic vi, I don't see FXP as one of the menu options.  Will FXP be supported in the future?

-John Wu

Riobotics Consulting

0 Kudos
Message 7 of 53
(5,605 Views)

Hi John,

Thanks for the nice words. Were you having those issues even when specifying your Open FPGA Reference to use Dynamic Mode?

As far as the tools here are concerned, there is no support for FXP and no plans on supporting FXP. The reason for the lack of support of FXP is because the DLL that gets called doesn't have FXP functions. I don't remember if potential FXP support was impossible given the current state of the DLL or if it was just too tedious and cumbersome to deal with in order to expose in this tool. Since there is an easy way to work around the FXP problem (discussed below), I made the decision to not provide direct FXP capability because of the extra mess and potential performance hit that would be taken to support the wide variety of word and integer lengths that are possible with FXP numbers.

As far as the work around is concerned, on the FPGA you use the FXP to Integer Cast or Integer to FXP Cast depending on which direction the data is going and on the host you use the corresponding Integer to FXP Cast or FXP to Integer Cast. These cast functions allow you to specify the FXP data type on the Integer to FXP Cast so that the data type maps correctly to the originating FXP. These cast functions simply preserve the bit information by allowing a user to change where the decimal point (or should this be called a binary point) is located. This means that you'll always have an integer data type on your FPGA interface. If you follow my suggestions in the whitepaper and make a user driver API instead of using the interface directly in the higher level VIs, you can still expose whatever data type makes since to the user (possibly even just DBL). It would be possible to follow the same implementation of some of our drivers and allow a user to set a value according to DBL and then force them to read back the value if they want to see how it coerced (RFSA IQ Rate is one of example of this).

Hope this helps!

Regards,

0 Kudos
Message 8 of 53
(5,605 Views)

Hi Mike,

Thanks for your fast reply.  Theorectically the dynamic mode introduced in LV2010 kinda works, but my engineers have told me that sometimes they'll still get broken wires.  We were under pressure to close a project at that time, so we had to make a choice between spending time to investigate the issue, or brute forcing using static references.  We chose the latter.

As far FXP goes, I'm sure the workaround you suggested will work.  We've been programming FPGA since LabVIEW 7.1 when there was no FXP to use (gasp), so we're used to doing some conversion work on the host side.  Thanks!

-John

0 Kudos
Message 9 of 53
(5,605 Views)

Hi Mike

thanks for this great tool. Unfortunately there is a problem and I don't see any reason for that.

My background is a Custom Device for VeriStand I want to create. The FPGA should write measurement data into a Target-to-Host DMA ("DMA_PWM"). After creating the bitfile I load it to the FPGA Interface tool but especially this FIFO does not appear. All other VeriStand specific stuff is available (see screenshot). Do you have any idea why?

When opening the .lvbitx file with a text editor I can see all three DMA definitions. I attached this file in case you want to verify.

Thanks in advance.

FIFO missing.png

0 Kudos
Message 10 of 53
(5,605 Views)