Projects/HotTubTemp: Difference between revisions
< Projects
(Created page with "==Hardware== *CampZone2019 badge 'I-PANE' *Waterproof DS18B20 with 1K5 pullup on expansion VCC,GND,SDA *Case *M12 Gland [picture] ==Software== <nowiki> import onewire...") ย |
No edit summary ย |
||
(One intermediate revision by the same user not shown) | |||
Line 7: | Line 7: | ||
[picture] | [picture] | ||
==Firmware Setup== | |||
<nowiki> | |||
cp -r firmware/python_modules/sha2017/onewire firmware/python_modules/campzone2019/</nowiki> | |||
==Software== | ==Software== |
Latest revision as of 20:40, 4 July 2021
Hardware
- CampZone2019 badge 'I-PANE'
- Waterproof DS18B20 with 1K5 pullup on expansion VCC,GND,SDA
- Case
- M12 Gland
[picture]
Firmware Setup
cp -r firmware/python_modules/sha2017/onewire firmware/python_modules/campzone2019/
Software
import onewire ds=onewire.ds18x20.DS18X20(onewire.OneWire(machine.Pin(4))) roms=ds.scan() def update(): global ds global roms rgb.clear() rgb.text(str(system.get_vcc_bat())) time.sleep(0.5) ds.convert_temp() rgb.clear() rgb.text(str(ds.read_temp(roms[0]))[0:5]) while(1): update() time.sleep(10)