In general, data transferred through I2C are bytes and thus should have type uint8_t, not char. Also convert uint8_t ptrs to void ptrs
This patch fix the bug in _i2c_receive. The STOP signal should be generated before the reading from the data register because the receiving of the next byte will be initiated by reading the data register (dev->D).