currentlimit5 2.0.0.0
Current Limit 5 Click Driver

API for configuring and manipulating Current Limit 5 Click driver. More...

Topics

 Current Limit 5 Settings
 Settings of Current Limit 5 Click driver.
 
 Current Limit 5 MikroBUS Map
 MikroBUS pin mapping of Current Limit 5 Click driver.
 

Functions

void currentlimit5_cfg_setup (currentlimit5_cfg_t *cfg)
 Current Limit 5 configuration object setup function.
 
err_t currentlimit5_init (currentlimit5_t *ctx, currentlimit5_cfg_t *cfg)
 Current Limit 5 initialization function.
 
err_t currentlimit5_default_cfg (currentlimit5_t *ctx)
 Current Limit 5 default configuration function.
 
err_t currentlimit5_set_ilimit (currentlimit5_t *ctx, currentlimit5_ilimit_t ilimit)
 Current Limit 5 set ilimit function.
 
uint8_t currentlimit5_get_fault_pin (currentlimit5_t *ctx)
 Current Limit 5 get fault pin function.
 
void currentlimit5_enable_limit (currentlimit5_t *ctx)
 Current Limit 5 enable limit function.
 
void currentlimit5_disable_limit (currentlimit5_t *ctx)
 Current Limit 5 disable limit function.
 

Detailed Description

API for configuring and manipulating Current Limit 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

◆ currentlimit5_cfg_setup()

void currentlimit5_cfg_setup ( currentlimit5_cfg_t * cfg)

Current Limit 5 configuration object setup function.

This function initializes click configuration structure to initial values.

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

◆ currentlimit5_default_cfg()

err_t currentlimit5_default_cfg ( currentlimit5_t * ctx)

Current Limit 5 default configuration function.

This function executes a default configuration of Current Limit 5 click board.

Parameters
[in]ctx: Click context object. See currentlimit5_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.

◆ currentlimit5_disable_limit()

void currentlimit5_disable_limit ( currentlimit5_t * ctx)

Current Limit 5 disable limit function.

This function disables the current limiting switch.

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

◆ currentlimit5_enable_limit()

void currentlimit5_enable_limit ( currentlimit5_t * ctx)

Current Limit 5 enable limit function.

This function enables the current limiting switch.

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

◆ currentlimit5_get_fault_pin()

uint8_t currentlimit5_get_fault_pin ( currentlimit5_t * ctx)

Current Limit 5 get fault pin function.

This function returns the fault pin logic state.

Parameters
[in]ctx: Click context object. See currentlimit5_t object definition for detailed explanation.
Returns
  • 0 - Current limiting or thermal shutdown operation,
  • 1 - Normal operation.
Note
None.

◆ currentlimit5_init()

err_t currentlimit5_init ( currentlimit5_t * ctx,
currentlimit5_cfg_t * cfg )

Current Limit 5 initialization function.

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

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

◆ currentlimit5_set_ilimit()

err_t currentlimit5_set_ilimit ( currentlimit5_t * ctx,
currentlimit5_ilimit_t ilimit )

Current Limit 5 set ilimit function.

This function sets the current limit value by configuring the onboard digital potentiometer.

Parameters
[in]ctx: Click context object. See currentlimit5_t object definition for detailed explanation.
[in]ilimit: Ilimit value. See currentlimit5_ilimit_t enum definition for detailed explanation.
Returns
  • 0 - Success,
  • -1 - Error.
See #err_t definition for detailed explanation.
Note
None.