dac3 2.0.0.0
Public function

Functions

void dac3_cfg_setup (dac3_cfg_t *cfg)
 Config Object Initialization function.
 
DAC3_RETVAL dac3_init (dac3_t *ctx, dac3_cfg_t *cfg)
 Initialization function.
 
void dac3_set_out_voltage (dac3_t *ctx, uint16_t output)
 Set output voltage function.
 
void dac3_send_command (dac3_t *ctx, uint8_t cmd)
 Send command function.
 
void dac3_write_all_mem (dac3_t *ctx, uint16_t value)
 Send command function.
 

Detailed Description

Function Documentation

◆ dac3_cfg_setup()

void dac3_cfg_setup ( dac3_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.

◆ dac3_init()

DAC3_RETVAL dac3_init ( dac3_t * ctx,
dac3_cfg_t * cfg )

Initialization function.

Parameters
dac3Click object.
cfgClick configuration structure.

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

◆ dac3_send_command()

void dac3_send_command ( dac3_t * ctx,
uint8_t cmd )

Send command function.

Parameters
ctxClick object.
cmdSPI command.

@description This function sends a command to the click module using SPI communication.

◆ dac3_set_out_voltage()

void dac3_set_out_voltage ( dac3_t * ctx,
uint16_t output )

Set output voltage function.

Parameters
ctxClick object.
outputOutput voltage.

@description This function sets the output voltage on the click module terminal.

◆ dac3_write_all_mem()

void dac3_write_all_mem ( dac3_t * ctx,
uint16_t value )

Send command function.

Parameters
ctxClick object.
cmdSPI command.

@description This function configures the click module.

Note
In order to use this function properly you need to initialize the dac_cfg object in ctx.