mcp23008

Library functions for the MSP23008.

Author Rob Jansen, Copyright © 2024..2024, all rights reserved.
Adapted-by
Compiler 2.5r8

Description

Library functions for the MSP23008. The port and individual
             port bits are all accessed using pseudo variables. In this way
             accessing the pins is the same as accessing PIC IO pins. 
             The provided pin functions are (x = 0..7):
                 mcp23008_pinx_direction  using value INPUT/OUTPUT
                 mcp23008_pinx_polarty    using value ENABLED/DISABLED
                 mcp23008_pinx            using value HIGH/LOW
                 mcp23008_latchx          using value HIGH/LOW
                 mcp23008_pull_upx        using value ENABLED/DISABLED
              Port pseudo variables, activating all pins at once:
                 mcp23008_port_direction  Bits 0 = output, 1 = input
                 mcp23008_port_polarity   Bits 0 = normal, 1 = inverted
                 mcp23008_port            Bits 0 = LOW, 1 = HIGH
                 mcp23008_latch           Bits 0 = LOW, 1 = HIGH
                 mcp23008_pull_up         Bits 0 = DISABLED, 1 = ENABLED
              All other functions are provided via procedures and functions as
              described in the Public API section.


Sources

Microchip MCP23008/MCP23008 8-bit I/O Expander with serial interface.
         Datasheet DS20001919F.


Dependencies

No dependency found



Summary

Global variables/contants

Procedures

Private

Functions

Private

API details

Global variables/contants

Procedures

Private

Functions

Private

Related samples

Here are the list of samples which use this library:

16f182516f1825_mcp23008.jal