mcp23s17 (community library)
Summary
Name | Value |
---|---|
Name | mcp23s17 |
Version | 0.2.0 |
Installs | |
License | The MIT License (MIT) |
Author | Zachary J. Fields zachary_fields@yahoo.com |
URL | https://github.com/zfields/mcp23s17-wiring/ |
Repository | https://github.com/zfields/mcp23s17-wiring.git |
Download | .tar.gz |
All Versions | 0.2.0, 0.1.0 |
A C++ wrapper for the Microchip MCP23S17. This library provides an object based interface to an Microchip MCP23S17 connected via SPI. The object allows you to utilize the GPIO expansion functionality via the Wiring API (i.e. digitalRead, digitalWrite, pinMode, etc...).
Example Build Testing
Device OS Version:
This table is generated from an automated build. Success only indicates that the code compiled successfully.
Library Read Me
This content is provided by the library maintainer and has not been validated or approved.
A C++ wrapper for the Microchip MCP23S17.
SAMPLES:
/****************/
/* Hello Blinky */
/****************/
#include "mcp23s17/mcp23s17.h"
const int LED_PIN = 7;
mcp23s17 gpio_x(mcp23s17::HardwareAddress::HW_ADDR_0); // All addressing pins set to GND
void setup (void) {
gpio_x.pinMode(LED_PIN, mcp23s17::PinMode::OUTPUT);
}
void loop (void) {
gpio_x.digitalWrite(LED_PIN, mcp23s17::PinLatchValue::HIGH);
delay(500);
gpio_x.digitalWrite(LED_PIN, mcp23s17::PinLatchValue::LOW);
delay(500);
}
TODO:
Implement interrupts
ATTRIBUTION:
- The makefiles used for compiling the Google Unit Test where taken from Google.
LICENSE:
- The MIT License (MIT). Refer to the LICENSE file for more details.
Browse Library Files