DS1307 interfacing with sparkfun's the thing
Posted: Mon Aug 20, 2018 3:02 pm
hi,
I am trying to interface Grove-RTC module with ESP32 the thing. it has DS1307 chip on it, so im trying to use adafruit's urtc.py module
[code]
from machine import I2C, Pin
import urtc
i2c = I2C(scl = Pin(22), sda = Pin(21))
rtc = urtc.DS1307(i2c)
rtc.datetime()
[/code]
and i get this error
[code]
Traceback (most recent call list):
File "<stdin>", line 1, in <module>
File "urtc.py", line 60, in datetime
OSError: [Errno 19] ENODEV
[/code]
whenever i try to use i2c.scan i get empty []
what should i do?
I am trying to interface Grove-RTC module with ESP32 the thing. it has DS1307 chip on it, so im trying to use adafruit's urtc.py module
[code]
from machine import I2C, Pin
import urtc
i2c = I2C(scl = Pin(22), sda = Pin(21))
rtc = urtc.DS1307(i2c)
rtc.datetime()
[/code]
and i get this error
[code]
Traceback (most recent call list):
File "<stdin>", line 1, in <module>
File "urtc.py", line 60, in datetime
OSError: [Errno 19] ENODEV
[/code]
whenever i try to use i2c.scan i get empty []
what should i do?