Syntax
virtual int read();
ContentsIndex
PreviousUpNext
TwoWire::read Method
TwoWire Class | Example
Syntax
virtual int read();
Description

Reads a byte of data which are sent from master to slave or from slave to master. The master makes requests by using requestFrom().

Returns

The byte of data read.

Example
#include <Wire.h>
void setup()
{
    Wire.begin();
}
void loop()
{
    Wire.requestFrom(0x27,6);
    while((Wire.available()))
    {
        int c = Wire.read();
    }
}
File

Wire.h

Class