CAN Controller DLL with Java Application. Unable to open CAN port.
Posted
by Joseph Lim
on Stack Overflow
See other posts from Stack Overflow
or by Joseph Lim
Published on 2010-06-18T07:46:49Z
Indexed on
2010/06/18
7:53 UTC
Read the original article
Hit count: 307
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
© Stack Overflow or respective owner