AnsweredAssumed Answered

How to talk with RTC hardware by Python?

Question asked by Jack BK on Feb 8, 2017
Latest reply on Feb 9, 2017 by Jack BK

I am using DT6 custom board from Variscite . This board is connect with DART MX6 board. DT6 in below link


I need to handle the RTC hardware on DT6 board by Python. This RTC named ISL12057. I google some info and I understand as follows.


- ISL12057 is same as DS1307. There is a library of Python for DS1307 as link 


I try this Python library, but I do not understand this library well. So I have some questions as below. Can you answer them? I appreciate your support.


1. As I list in `/dev/`, it has `i2c-0`, `i2c-1`, `i2c-2`. I do not know which I2C that connect to my RTC. I tried 3 of them by `smbus.SMBus(0)`, `smbus.SMBus(1)`, `smbus.SMBus(2)`, there are 2 kinds of error.


1.1 IOError: [Errno 16] Device or resource busy


1.2 IOError: [Errno 5] Input/output error


So, firstly, how can I solve `1.1` or `1.2` to talk with my RTC?


2. I have no experience with Python that can talk with RTC hardware. so, if my usage of DS1307 library for my ISL12057 is not correct, could you tell me another way?


3. ISL12057 has an interrupt function at each second or each minute. In Python, can we detect that interrupt when it is asserted?