I try to access 24C32N (87=x57) memory of DS3231 (104) for test.
I can't do it.
Do you have any idea for it?
Thanks
Armen
https://images-na.ssl-images-amazon.com ... L._AC_.jpg
(Chip is ATHYC502-24C32N)
storage capacity 32K
VCC= Tested with 5.0 and 3.3 V
Pull up =10K
reduce freq=400000 to 100000 (Effectless)
Try with this :
http://docs.micropython.org/en/latest/l ... e.I2C.html
and this:
https://github.com/micropython-Chinese- ... ster/misc/
and this:
viewtopic.php?t=2874
and this:
https://github.com/peterhinch/micropython_eeprom
and this:
https://github.com/mcauser/micropython-tinyrtc-i2c
Code: Select all
MicroPython v1.12 on 2019-12-20; ESP module with ESP8266
Type "help()" for more information.
>>> from machine import Pin, I2C
>>> i2c = I2C(scl=Pin(2), sda=Pin(0), freq=400000)
>>> i2c.scan()
[32, 63, 87, 104]
# 63 == x3F access to LCD is OK
# 32 == x20 access to PCF is OK
# 104 == x68 access to RTC not test
>>> i2c.readfrom_mem(0x57, 0, 50)
b'\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff'
>>> i2c.writeto_mem(0x57, 0, b'hello world')
>>> i2c.readfrom_mem(0x57, 0, 50)
b'\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff3210'
>>>