fix for issue #346

Some bugs have been introduced with onewire precision changes (ce9a803e3e9c51b485551d004f5c93705648ce17)