ESP8266
Public Member Functions | Static Private Member Functions | Static Private Attributes | List of all members
TwoWire Class Reference
Inheritance diagram for TwoWire:
Stream Print

Public Member Functions

 TwoWire ()
 
void begin (int sda, int scl)
 
void pins (int sda, int scl) __attribute__((deprecated))
 
void begin ()
 
void begin (uint8_t)
 
void begin (int)
 
void setClock (uint32_t)
 
void beginTransmission (uint8_t)
 
void beginTransmission (int)
 
uint8_t endTransmission (void)
 
uint8_t endTransmission (uint8_t)
 
size_t requestFrom (uint8_t address, size_t size, bool sendStop)
 
uint8_t requestFrom (uint8_t, uint8_t)
 
uint8_t requestFrom (uint8_t, uint8_t, uint8_t)
 
uint8_t requestFrom (int, int)
 
uint8_t requestFrom (int, int, int)
 
virtual size_t write (uint8_t)
 
virtual size_t write (const uint8_t *, size_t)
 
virtual int available (void)
 
virtual int read (void)
 
virtual int peek (void)
 
virtual void flush (void)
 
void onReceive (void(*)(int))
 
void onRequest (void(*)(void))
 
size_t write (unsigned long n)
 
size_t write (long n)
 
size_t write (unsigned int n)
 
size_t write (int n)
 
- Public Member Functions inherited from Stream
 Stream ()
 
void setTimeout (unsigned long timeout)
 
bool find (const char *target)
 
bool find (uint8_t *target)
 
bool find (const char *target, size_t length)
 
bool find (const uint8_t *target, size_t length)
 
bool find (char target)
 
bool findUntil (const char *target, const char *terminator)
 
bool findUntil (const uint8_t *target, const char *terminator)
 
bool findUntil (const char *target, size_t targetLen, const char *terminate, size_t termLen)
 
bool findUntil (const uint8_t *target, size_t targetLen, const char *terminate, size_t termLen)
 
long parseInt ()
 
float parseFloat ()
 
size_t readBytes (char *buffer, size_t length)
 
size_t readBytes (uint8_t *buffer, size_t length)
 
size_t readBytesUntil (char terminator, char *buffer, size_t length)
 
size_t readBytesUntil (char terminator, uint8_t *buffer, size_t length)
 
String readString ()
 
String readStringUntil (char terminator)
 
- Public Member Functions inherited from Print
 Print ()
 
int getWriteError ()
 
void clearWriteError ()
 
size_t write (const char *str)
 
size_t write (const char *buffer, size_t size)
 
size_t printf (const char *format,...) __attribute__((format(printf
 
size_t size_t print (const __FlashStringHelper *)
 
size_t print (const String &)
 
size_t print (const char[])
 
size_t print (char)
 
size_t print (unsigned char, int=10)
 
size_t print (int, int=10)
 
size_t print (unsigned int, int=10)
 
size_t print (long, int=10)
 
size_t print (unsigned long, int=10)
 
size_t print (double, int=2)
 
size_t print (const Printable &)
 
size_t println (const __FlashStringHelper *)
 
size_t println (const String &s)
 
size_t println (const char[])
 
size_t println (char)
 
size_t println (unsigned char, int=10)
 
size_t println (int, int=10)
 
size_t println (unsigned int, int=10)
 
size_t println (long, int=10)
 
size_t println (unsigned long, int=10)
 
size_t println (double, int=2)
 
size_t println (const Printable &)
 
size_t println (void)
 

Static Private Member Functions

static void onRequestService (void)
 
static void onReceiveService (uint8_t *, int)
 

Static Private Attributes

static uint8_t rxBuffer []
 
static uint8_t rxBufferIndex = 0
 
static uint8_t rxBufferLength = 0
 
static uint8_t txAddress = 0
 
static uint8_t txBuffer []
 
static uint8_t txBufferIndex = 0
 
static uint8_t txBufferLength = 0
 
static uint8_t transmitting = 0
 
static void(* user_onRequest )(void)
 
static void(* user_onReceive )(int)
 

Additional Inherited Members

- Protected Member Functions inherited from Stream
int timedRead ()
 
int timedPeek ()
 
int peekNextDigit ()
 
long parseInt (char skipChar)
 
float parseFloat (char skipChar)
 
- Protected Member Functions inherited from Print
void setWriteError (int err=1)
 
- Protected Attributes inherited from Stream
unsigned long _timeout
 
unsigned long _startMillis
 

Constructor & Destructor Documentation

TwoWire::TwoWire ( )

Member Function Documentation

int TwoWire::available ( void  )
virtual

Implements Stream.

void TwoWire::begin ( int  sda,
int  scl 
)
void TwoWire::begin ( void  )
void TwoWire::begin ( uint8_t  address)
void TwoWire::begin ( int  address)
void TwoWire::beginTransmission ( uint8_t  address)
void TwoWire::beginTransmission ( int  address)
uint8_t TwoWire::endTransmission ( void  )
uint8_t TwoWire::endTransmission ( uint8_t  sendStop)
void TwoWire::flush ( void  )
virtual

Implements Stream.

void TwoWire::onReceive ( void(*)(int)  function)
void TwoWire::onReceiveService ( uint8_t *  inBytes,
int  numBytes 
)
staticprivate
void TwoWire::onRequest ( void(*)(void)  function)
void TwoWire::onRequestService ( void  )
staticprivate
int TwoWire::peek ( void  )
virtual

Implements Stream.

void TwoWire::pins ( int  sda,
int  scl 
)
int TwoWire::read ( void  )
virtual

Implements Stream.

size_t TwoWire::requestFrom ( uint8_t  address,
size_t  size,
bool  sendStop 
)
uint8_t TwoWire::requestFrom ( uint8_t  address,
uint8_t  quantity 
)
uint8_t TwoWire::requestFrom ( uint8_t  address,
uint8_t  quantity,
uint8_t  sendStop 
)
uint8_t TwoWire::requestFrom ( int  address,
int  quantity 
)
uint8_t TwoWire::requestFrom ( int  address,
int  quantity,
int  sendStop 
)
void TwoWire::setClock ( uint32_t  frequency)
size_t TwoWire::write ( uint8_t  data)
virtual

Implements Print.

size_t TwoWire::write ( const uint8_t *  data,
size_t  quantity 
)
virtual

Reimplemented from Print.

size_t TwoWire::write ( unsigned long  n)
size_t TwoWire::write ( long  n)
size_t TwoWire::write ( unsigned int  n)
size_t TwoWire::write ( int  n)

Member Data Documentation

uint8_t TwoWire::rxBuffer
staticprivate
uint8_t TwoWire::rxBufferIndex = 0
staticprivate
uint8_t TwoWire::rxBufferLength = 0
staticprivate
uint8_t TwoWire::transmitting = 0
staticprivate
uint8_t TwoWire::txAddress = 0
staticprivate
uint8_t TwoWire::txBuffer
staticprivate
uint8_t TwoWire::txBufferIndex = 0
staticprivate
uint8_t TwoWire::txBufferLength = 0
staticprivate
void(* TwoWire::user_onReceive)(int)
staticprivate
void(* TwoWire::user_onRequest)(void)
staticprivate