Closed ProphetZero closed 6 months ago
The error codes are all OS-specific unfortunately (which is why these getLastErrorXXX functions exist in the first place). You should be able to use the lastErrorLocation to look up the line number in either SerialPort_Posix.c or SerialPort_Windows.c (depending on your OS, located under src/main/c/{Posix,Windows}
), and that will tell you which OS function call is failing. You can then Google that function to find the meaning of the error code value.
In this specific case, based on the error location, I'm assuming you're on Windows. The error code indicates that you are trying to open a port that is already open.
Suddenly lost connection The application is build for event based Non-blocking interaction. We are only listening for LISTENING_EVENT_DATA_AVAILABLE and LISTENING_EVENT_PORT_DISCONNECT. We are using 115200 as the baud rate.
It happens on both linux and windows.
Is there a place i can see the definition of all the error codes?