CAN Controller DLL with Java Application. Unable to open CAN port

I am creating a Java application that controls a Controller Area Network (CAN) controller via a vendor-supplied can.dll file.

can.dll contains a function bool openPort(DWORD memAddr) that allows the application to establish connection with the CAN controller.

I wrote a C++ test application, loaded can.dll via LoadLibrary and found this function to be working as it should, i.e. it returns true.

However, in my Java application, calling this via JNI or JNA returns false.

I hope someone can help me with this problem as I have been trying to fix this problem for more than a week.

Thanks :) JL


I think you might want to look at sockets as an alternative or other IPC solutions.

Need Your Help

Qt Deployement C++ set linked file to executable directory

javascript html qt

I'am working on a touchscreen app with Qt on win32, and i need to set the url of my linked file to the executable directory. (Like if i could do "./file")