This is an old revision of the document!
WMPRO, WMMINI FW >= 1.0 WMMEGA FW >= 2.0
Read a temperature from a device on the onewire bus
$device_id: Array of 8 integers containing the unique onewire device id. This is optional and it will otherwise send a wildcard to read the first device that response, which would work if only one temperature sensor was present.
A float value containing the temperature read from the sensor
<pre><? $res=ow_read_temp(); print("Temperature is ".$res); $dev=array(0xA0,0x00,0x00,0x04,0x80,0x57,0x77); $res=ow_read_temp($dev); print("Temperature for device is ".$res); ?>
ow_first() - Get the first device on the bus
ow_next() - Get next device on bus
ow_read() - Read a byte from a device
ow_reset() - Reset the onewire bus
ow_write() - Write to onewire bus