Trouble with PipeIn in LabView

I am having trouble with implementing PipeIn in LabView.

Basically I am building an arbitrary wave generator using the XEM5010 with a DAC. I implemented a simple dual port RAM on the FPGA. I used PipeIn to write a waveform into the RAM and then output data from the RAM to the DAC. When I use the provided FrontPanel software to setup PipeIn (in XML, using okFilePipe), my program works fine.

However, when I call the WritetoPipeIn function from a LabView program I wrote myself (after importing the okFrontPanel dll into LabView), I always get a -9 error code returned by the WritetoPipeIn VI. I can successfully configure my FPGA in this LabView program. A simpler LabView program that only uses Trigger in and Wire In functions also worked fine. But I just can’t get the WritetoPipeIn function to work.

My control program is really straight forward. It just has two TriggerIns that reset some counters in my program and IODELAY respectively, two WireIns that set the delay and width of the waveform respectively. And PipeIn is for loading a waveform into the RAM.

I just can’t figure out why the FrontPanel control works but the LabView program doesn’t. I really can’t see where it went wrong in LabView. I have the correct endpoint address, I set the length to 14 (only passing in 14 bytes), I am passing in an Array Data Pointer to a 1D array of 14 unsigned bytes to the data parameter (the type for this parameter for the WritetoPipeIn Call Library Function Node was originally somehow C-String which I changed to Array of unsigned 8 bit integer).

I would really appreciate if someone could tell me what could be the problem with my PipeIn implementation in LabView. Thanks!

Error Code -9 (defined in the okFrontPanelDLL.h) is an InvalidEndpoint. I would suspect your LabView code is not setting the endpoint address correctly.

— Begin quote from Opal Kelly Support;3218

Error Code -9 (defined in the okFrontPanelDLL.h) is an InvalidEndpoint. I would suspect your LabView code is not setting the endpoint address correctly.

— End quote

Thank you so much! That was the problem! 0x80 is not 80 in decimal. That was one stupid yet easy to fix mistake:)

A somewhat unrelated question.

I have no problem importing the FrontPanel dll into LabView 2009 or 2010. But I can’t seem to do so in LabView 8.5 which is the one I want to use. I followed the steps posted on this forum. After hitting next on “Configure include paths and preprocessor definitions”, I get this message, "The Import Shared Library tool cannot get exported function names from the input shared library file. Please check the input shared library file whether it contains functions. "

Anyone else has similar problem?

I’ve done this with LabView 8.6, and used “WIN32; DLL_ENTRY = __stdcall;
okDLLEXPORT; UINT32=unsigned int” to the preprocessor definitions to get it to work.

dear YalePhysics.
i am having trouble with read from pipe out.
can you show me how to use it?
do you have an example about that?
can you share it to me?
thank you
best regard,
my email: ndhoang@iop.vast.ac.vn