mongoose-os-libs / i2c

Other
4 stars 6 forks source link

Implement linux-i2c vesion of I2C library for use in Ubuntu platform #9

Closed pimvanpelt closed 5 years ago

pimvanpelt commented 5 years ago

This adds i2c.dev_no to mos.yml, which instructs the driver to open /dev/i2c-? as backend for I2C. It then implements a Linux I2C version of the driver, using ioctl() to select the slave, and read/write to write to it.

Notes:

Basic functionality works -- reading and writing, SMBUS register read/write, and scanning.

rojer commented 5 years ago

https://github.com/cesanta/mos-libs/commit/d2806f768ea9742c036fb3214499f7958adc1695