efuse5 2.1.0.0
eFuse 5 Click Driver

API for configuring and manipulating eFuse 5 Click driver. More...

Topics

 eFuse 5 Instruction Byte List
 List of Instruction Byte of eFuse 5 Click driver.
 
 eFuse 5 Registers Settings
 Settings for registers of eFuse 5 Click driver.
 
 eFuse 5 MikroBUS Map
 MikroBUS pin mapping of eFuse 5 Click driver.
 

Functions

void efuse5_cfg_setup (efuse5_cfg_t *cfg)
 eFuse 5 configuration object setup function.
 
err_t efuse5_init (efuse5_t *ctx, efuse5_cfg_t *cfg)
 eFuse 5 initialization function.
 
err_t efuse5_default_cfg (efuse5_t *ctx)
 eFuse 5 default configuration function.
 
err_t efuse5_write_byte (efuse5_t *ctx, uint8_t inst, uint8_t data_in)
 eFuse 5 I2C writing function.
 
err_t efuse5_generic_read (efuse5_t *ctx, uint8_t *data_out)
 eFuse 5 I2C reading function.
 
err_t efuse5_write_rdac (efuse5_t *ctx, uint8_t rdac_data)
 eFuse 5 write RDAC function.
 
err_t efuse5_read_rdac (efuse5_t *ctx, uint8_t *rdac_data)
 eFuse 5 read RDAC function.
 
err_t efuse5_set_digi_pot (efuse5_t *ctx, uint8_t wiper_pos)
 eFuse 5 set the digital potentiometer function.
 
err_t efuse5_set_resistance (efuse5_t *ctx, uint16_t res_ohm)
 eFuse 5 set the resistance function.
 
err_t efuse5_set_current_limit (efuse5_t *ctx, efuse5_current_limit_t current_limit)
 eFuse 5 set the current limit function.
 
void efuse5_enable_device (efuse5_t *ctx)
 eFuse 5 enable the device function.
 
void efuse5_shutdown (efuse5_t *ctx)
 eFuse 5 disable the device function.
 
uint8_t efuse5_get_imon (efuse5_t *ctx)
 eFuse 5 get imon function.
 
uint8_t efuse5_get_pgood (efuse5_t *ctx)
 eFuse 5 gets power good state function.
 
uint8_t efuse5_get_fault (efuse5_t *ctx)
 eFuse 5 gets fault condition state function.
 

Detailed Description

API for configuring and manipulating eFuse 5 Click driver.

Any initialization code needed for MCU to function properly. Do not remove this line or clock might not be set correctly.

Function Documentation

◆ efuse5_cfg_setup()

void efuse5_cfg_setup ( efuse5_cfg_t * cfg)

eFuse 5 configuration object setup function.

This function initializes click configuration structure to initial values.

Parameters
[out]cfg: Click configuration structure. See efuse5_cfg_t object definition for detailed explanation.
Returns
Nothing.
Note
The all used pins will be set to unconnected state.

◆ efuse5_default_cfg()

err_t efuse5_default_cfg ( efuse5_t * ctx)

eFuse 5 default configuration function.

This function executes a default configuration of eFuse 5 click board.

Parameters
[in]ctx: Click context object. See efuse5_t object definition for detailed explanation.
Returns
  • 0 - Success,
  • -1 - Error. See #err_t definition for detailed explanation.
Note
This function can consist any necessary configuration or setting to put device into operating mode.

◆ efuse5_enable_device()

void efuse5_enable_device ( efuse5_t * ctx)

eFuse 5 enable the device function.

This function performs the device to enter into low-power shutdown mode of the TPS16530 58-V, 4.5-A eFuse With Pulse Current Support for Load Transients on the eFuse 5 Click board™.

Parameters
[in]ctx: Click context object. See efuse5_t object definition for detailed explanation.
Returns
Nothing.
Note
None.

◆ efuse5_generic_read()

err_t efuse5_generic_read ( efuse5_t * ctx,
uint8_t * data_out )

eFuse 5 I2C reading function.

This function reads data bytes by using I2C serial interface.

Parameters
[in]ctx: Click context object. See efuse5_t object definition for detailed explanation.
[out]data_out: Output read data.
Returns
  • 0 - Success,
  • -1 - Error. See #err_t definition for detailed explanation.
Note
None.

◆ efuse5_get_fault()

uint8_t efuse5_get_fault ( efuse5_t * ctx)

eFuse 5 gets fault condition state function.

This function get the states of the FLT pin
of theTPS16530 58-V, 4.5-A eFuse With Pulse Current Support for Load Transients on the eFuse 5 Click board™.

Parameters
[in]ctx: Click context object. See efuse5_t object definition for detailed explanation.
Returns
  • 0 - Fault condition.
  • 1 - No fault.
Note
None.

◆ efuse5_get_imon()

uint8_t efuse5_get_imon ( efuse5_t * ctx)

eFuse 5 get imon function.

This function get the states of the MON pin
of theTPS16530 58-V, 4.5-A eFuse With Pulse Current Support for Load Transients on the eFuse 5 Click board™.

