leddriver17 2.1.0.0
LED Driver 17 Click Driver

API for configuring and manipulating LED Driver 17 Click driver. More...

Topics

 LED Driver 17 PWM Settings
 Settings for configuration of LED Driver 17 Click driver.
 
 LED Driver 17 MikroBUS Map
 MikroBUS pin mapping of LED Driver 17 Click driver.
 

Functions

void leddriver17_cfg_setup (leddriver17_cfg_t *cfg)
 LED Driver 17 configuration object setup function.
 
err_t leddriver17_init (leddriver17_t *ctx, leddriver17_cfg_t *cfg)
 LED Driver 17 initialization function.
 
err_t leddriver17_default_cfg (leddriver17_t *ctx)
 LED Driver 17 default configuration function.
 
err_t leddriver17_set_duty_cycle (leddriver17_t *ctx, float duty_cycle)
 LED Driver 17 sets PWM duty cycle.
 
err_t leddriver17_pwm_stop (leddriver17_t *ctx)
 LED Driver 17 stop PWM module.
 
err_t leddriver17_pwm_start (leddriver17_t *ctx)
 LED Driver 17 start PWM module.
 
uint8_t leddriver17_get_fault_pin (leddriver17_t *ctx)
 LED Driver 17 get fault pin function.
 

Detailed Description

API for configuring and manipulating LED Driver 17 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

◆ leddriver17_cfg_setup()

void leddriver17_cfg_setup ( leddriver17_cfg_t * cfg)

LED Driver 17 configuration object setup function.

This function initializes click configuration structure to initial values.

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

◆ leddriver17_default_cfg()

err_t leddriver17_default_cfg ( leddriver17_t * ctx)

LED Driver 17 default configuration function.

This function executes a default configuration of LED Driver 17 click board.

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

◆ leddriver17_get_fault_pin()

uint8_t leddriver17_get_fault_pin ( leddriver17_t * ctx)

LED Driver 17 get fault pin function.

This function returns the fault (FLT) pin logic state.

Parameters
[in]ctx: Click context object. See leddriver17_t object definition for detailed explanation.
Returns
Pin logic state.
Note
None.

◆ leddriver17_init()

err_t leddriver17_init ( leddriver17_t * ctx,
leddriver17_cfg_t * cfg )

LED Driver 17 initialization function.

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

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

◆ leddriver17_pwm_start()

err_t leddriver17_pwm_start ( leddriver17_t * ctx)

LED Driver 17 start PWM module.

This function starts the PWM module output.

Parameters
[in]ctx: Click context object. See leddriver17_t object definition for detailed explanation.
Returns
  • 0 - Success,
  • -1 - Error. See #err_t definition for detailed explanation.
Note
None.

◆ leddriver17_pwm_stop()

err_t leddriver17_pwm_stop ( leddriver17_t * ctx)

LED Driver 17 stop PWM module.

This function stops the PWM module output.

Parameters
[in]ctx: Click context object. See leddriver17_t object definition for detailed explanation.
Returns
  • 0 - Success,
  • -1 - Error. See #err_t definition for detailed explanation.
Note
None.

◆ leddriver17_set_duty_cycle()

err_t leddriver17_set_duty_cycle ( leddriver17_t * ctx,
float duty_cycle )

LED Driver 17 sets PWM duty cycle.

This function sets the PWM duty cycle in percentages ( Range[ 0..1 ] ).

Parameters
[in]ctx: Click context object. See leddriver17_t object definition for detailed explanation.
[in]duty_cycle: PWM duty cycle.
Returns
  • 0 - Success,
  • -1 - Error. See #err_t definition for detailed explanation.
Note
None.