Error instantiating SerialComManager on Windows 10 32-bit OS

5 views
Skip to first unread message

Alex Olsen

unread,
Aug 10, 2016, 10:34:20 PM8/10/16
to SerialPundit
Hi Rishi,

Thanks for providing and maintaining this great library.

I've developed a Java application with releases on Mac OS X, 32-bit and 64-bit Windows.

I'm using the most recent version of SerialPundit, and I've added the following JAR files to my library classpath:
- sp-core.jar
- sp-hid.jar
- sp-ioctl.jar
- sp-tty.jar
- sp-usb.jar

The application works flawlessly on Mac OS X and 64-bit Windows.

However, when testing the application on Windows 10 32-bit OS I get the following exception when instantiating the SerialComManager:

SEVERE: Error instantiating serial port manager:
com.serialpundit.core.SerialComException: C:\Users\ALEXOL~1\AppData\Local\Temp\sp_tuartx1\spcomwinx86.dll
 at com.serialpundit.serial.internal.SerialComPortJNIBridge.loadNativeLibrary(SerialComPortJNIBridge.java:350)
 at com.serialpundit.serial.SerialComManager.<init>(SerialComManager.java:378)
 at jcu.marinegeophysics.InstrumentCommunications.<init>(InstrumentCommunications.java:115)
 at jcu.marinegeophysics.InstrumentModel.<init>(InstrumentModel.java:118)
 at jcu.marinegeophysics.MainController.initialize(MainController.java:393)
 at javafx.fxml.FXMLLoader.loadImpl(FXMLLoader.java:2548)
 at javafx.fxml.FXMLLoader.load(FXMLLoader.java:2425)
 at jcu.marinegeophysics.MarotteHSConfig.start(MarotteHSConfig.java:37)
 at com.sun.javafx.application.LauncherImpl.lambda$launchApplication1$162(LauncherImpl.java:863)
 at com.sun.javafx.application.PlatformImpl.lambda$runAndWait$175(PlatformImpl.java:326)
 at com.sun.javafx.application.PlatformImpl.lambda$null$173(PlatformImpl.java:295)
 at java.security.AccessController.doPrivileged(Native Method)
 at com.sun.javafx.application.PlatformImpl.lambda$runLater$174(PlatformImpl.java:294)
 at com.sun.glass.ui.InvokeLaterDispatcher$Future.run(InvokeLaterDispatcher.java:95)
 at com.sun.glass.ui.win.WinApplication._runLoop(Native Method)
 at com.sun.glass.ui.win.WinApplication.lambda$null$148(WinApplication.java:191)
 at java.lang.Thread.run(Thread.java:745)
Caused by: com.serialpundit.core.SerialComException: Can not get shared library spcomwinx86.dll resource as stream from sp-tty.jar file !
 at com.serialpundit.serial.internal.SerialComPortJNIBridge.loadNativeLibrary(SerialComPortJNIBridge.java:347)
 ... 16 more

Any help in correcting this exception will be greatly appreciated. Let me know if you require any additional info.

Cheers,
Alex Olsen

Rishi Gupta

unread,
Aug 10, 2016, 11:03:15 PM8/10/16
to SerialPundit

Alex Olsen

unread,
Aug 10, 2016, 11:25:24 PM8/10/16
to SerialPundit
Thanks for the prompt reply. The above issue is resolved.

However, a new exception has arisen inside sp-tty.jar when trying to list available serial ports on 32-bit Windows 10:

SEVERE: Error collecting available serial ports.
com.serialpundit.core.SerialComException: The system cannot find the file specified.
 at com.serialpundit.serial.internal.SerialComPortJNIBridge.listAvailableComPorts(Native Method)
 at com.serialpundit.serial.internal.SerialComPortsList.listAvailableComPorts(SerialComPortsList.java:134)
 at com.serialpundit.serial.SerialComManager.listAvailableComPorts(SerialComManager.java:524)
 at jcu.marinegeophysics.InstrumentCommunications.refreshSerialPortList(InstrumentCommunications.java:389)
 at jcu.marinegeophysics.InstrumentModel.<init>(InstrumentModel.java:126)

 at jcu.marinegeophysics.MainController.initialize(MainController.java:393)
 at javafx.fxml.FXMLLoader.loadImpl(FXMLLoader.java:2548)
 at javafx.fxml.FXMLLoader.load(FXMLLoader.java:2425)
 at jcu.marinegeophysics.MarotteHSConfig.start(MarotteHSConfig.java:37)
 at com.sun.javafx.application.LauncherImpl.lambda$launchApplication1$162(LauncherImpl.java:863)
 at com.sun.javafx.application.PlatformImpl.lambda$runAndWait$175(PlatformImpl.java:326)
 at com.sun.javafx.application.PlatformImpl.lambda$null$173(PlatformImpl.java:295)
 at java.security.AccessController.doPrivileged(Native Method)
 at com.sun.javafx.application.PlatformImpl.lambda$runLater$174(PlatformImpl.java:294)
 at com.sun.glass.ui.InvokeLaterDispatcher$Future.run(InvokeLaterDispatcher.java:95)
 at com.sun.glass.ui.win.WinApplication._runLoop(Native Method)
 at com.sun.glass.ui.win.WinApplication.lambda$null$148(WinApplication.java:191)
 at java.lang.Thread.run(Thread.java:745)

Alex Olsen

unread,
Aug 12, 2016, 8:33:35 PM8/12/16
to SerialPundit
I have found a fix to the latest exception. It was not originating from the serialpundit jar files. Thanks for your help Rishi.
Reply all
Reply to author
Forward
0 new messages