开发者

Send command to device with Java

开发者 https://www.devze.com 2023-03-09 11:55 出处:网络
I want to connect magnetic card reader, send commands and get responses with Java (COM Port) in Windows XP. I have .h file & dll. I want use dll functions. How can I con开发者_JAVA技巧nect or send

I want to connect magnetic card reader, send commands and get responses with Java (COM Port) in Windows XP. I have .h file & dll. I want use dll functions. How can I con开发者_JAVA技巧nect or send device?


You will need to use JNI (Java Native Interface), google it for details. You probably will have to write some wrappers around the DLL in C first before JNI can use it.


As an alternative, you may be able to bind to the dll using JNA.

0

精彩评论

暂无评论...
验证码 换一张
取 消