PU2CLR PCF8574 Arduino Library  1.0.3
Arduino Library for PCF8574 Device - By Ricardo Lima Caratti
PCF Class Reference

#include <pu2clr_pcf8574.h>

Public Member Functions

uint8_t lookForDevice ()
 Look for PCF8574 device I2C Address. More...
 
void reset ()
 
void setup (uint8_t i2c=DEFAULT_I2C_ADDRESS)
 Starts the PCF8574. More...
 
void write (uint8_t value)
 Sets a value to a given register. More...
 
uint8_t read ()
 Gets the corrent register information. More...
 
uint8_t digitalRead (uint8_t port)
 Reads a given port content (HIGH or LOW) More...
 
void digitalWrite (uint8_t port, uint8_t value)
 Writes HIGH or LOW in a given port (pin) More...
 
bool error ()
 Returns the last wrire or read status. More...
 
void setClock (long freq)
 Sets I2C bus to a given frequency. More...
 

Protected Attributes

uint8_t i2c_address = DEFAULT_I2C_ADDRESS
 Default i2c address. More...
 
int reset_pin = -1
 Digital Arduino pin to control the PCF8574 RESET. More...
 
bool io_error = false
 

Member Function Documentation

◆ reset()

void PCF::reset ( )

Field Documentation

◆ i2c_address

uint8_t PCF::i2c_address = DEFAULT_I2C_ADDRESS
protected

Default i2c address.

◆ reset_pin

int PCF::reset_pin = -1
protected

Digital Arduino pin to control the PCF8574 RESET.

◆ io_error

bool PCF::io_error = false
protected

Referenced by error(), read(), and write().


The documentation for this class was generated from the following files: