Skip to content

rtborg/espidf_mcp23s01

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

MCP23S08 SPI Expander driver for espidf

Original version: Alex Fabre

Driver Description

The driver is intended to work with any board which supports SPI. The user is required to provide implementation of the function int (*spi_transfer)(uint8_t *tx_buffer, uint8_t tx_len, uint8_t *rx_buffer, uint8_t *rx_len). Initialization sequence is descibed in the driver header file.

espidf example application

File main.c shows a minimal application to read and write data to the GPIO expander:

  • SPI initialization
  • spi_transfer function implementation
  • MCP23S08 initialization
  • FreeRTOS task which reads GPIO port and toggles its value

About

Minimal driver for MCP23S01 GPIO expander

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages