Tracker01: Difference between revisions
From Federal Burro of Information
Jump to navigationJump to search
No edit summary |
(→Code) |
||
Line 53: | Line 53: | ||
== Code == | == Code == | ||
== References == | |||
* https://arduino.stackexchange.com/questions/24888/counting-adc-samples-using-a-light-sensor |
Revision as of 03:02, 22 April 2018
Hardware
1 pi zero
1 INA219 current sensor.
1 HTU21 temp/humidity sensor
1 ADS1015 with two Photo Resistors
System config
All devices are i2c.
Address Device
pi@raspberrypi:~/Adafruit_Python_ADS1x15/examples $ i2cdetect -l i2c-1 i2c bcm2835 I2C adapter I2C adapter pi@raspberrypi:~/Adafruit_Python_ADS1x15/examples $ i2cdetect -F 1 Functionalities implemented by /dev/i2c-1: I2C yes SMBus Quick Command yes SMBus Send Byte yes SMBus Receive Byte yes SMBus Write Byte yes SMBus Read Byte yes SMBus Write Word yes SMBus Read Word yes SMBus Process Call yes SMBus Block Write yes SMBus Block Read no SMBus Block Process Call no SMBus PEC yes I2C Block Write yes I2C Block Read yes pi@raspberrypi:~/Adafruit_Python_ADS1x15/examples $ i2cdetect 1 WARNING! This program can confuse your I2C bus, cause data loss and worse! I will probe file /dev/i2c-1. I will probe address range 0x03-0x77. Continue? [Y/n] y 0 1 2 3 4 5 6 7 8 9 a b c d e f 00: -- -- -- -- -- -- -- -- -- -- -- -- -- 10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 40: 40 41 -- -- -- -- -- -- 48 -- -- -- -- -- -- -- 50: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 60: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 70: -- -- -- -- -- -- -- -- pi@raspberrypi:~/Adafruit_Python_ADS1x15/examples $