espruino/EspruinoDocs — pull request #9 by zigrin (2014-01-09 00:10:23+00:00)
Title: Added support for multiple sensors on a single OneWire bus.

This is not only saving pins but should also use less memory for multiple sensors.

Functionally it is compatible with your implementation but logically it is different in that connect() returns a bus object instead of a sensor.
If you are happy with these changes then I can update documentation too. Here are some quick examples:
```
var sensorBus = require("DS18B20").connect(A1);
sensorBus.getTemp(); //gets reading from the first sensor
sensorBus.getSensors().length; //number of sensors
var kitchen = sensorBus.getSensors()[1];
sensorBus.getTemp(kitchen);
```