Traceback (most recent call last):
File "testSDL_DS3231.py", line 31, in
ds3231.write_now()
File "/home/pi/Documents/examples/opcn2/RTC_SDL_DS3231/SDL_DS3231.py", line 222, in write_now
self.write_datetime(datetime.now())
File "/home/pi/Documents/examples/opcn2/RTC_SDL_DS3231/SDL_DS3231.py", line 217, in write_datetime
dt.isoweekday(), dt.day, dt.month, dt.year % 100)
File "/home/pi/Documents/examples/opcn2/RTC_SDL_DS3231/SDL_DS3231.py", line 180, in write_all
self._write(self._REG_SECONDS, seconds_reg)
File "/home/pi/Documents/examples/opcn2/RTC_SDL_DS3231/SDL_DS3231.py", line 97, in _write
self._bus.write_byte_data(self._addr, register, data)
IOError: [Errno 16] Device or resource busy
When I run it on spyder, it says no SDL_DS3231 module found.
Where am I wrong. Please let me know how to correct this. Thank you.
Hello, Thank you for the library. I am using a ds3231 with raspberry pi 2. When I run the testSDL_DS3231.py , I get the following in my terminal.
pi@PC-17-0302:~/Documents/examples/opcn2/RTC_SDL_DS3231 $ python testSDL_DS3231.py
Test SDL_DS3231 Version 1.0 - SwitchDoc Labs
Program Started at:2017-06-13 14:58:38
Traceback (most recent call last): File "testSDL_DS3231.py", line 31, in
ds3231.write_now()
File "/home/pi/Documents/examples/opcn2/RTC_SDL_DS3231/SDL_DS3231.py", line 222, in write_now
self.write_datetime(datetime.now())
File "/home/pi/Documents/examples/opcn2/RTC_SDL_DS3231/SDL_DS3231.py", line 217, in write_datetime
dt.isoweekday(), dt.day, dt.month, dt.year % 100)
File "/home/pi/Documents/examples/opcn2/RTC_SDL_DS3231/SDL_DS3231.py", line 180, in write_all
self._write(self._REG_SECONDS, seconds_reg)
File "/home/pi/Documents/examples/opcn2/RTC_SDL_DS3231/SDL_DS3231.py", line 97, in _write
self._bus.write_byte_data(self._addr, register, data)
IOError: [Errno 16] Device or resource busy
When I run it on spyder, it says no SDL_DS3231 module found.
Where am I wrong. Please let me know how to correct this. Thank you.