HWA
Bare metal programming with style
PCF8574 8-bit I/O expander for I²C bus

Detailed Description

This class implements a PCF8574 8-bit I/O expander for I²C bus.

Header file:

Relatives

Interface

#define PCF HW_PCF8574( interface, twi0, address, 0x27 )

The implementation of this device focuses on code size rather than on speed, so it relies on extern C functions. These functions are declared with HW_DECLARE(...) and defined with HW_IMPLEMENT(...):

HW_DECLARE( PCF ); // Declare the functions that implement the device
HW_IMPLEMENT( PCF ); // Define the functions that implement the device

Constructor for PCF8574

hw|hwa( configure, PCF );
hw( read, PCF );
hw( write, PCF, value );

Modules

 PCF8574 I/O
 
hwa
#define hwa(...)
hwa( action, object [,...] ) stores an action for an object into a HWA context.
Definition: hwa_macros.h:552
HW_DECLARE
#define HW_DECLARE(...)
Declares the functions that implement an object.
Definition: hwa_1.h:526
hw
#define hw(...)
hw( action, object [,...] ) executes an action immediately on an object.
Definition: hwa_macros.h:523
pcf8574.h
PCF8574 8-bit I/O expander for I²C bus.
HW_IMPLEMENT
#define HW_IMPLEMENT(...)
Defines the functions that implement an object.
Definition: hwa_1.h:548