Hey all,
it's been a while with no news on this topic. Well, Good news everyone! I made a very simple sml binding which reads power values in the SML format from a serial port (this may be an optical reader for USB or RS232 for example, see
www.volkszaehler.org for more information). No need to use scripting anymore.
Unfortunately I am not sure how much more time I can spend into development. I would be very happy to hand my work over to someone who wants to test and maybe evolve and release the binding. If you are interested, take a look into the attached sources (contains a compiled binding addon jar under target). The binding is based on the serial binding and adds some SML parsing.
The corresponding items look like this:
Number Power_EnergyToPlant "EnergyToPlant: [%s]" {sml="/dev/ttyUSB0:ENERGYTOPLANT"}
Number Power_EnergyFromPlant "EnergyFromPlant: [%s]" {sml="/dev/ttyUSB0:ENERGYFROMPLANT"}
Number Power_CurrentUsage "CurrentUsage: [%s]" {sml="/dev/ttyUSB0:CURRENTPOWER"}
TODO: does not unload correctly on config refresh.
More TODOs in the code...
Enjoy!
PS: don't forget to add something like "-Dgnu.io.rxtx.SerialPorts=/dev/ttyUSB0 " to your OpenHAB startup script, see Serial Binding!