working on restoring thread I2C slave API as a library