Java Question How to import jamod.jar as Lib?

xky

Member
Licensed User
Longtime User
I have found a modbus Lib "jamod.jar" I want to use it in B4A, I think there mast be a jamod.xml file, but I can't find it.

This is the Lib, Who can tell me how to use it in B4A?
 

Attachments

  • Modbus.zip
    285.1 KB · Views: 393

xky

Member
Licensed User
Longtime User
Now I'm Licenced. :)
I followed the step about generate .xml but failed, the XML is generated but after I put jamod.jar & jamod.xml into Lib, I can't load it.
You may need the file attached in eclipse, but I don't know what's wrong with it.
 

Attachments

  • javacomm20-win32.zip
    266.3 KB · Views: 355

xky

Member
Licensed User
Longtime User
I got the error is "Error parsing libraries"
Can you use Eclipse to do the same as your tour? Maybe I do something wrong.
The Java source code I have posted in attachment.
The .jar file is a Modbus class, is there some lib in B4A the same but I don'e know?
:sign0188:
 
Last edited:

xky

Member
Licensed User
Longtime User
I just understand, it's not a way to convert a .jar to .B4A lib, each member in JAVA class I need to declare again by create a new java project, after that use BADoclet. So if the class is a very big one, it will take a longtime. If I only use a little member in that big class, it's a good way, right?

Do you have idea to convert a big .jar class into B4A lib easily?:icon_clap:
 

oymyakon

Member
Licensed User
Longtime User
dbus

Hi i am trying to implement modbus. i have had some success with jamod over TCP but i am now trying to implement it over Bluetooth serial. for some reason i cannot get the jamod to connect to the serial port i have started. i am getting the bluetooth to connect ok and i have sent data across it but the modbus wont connect. any help would be appreciated.
 

jinyistudio

Well-Known Member
Licensed User
Longtime User
Hi
Could you give me little example code ? tell me how to implement jamod in B4J to read/write slave device with modbus TCP. Tandk's and Merry chrismas !:D

dbus

Hi i am trying to implement modbus. i have had some success with jamod over TCP but i am now trying to implement it over Bluetooth serial. for some reason i cannot get the jamod to connect to the serial port i have started. i am getting the bluetooth to connect ok and i have sent data across it but the modbus wont connect. any help would be appreciated.
 
Top