simple DS18B20 thermometer
This flow uses Johnny5 and an Arduino board with ConfigurableFirmata that includes OneWire. A DS18B20 sensor is connected to pin 4 of the Arduino board The debug node displays the temperature in Celcius
French version
Ce flux utilise Johnny5 et une carte Arduino avec le programme ConfigurableFirmata incluant l'option OneWire. Un capteur DS18B20 est connecté à la broche 4 de la carte Arduino (voir câblage ci-dessous)
Le noeud de debug affiche la température mesurée.
[{"id":"1c458ed.275e271","type":"tab","label":"Simple DS18B20","disabled":false,"info":""},{"id":"96d42626.cf48f","type":"debug","z":"1c458ed.275e271","name":"","active":false,"console":"false","complete":"payload","x":570,"y":360,"wires":[]},{"id":"9aab8a1f.1be2b8","type":"johnny5","z":"1c458ed.275e271","name":"DS18B20","func":"var temperature = new five.Temperature({\n controller: \"DS18B20\",\n pin: \"4\",\n freq: 1000\n });\n \ntemperature.on(\"data\", function() {\n freq = 1000,\n node.send({topic: \"temperature\", payload: this.celsius});\n});\n \n","board":"410d023d.6bd37c","noerr":0,"x":340,"y":360,"wires":[["96d42626.cf48f"]]},{"id":"410d023d.6bd37c","type":"nodebot","z":"","name":"","username":"","password":"","boardType":"firmata","serialportName":"/dev/ttyACM0","connectionType":"local","mqttServer":"","socketServer":"","pubTopic":"","subTopic":"","tcpHost":"","tcpPort":"","sparkId":"","sparkToken":"","beanId":"","impId":"","meshbluServer":"https://meshblu.octoblu.com","uuid":"","token":"","sendUuid":""}]