expand4 2.0.0.0
Public function

Functions

void expand4_cfg_setup (expand4_cfg_t *cfg)
 Config Object Initialization function.
 
EXPAND4_RETVAL expand4_init (expand4_t *ctx, expand4_cfg_t *cfg)
 Initialization function.
 
void expand4_enable_output (expand4_t *ctx)
 Enable output function.
 
void expand4_disable_output (expand4_t *ctx)
 Disable output function.
 
void expand4_reset (expand4_t *ctx)
 Clear register function.
 
void expand4_write_data (expand4_t *ctx, uint8_t write_command)
 
void expand4_turn_on_by_position (expand4_t *ctx, uint8_t position)
 

Detailed Description

Function Documentation

◆ expand4_cfg_setup()

void expand4_cfg_setup ( expand4_cfg_t * cfg)

Config Object Initialization function.

Parameters
cfgClick configuration structure.

@description This function initializes click configuration structure to init state.

Note
All used pins will be set to unconnected state.

◆ expand4_disable_output()

void expand4_disable_output ( expand4_t * ctx)

Disable output function.

Parameters
ctxClick object.

@description Function turn off output buffers set PWM pin high

◆ expand4_enable_output()

void expand4_enable_output ( expand4_t * ctx)

Enable output function.

Parameters
ctxClick object.

@description Function turn on output buffers - set PWM pin low

◆ expand4_init()

EXPAND4_RETVAL expand4_init ( expand4_t * ctx,
expand4_cfg_t * cfg )

Initialization function.

Parameters
ctxClick object.
cfgClick configuration structure.

@description This function initializes all necessary pins and peripherals used for this click.

◆ expand4_reset()

void expand4_reset ( expand4_t * ctx)

Clear register function.

Parameters
ctxClick object.

@description Function clear input TPIC6A595 shift register.

◆ expand4_turn_on_by_position()

void expand4_turn_on_by_position ( expand4_t * ctx,
uint8_t position )

@breif Turn on output pin masks by position function

Parameters
ctxClick object.
positionposition from 0 to 7

@description Function turning on output pin masks by position:

  • 0 for D0
  • 1 for D1
  • 2 for D2
  • 3 for D3
  • 4 for D4
  • 5 for D5
  • 6 for D6
  • 7 for D7

◆ expand4_write_data()

void expand4_write_data ( expand4_t * ctx,
uint8_t write_command )

@breif Generic write data function

Parameters
ctxClick object.
write_command8-bit data to write

@description Function write 8-bit data function to TPIC6A595 shift register.