Parameters
[in]ctx: Click context object. See efuse5_t object definition for detailed explanation.
Returns
States of the MON pin.
Note
None.

◆ efuse5_get_pgood()

uint8_t efuse5_get_pgood ( efuse5_t * ctx)

eFuse 5 gets power good state function.

This function get the states of the PGD pin
of theTPS16530 58-V, 4.5-A eFuse With Pulse Current Support for Load Transients on the eFuse 5 Click board™.

Parameters
[in]ctx: Click context object. See efuse5_t object definition for detailed explanation.
Returns
  • 0 - Fault condition, internal FET is turned OFF during a fault.
  • 1 - Power is good, internal FET is enhanced.
Note
None.

◆ efuse5_init()

err_t efuse5_init ( efuse5_t * ctx,
efuse5_cfg_t * cfg )

eFuse 5 initialization function.

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

Parameters
[out]ctx: Click context object. See efuse5_t object definition for detailed explanation.
[in]cfg: Click configuration structure. See efuse5_cfg_t object definition for detailed explanation.
Returns
  • 0 - Success,
  • -1 - Error. See #err_t definition for detailed explanation.
Note
None.

◆ efuse5_read_rdac()

err_t efuse5_read_rdac ( efuse5_t * ctx,
uint8_t * rdac_data )

eFuse 5 read RDAC function.

This function reads 6-bit RDAC values of the AD5171, 64-Position OTP Digital Potentiometer on the eFuse 5 Click board™.

Parameters
[in]ctx: Click context object. See efuse5_t object definition for detailed explanation.
[out]rdac_data: Data to be written.
Returns
  • 0 - Success,
  • -1 - Error. See #err_t definition for detailed explanation.
Note
None.

◆ efuse5_set_current_limit()

err_t efuse5_set_current_limit ( efuse5_t * ctx,
efuse5_current_limit_t current_limit )

eFuse 5 set the current limit function.

This function set current limit value of the AD5171, 64-Position OTP Digital Potentiometer on the eFuse 5 Click board™.

Parameters
[in]ctx: Click context object. See efuse5_t object definition for detailed explanation.
[in]current_limit: Current limit values [mA].
Returns
  • 0 - Success,
  • -1 - Error. See #err_t definition for detailed explanation.
Note
None.

◆ efuse5_set_digi_pot()

err_t efuse5_set_digi_pot ( efuse5_t * ctx,
uint8_t wiper_pos )

eFuse 5 set the digital potentiometer function.

This function set the digital potentiometer wiper position of the AD5171, 64-Position OTP Digital Potentiometer on the eFuse 5 Click board™.

Parameters
[in]ctx: Click context object. See efuse5_t object definition for detailed explanation.
[in]wiper_pos: Wiper position (from 0 to 63).
Returns
  • 0 - Success,
  • -1 - Error. See #err_t definition for detailed explanation.
Note
None.

◆ efuse5_set_resistance()

err_t efuse5_set_resistance ( efuse5_t * ctx,
uint16_t res_ohm )

eFuse 5 set the resistance function.

This function set the resistance value of the digital potentiometer wiper position of the AD5171, 64-Position OTP Digital Potentiometer on the eFuse 5 Click board™.

Parameters
[in]ctx: Click context object. See efuse5_t object definition for detailed explanation.
[in]res_ohm: Resistance (from 4000 to 30000 Ohm).
Returns
  • 0 - Success,
  • -1 - Error. See #err_t definition for detailed explanation.
Note
None.

◆ efuse5_shutdown()

void efuse5_shutdown ( efuse5_t * ctx)

eFuse 5 disable the device function.

This function resets the device that has latched off due to a fault condition of theTPS16530 58-V, 4.5-A eFuse With Pulse Current Support for Load Transients on the eFuse 5 Click board™.

Parameters
[in]ctx: Click context object. See efuse5_t object definition for detailed explanation.
Returns
Nothing.
Note
None.

◆ efuse5_write_byte()

err_t efuse5_write_byte ( efuse5_t * ctx,
uint8_t inst,
uint8_t data_in )

eFuse 5 I2C writing function.

This function writes data bytes with desired instructions by using I2C serial interface.

Parameters
[in]ctx: Click context object. See efuse5_t object definition for detailed explanation.
[in]inst: Instruction Byte.
[in]data_in: Data to be written.
Returns
  • 0 - Success,
  • -1 - Error. See #err_t definition for detailed explanation.
Note
None.

◆ efuse5_write_rdac()

err_t efuse5_write_rdac ( efuse5_t * ctx,
uint8_t rdac_data )

eFuse 5 write RDAC function.

This function writes 6-bit RDAC values of the AD5171, 64-Position OTP Digital Potentiometer on the eFuse 5 Click board™.

Parameters
[in]ctx: Click context object. See efuse5_t object definition for detailed explanation.
[in]rdac_data: Data to be written.
Returns
  • 0 - Success,
  • -1 - Error. See #err_t definition for detailed explanation.
Note
None.