brushless16 2.0.0.0
Brushless 16 Click Driver

API for configuring and manipulating Brushless 16 Click driver. More...

Functions

void brushless16_cfg_setup (brushless16_cfg_t *cfg)
 Brushless 16 configuration object setup function.
 
err_t brushless16_init (brushless16_t *ctx, brushless16_cfg_t *cfg)
 Brushless 16 initialization function.
 
void brushless16_set_en (brushless16_t *ctx, uint8_t state)
 Set en pin state.
 
uint8_t brushless16_get_rd (brushless16_t *ctx)
 Get rd pin state.
 
uint8_t brushless16_get_fg (brushless16_t *ctx)
 Get fg pin state.
 

Detailed Description

API for configuring and manipulating Brushless 16 Click driver.

Function Documentation

◆ brushless16_cfg_setup()

void brushless16_cfg_setup ( brushless16_cfg_t * cfg)

Brushless 16 configuration object setup function.

This function initializes click configuration structure to initial values.

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

◆ brushless16_get_fg()

uint8_t brushless16_get_fg ( brushless16_t * ctx)

Get fg pin state.

Read logic state of FG pin.

Parameters
[in]ctx: Click context object. See brushless16_t object definition for detailed explanation.
Returns
  • 0 - Low pin state,
  • 1 - High pin state.

◆ brushless16_get_rd()

uint8_t brushless16_get_rd ( brushless16_t * ctx)

Get rd pin state.

Read logic state of RD pin

Parameters
[in]ctx: Click context object. See brushless16_t object definition for detailed explanation.
Returns
  • 0 - Low pin state,
  • 1 - High pin state.

◆ brushless16_init()

err_t brushless16_init ( brushless16_t * ctx,
brushless16_cfg_t * cfg )

Brushless 16 initialization function.

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

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

◆ brushless16_set_en()

void brushless16_set_en ( brushless16_t * ctx,
uint8_t state )

Set en pin state.

This function sets the target pin on the high level of Brushless 16 click board.

Parameters
[in]ctx: Click context object. See brushless16_t object definition for detailed explanation.
[in]state: Pin state.
Returns
Nothing.