NeuronRobotics / nrjavaserial

A Java Serial Port system. This is a fork of the RXTX project that uses in jar loading of the native code.
Other
345 stars 143 forks source link

Added /dev/ttyAMA to known serial ports list for RPi #86

Closed Rallymen007 closed 7 years ago

Rallymen007 commented 8 years ago

Quick addition to ease the use of this library on RPi projects. This just convenience to avoid having to set the property on every launch, and has been successfully tested with the openHAB aleoncean binding.

Rallymen007 commented 8 years ago

By mistake I made a second push on the same branch.

It contains a bit of logging inside loadResource. This log line would show an error message if liblockdev is missing, and then rethrow the exception to signal higher level code. The log is the standard Linux load error: /tmp/libNRJavaSerial_HF_osmc_0/libNRJavaSerial_HF.so: liblockdev.so.1: cannot open shared object file: No such file or directory So maybe it's a good idea to log this to show the user some feedback, in case the library is loaded outside of a system package.

madhephaestus commented 7 years ago

cool, thanks for this!