Need a working example that runs with 1.4.0


#1

I am using FrontPanel Version 1.4.0 and the libraries for Modelsim 6e.

The sim/fpga side of things is working perfectly. I am having trouble with the C programming.

I am spending a lot of time trying to find examples that work with the latest release from Opal Kelly (which I believe I am running).

I get different instructions based on what official Opal Kelly doc I look at, for example:

This page describes how to use the DLL and configure compiling and use new function names:

http://opalkelly.com/wiki/frontpanel3deltas

“Do NOT link with okFrontPanel.lib anymore.”

This page describes a different way of using the API (1.4.0):

http://www.opalkelly.com/library/FrontPanelAPI/

“and also add the library okFrontPanel.lib to be linked with your project.”

Do I link ‘okFrontPanel.lib’ or not?

Anyhow,

Can you post a simple (full and working) C example showing how to configure the PLL and activate a trigger using 1.4.0 and VS 2003 (7.1)?

I am using the XEM3001. Thank you!


#2

I answered most of my questions with the example that came with the latest 1.4.0, in this folder:

C:\Program Files\Opal Kelly\FrontPanel\Samples\DES\CxxDLL

Your product is great, but your documentation leads me on wild goose chases.

These examples are goldmines, they are very appreciated.


#3

Hi Slagerij–

You’ve found the FrontPanel-3 Deltas document which describes the differences between previous releases (1.4.0 and earlier) and the yet-to-be-released FrontPanel 3.0. This release is in the hands of beta users which is why we posted the Deltas document.

We very much appreciate you pointing out any inconsistencies in the documentation and will strive to avoid them. Unfortunately, with the changes between FP-1 and FP-3, we’ll have to do something to make it clear what version people should refer to.

In all cases, we highly recommend using the DLL rather than the static library. FP-3 does not include a static library anymore. We found the compatibility issues to outweigh any of the benefits. e.g. there are even compatibility issues between VS 6/7/8. So, we now include the DLL as the only way to incorporate the API.

FP-3 does, however, include a new C++ wrapper around the DLL. All samples have been ported to this new style and it is very simple. After you call to load the DLL, the C++ wrapper looks exactly like the previous static library did. The difference is that you now build part of the library with your code (okFrontPanelDLL.cpp).

Straight “C” users will be happy to know that you don’t need C++ either. The existing C calls will work just fine. You can rename okFrontPanelDLL.c and the compiler will be smart enough to not build the C++ wrapper portion (using an #ifdef to remove any C++ stuff).

We’re now tidying up a few documentation changes and hope to release FP-3 this week. Customers using our XEM3001 or XEM3010 will get the upgrade for free, including the new firmware.