LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Communication with C-Program

I wonder how a labview program could
communicate with a C-program. In
particular the labview program should be running and sending characters.
The C-program should receive these characters and print them out in real
time (like a client/server application).
Thanks for your help.
0 Kudos
Message 1 of 4
(3,027 Views)
Felix wrote:

> I wonder how a labview program could
> communicate with a C-program. In
> particular the labview program should be running and sending characters.
> The C-program should receive these characters and print them out in real
> time (like a client/server application).
> Thanks for your help.

Check out the manuals on the following.
CIN - "Code Interface Node" allows for minor C code to be called.
CLF - "Call Library Function" - Allows for calling C functions from a DLL.

One or the other should solve the problems.

Kevin Kent
0 Kudos
Message 2 of 4
(3,027 Views)
Hi Kevin,
you are describing how to CALL a C-program from Labview. But the C-program
should run independently and get messages from the labview program. Could
you give me a hint how to solve this? Thanks.



"Kevin B. Kent" wrote:
>This is a multi-part message in MIME format.>--------------0D491E523979B093532952E1>Content-Type:
text/plain; charset=us-ascii>Content-Transfer-Encoding: 7bit>>Felix wrote:>>>
I wonder how a labview program could>> communicate with a C-program. In>>
particular the labview program should be running and sending characters.>>
The C-program should receive these characters and print them out in real>>
time (like a client/server application).>> Thanks for your help.>>Check out
the manuals on the following.
>CIN - "Code Interface Node" allows for minor
C code to be called.>CLF - "Call Library Function" - Allows for calling C
functions from a DLL.>>One or the other should solve the problems.>>Kevin
Kent>>--------------0D491E523979B093532952E1>Content-Type: text/x-vcard;
charset=us-ascii;> name="Kevin.Kent.vcf">Content-Transfer-Encoding: 7bit>Content-Description:
Card for Kevin B. Kent>Content-Disposition: attachment;> filename="Kevin.Kent.vcf">>begin:vcard
>n:Kent;Kevin>tel;fax:972-477-4462>tel;work:972-477-4468 >x-mozilla-html:TRUE>url:http://www.usa.alcatel.com>org:Alcatel
USA;OXC Hardware Development>version:2.1>email;internet:Kevin.Kent@usa.alcatel.com>title:Engineering
Technician>adr;quoted-printable:;;MS OLXDV=0D=0A1000 coit Rd;Plano;Texas;75075-5802;United
States>x-mozilla-cpt:;16128>fn:Kevin Kent>end:vcard>>--------------0D491E523979B093532952E1-->
0 Kudos
Message 3 of 4
(3,027 Views)
Learn how to implement a DDE port in your C program. This will allow
bi-directional communication with Labview. Alternatively, less efficiently
but maybe easier, use TCP- it depends what you have more documentation on.
From the Labview side it's easy to handle either TCP or DDE communication
with another program, with either side operating as the server, once you
decide which way to go.

The mechanics of either method from the C side are probably better suited to
discussion in one of the C newsgroups.

Felix wrote in message
news:3a5a0246@newsgroups.ni.com...
>
> Hi Kevin,
> you are describing how to CALL a C-program from Labview. But the C-program
> should run independently and get messages from the labview program. Could
> you
give me a hint how to solve this? Thanks.
0 Kudos
Message 4 of 4
(3,027 Views)