mux9 2.1.0.0
mux9.h File Reference

This file contains API for MUX 9 Click Driver. More...

#include "drv_digital_out.h"
#include "drv_spi_master.h"
#include "spi_specifics.h"

Go to the source code of this file.

Data Structures

struct  mux9_t
 MUX 9 Click context object. More...
 
struct  mux9_cfg_t
 MUX 9 Click configuration object. More...
 

Macros

#define MUX9_SELECT_CH_1   1
 mux9_set MUX 9 channel selection flags.
 
#define MUX9_SELECT_CH_2   2
 
#define MUX9_SELECT_CH_3   3
 
#define MUX9_SELECT_CH_4   4
 
#define MUX9_SELECT_CH_5   5
 
#define MUX9_SELECT_CH_6   6
 
#define MUX9_SELECT_CH_7   7
 
#define MUX9_SELECT_CH_8   8
 
#define MUX9_SET_DATA_SAMPLE_EDGE   SET_SPI_DATA_SAMPLE_EDGE
 Data sample selection.
 
#define MUX9_SET_DATA_SAMPLE_MIDDLE   SET_SPI_DATA_SAMPLE_MIDDLE
 
#define MUX9_MAP_MIKROBUS(cfg, mikrobus)
 MikroBUS pin mapping.
 

Enumerations

enum  mux9_return_value_t { MUX9_OK = 0 , MUX9_ERROR = -1 }
 MUX 9 Click return value data. More...
 

Functions

void mux9_cfg_setup (mux9_cfg_t *cfg)
 MUX 9 configuration object setup function.
 
err_t mux9_init (mux9_t *ctx, mux9_cfg_t *cfg)
 MUX 9 initialization function.
 
void mux9_reset (mux9_t *ctx)
 MUX 9 reset function.
 
void mux9_enable (mux9_t *ctx)
 MUX 9 enable function.
 
void mux9_disable (mux9_t *ctx)
 MUX 9 disable function.
 
err_t mux9_generic_write (mux9_t *ctx, uint8_t data_in)
 MUX 9 data writing function.
 
err_t mux9_active_channel (mux9_t *ctx, uint8_t sel_ch)
 MUX 9 active channel function.
 

Detailed Description

This file contains API for MUX 9 Click Driver.

Enumeration Type Documentation

◆ mux9_return_value_t

MUX 9 Click return value data.

Predefined enum values for driver return values.

Enumerator
MUX9_OK 
MUX9_ERROR