hamishcunningham/pi-tronics — pull request #4 by stoduk (2014-06-11 13:39:33+00:00)
Title: Fix dameon handling and BAT_GOOD calculation

Fixes issues discussed over email:

- BAT_GOOD calculation was rounding down values to nearest integer, so in some cases BAT_LOW and BAT_GOOD were the same value (and in all cases BAT_GOOD was lower than it should have been)

- daemon handling meant that it could start a deamon even if it was already running, and also it wouldn't properly kill a process in a bad state

See separate commits for more details, and test logs.