B4J Question jSerial library update

peacemaker

Expert
Licensed User
Longtime User
Hi, All and @Erel

Is it possible to update the library ?
I hope this may help to improve work under Linux. There is a non-catchable error that occurs very often.

terminate called after throwing an instance of 'std::bad_alloc'
what(): std::bad_alloc

Maybe possible to make errors catchable ?

p.s. and maybe jBluetooth can be updated ?
 
Last edited:

peacemaker

Expert
Licensed User
Longtime User
Ha !

2.9.6 Latest
2023-12-15

Features​

  • Added RISC-V support. Precompiled binaries for riscv32 and riscv64 are included in jssc distribution #143
  • Information about certain errors in native code execution is now passed on to Java as exception #96

Update is needed for sure.
 
Last edited:
Upvote 0

peacemaker

Expert
Licensed User
Longtime User
Is it OK in the .XML of the lib?
<dependsOn>slf4j-jdk14-1.7.35</dependsOn>

With latest jssc-2.9.6.jar, renamed into jssc.jar, now the AStream_Error event gives the error (under Linux):

Error: (SerialPortException) jssc.SerialPortException: Port name - /dev/ttyUSB0; Method name - getInputBufferBytesCount; Exception type - Native exception occurred: IO input/output error.
No app crash now ! It's for sure better than before.
 
Last edited:
Upvote 0

peacemaker

Expert
Licensed User
Longtime User
Under Windows always were and is OK.
Troubles were under Linux only - crash at USB-COM plugging, the system non-catchable error was at some Linux (at another PC - it was OK).
No idea why.

Now with the latest .jar - no those error (as in the first post of the thread) at all, no crash!
And now the catchable error in AStream_Error is OK to workaround.

Under Win all is OK as before.
 
Upvote 0
Top