i2cmux7 2.0.0.0
i2cmux7.h File Reference

This file contains API for I2C MUX 7 Click Driver. More...

#include "drv_digital_out.h"
#include "drv_digital_in.h"
#include "drv_i2c_master.h"

Go to the source code of this file.

Data Structures

struct  i2cmux7_t
 I2C MUX 7 Click context object. More...
 
struct  i2cmux7_cfg_t
 I2C MUX 7 Click configuration object. More...
 

Macros

#define I2CMUX7_CHANNEL_DISABLE   0x00
 I2C MUX 7 channel selection values.
 
#define I2CMUX7_CHANNEL_0   0x08
 
#define I2CMUX7_CHANNEL_1   0x09
 
#define I2CMUX7_CHANNEL_2   0x0A
 
#define I2CMUX7_CHANNEL_3   0x0B
 
#define I2CMUX7_CHANNEL_4   0x0C
 
#define I2CMUX7_CHANNEL_5   0x0D
 
#define I2CMUX7_CHANNEL_6   0x0E
 
#define I2CMUX7_CHANNEL_7   0x0F
 
#define I2CMUX7_CHANNEL_NUM_MASK   0x07
 
#define I2CMUX7_DEV_ADDR_A2A1A0_000   0x70
 I2C MUX 7 device address setting.
 
#define I2CMUX7_DEV_ADDR_A2A1A0_001   0x71
 
#define I2CMUX7_DEV_ADDR_A2A1A0_010   0x72
 
#define I2CMUX7_DEV_ADDR_A2A1A0_011   0x73
 
#define I2CMUX7_DEV_ADDR_A2A1A0_100   0x74
 
#define I2CMUX7_DEV_ADDR_A2A1A0_101   0x75
 
#define I2CMUX7_DEV_ADDR_A2A1A0_110   0x76
 
#define I2CMUX7_DEV_ADDR_A2A1A0_111   0x77
 
#define I2CMUX7_MAP_MIKROBUS(cfg, mikrobus)
 MikroBUS pin mapping.
 

Enumerations

enum  i2cmux7_return_value_t { I2CMUX7_OK = 0 , I2CMUX7_ERROR = -1 }
 I2C MUX 7 Click return value data. More...
 

Functions

void i2cmux7_cfg_setup (i2cmux7_cfg_t *cfg)
 I2C MUX 7 configuration object setup function.
 
err_t i2cmux7_init (i2cmux7_t *ctx, i2cmux7_cfg_t *cfg)
 I2C MUX 7 initialization function.
 
err_t i2cmux7_set_channel (i2cmux7_t *ctx, uint8_t ch_sel, uint8_t ch_slave_addr)
 I2C MUX 7 set channel function.
 
err_t i2cmux7_read_channel (i2cmux7_t *ctx, uint8_t *ch_sel)
 I2C MUX 7 read channel function.
 
void i2cmux7_reset_device (i2cmux7_t *ctx)
 I2C MUX 7 reset device function.
 
err_t i2cmux7_generic_write (i2cmux7_t *ctx, uint8_t reg, uint8_t *tx_buf, uint8_t tx_len)
 I2C MUX 7 I2C writing function.
 
err_t i2cmux7_generic_read (i2cmux7_t *ctx, uint8_t reg, uint8_t *rx_buf, uint8_t rx_len)
 I2C MUX 7 I2C reading function.
 

Detailed Description

This file contains API for I2C MUX 7 Click Driver.

Enumeration Type Documentation

◆ i2cmux7_return_value_t

I2C MUX 7 Click return value data.

Predefined enum values for driver return values.

Enumerator
I2CMUX7_OK 
I2CMUX7_ERROR