Advertisement
Help Keep Boards Alive. Support us by going ad free today. See here: https://subscriptions.boards.ie/.
If we do not hit our goal we will be forced to close the site.

Current status: https://keepboardsalive.com/

Annual subs are best for most impact. If you are still undecided on going Ad Free - you can also donate using the Paypal Donate option. All contribution helps. Thank you.
https://www.boards.ie/group/1878-subscribers-forum

Private Group for paid up members of Boards.ie. Join the club.

calling a C++ executable from java?

  • 18-01-2005 03:14PM
    #1
    Registered Users, Registered Users 2 Posts: 978 ✭✭✭


    Hi all,
    For my final year project, I have a java server running on a computer receiving robot direction instructions from a client. Does anyone know of any java code to call a C++ executable file? The C++ code will control and send the directions instruction to a NI-DAQ card


Comments

  • Closed Accounts Posts: 92 ✭✭tempest


    Glenman wrote:
    Hi all,
    For my final year project, I have a java server running on a computer receiving robot direction instructions from a client. Does anyone know of any java code to call a C++ executable file? The C++ code will control and send the directions instruction to a NI-DAQ card
    Runtime.getRuntime().exec(pass,my, programname, and, arguments, in, here);


  • Registered Users, Registered Users 2 Posts: 14,318 ✭✭✭✭Raam


    or if you really want to show off, you could make a dll file instead of an exe and then use JNI.

    http://www.inonit.com/cygwin/jni/helloWorld/ has a sample of how to do it. Might be a bit dated, but I think it has links to the latest stuff from sun


  • Registered Users, Registered Users 2 Posts: 978 ✭✭✭Glenman


    Thanks guys, got it working
    Glenman


Advertisement