@György-Farkas said in Restarting I2C without reboot:
What does this mean precisely? (For example this "the I2C port locks up" ???)
Simplified Software flow:
size = 1
addr = 0x0E ## this is my control register - set to 1 when arduino has data to share
update_flag = i2c.readBytes(devAddres, addr, size)
if update_flag > 0 or first_run_flag > 0:
first_run_flag = 0
addr = 0x20
counter_1_val = i2c.readBytes(devAddres, addr, size)
... then i read through a whole bunch of other data registers and write to sql db. Once the last register is read then the arduino clears the update flag and we cycle through every 300ms or so
This runs perfectly for many hours and then no matter which register is read i still get the last value of the last register read no matter which address i get or set. Nothing is sent to the arduino on the i2c bus but there is still a response on the i2c.readBytes() function.
At this point even i2cset and i2cget return the same value as python call does. Resetting the arduino at this time does not help either
This only happens with the arduino dock address 0x08 - the oled and RTC still work fine.
Can anyone suggest a way to reset the onion I2C without rebooting? <-- i would like to restart /dev/i2c-0 to see if this module is stuck
A lot of grey hair and some worry about the reliabilty of my product... :O