The slave address is "global" to the open file. You can open the "/dev/i2c" more than once and set a different address for each open file. The caveat on using read/write is that the a stop occurs in each read() and write(). It you need a repeated start with no stop between operations, then you need to use the ioctl(I2C_RDWR) form. There are a ... program to generate a student marksheet using file read and write operation Shell script to perform operations like display, list, make directory and copy, rename, delete, edit file Program that performs file read, write, update and display operations
write() – Used by both master and slave to send data on the I2C bus. available() – Used by both master and slave to determine the number of bytes in the data they are receiving. read() – Reads a byte of data from the I2C bus. SetClock() – Used by the master to set a specific clock frequency.