LabVIEW Embedded

cancel
Showing results for 
Search instead for 
Did you mean: 

Can you use ncurses library in LV embedded software?

Has anyone had any success in including ncurses library into the LV embedded package?  I'm trying to create a Unix console application that I will need some simple graphical capabilities but still beyond that of just using a print statement.  Esentially I will need to draw a simulated keyboard and change the key colors to show that the key has been hit in what is to become a keyboard test. 
I know this can be done with C and the ncurses library can be utilized but when I try to even use it in an "Inline C Node" it gives me linking errors to the .h file.  I have redownloaded cygwin and included the library among the others suggested by NI and still no luck.  It seems to post an error for every line in the library file (ncurses.h) even though I have included it in the Inline C Node. 
Any help or suggestions of other methods would be great!
Thanks,
Dave
0 Kudos
Message 1 of 4
(7,072 Views)
Hi Dave,

If this doesn't resolve it, you can paste the error message to your reply so I can take a look. You might be missing an include path. Try adding  -I<path to ncurses.h> to the compiler flags in the build specifications window. <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
--
Michael P
National Instruments
0 Kudos
Message 2 of 4
(7,069 Views)
Michael,
I added the compiler flag as you sugested.  I still get the same error.

The Error is:
In file included from C:\Program Files\National Instruments\LabVIEW 8.5\CCodeGen\include\main\ncurses.h:127,
                 from C:\Documents and Settings\lehman.d\Desktop\Unix Target Test\Unix_Console\Console_Application\unix_console_test.c:34:
/usr/include/unctrl.h:1: error: parse error before '/' token
In file included from C:\Documents and Settings\lehman.d\Desktop\Unix Target Test\Unix_Console\Console_Application\unix_console_test.c:34:
C:\Program Files\National Instruments\LabVIEW 8.5\CCodeGen\include\main\ncurses.h:703: error: parse error before '(' token
C:\Program Files\National Instruments\LabVIEW 8.5\CCodeGen\include\main\ncurses.h:752: error: parse error before '(' token

It seems to have a problem with the syntax in the actual ncurses.h file.  ncurses calls the unctrl.h file so I added a copy of that which also seems to have an syntax issue.  I'll attach my .h file in case it is any help.
Thanks,
Dave
0 Kudos
Message 3 of 4
(7,065 Views)
Dave,

The error appears to indicate that gcc doesn't like this parameter in ncurses.h:

(*)(int)

I recommend that you take LabVIEW out of the equation for now and investigate why gcc is choking on that parameter. Once that is resolved, then you should be able to include this library in a LabVIEW application.
--
Michael P
National Instruments
0 Kudos
Message 4 of 4
(7,038 Views)