clockgen6 2.0.0.0
Clock Gen 6 Click Driver

API for configuring and manipulating Clock Gen 6 Click driver. More...

Topics

 Clock Gen 6 Registers Settings
 Settings for registers of Clock Gen 6 Click driver.
 
 Clock Gen 6 MikroBUS Map
 MikroBUS pin mapping of Clock Gen 6 Click driver.
 

Functions

void clockgen6_cfg_setup (clockgen6_cfg_t *cfg)
 Clock Gen 6 configuration object setup function.
 
err_t clockgen6_init (clockgen6_t *ctx, clockgen6_cfg_t *cfg)
 Clock Gen 6 initialization function.
 
err_t clockgen6_default_cfg (clockgen6_t *ctx)
 Clock Gen 6 default configuration function.
 
err_t clockgen6_set_digipot (clockgen6_t *ctx, uint8_t position)
 Clock Gen 6 set digipot function.
 
void clockgen6_enable_output (clockgen6_t *ctx)
 Clock Gen 6 enable output function.
 
void clockgen6_disable_output (clockgen6_t *ctx)
 Clock Gen 6 disable output function.
 

Detailed Description

API for configuring and manipulating Clock Gen 6 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

◆ clockgen6_cfg_setup()

void clockgen6_cfg_setup ( clockgen6_cfg_t * cfg)

Clock Gen 6 configuration object setup function.

This function initializes click configuration structure to initial values.

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

◆ clockgen6_default_cfg()

err_t clockgen6_default_cfg ( clockgen6_t * ctx)

Clock Gen 6 default configuration function.

This function executes a default configuration of Clock Gen 6 click board.

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

◆ clockgen6_disable_output()

void clockgen6_disable_output ( clockgen6_t * ctx)

Clock Gen 6 disable output function.

This function disables the output by setting the EN pin to low logic state.

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

◆ clockgen6_enable_output()

void clockgen6_enable_output ( clockgen6_t * ctx)

Clock Gen 6 enable output function.

This function enables the output by setting the EN pin to high logic state.

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

◆ clockgen6_init()

err_t clockgen6_init ( clockgen6_t * ctx,
clockgen6_cfg_t * cfg )

Clock Gen 6 initialization function.

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

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

◆ clockgen6_set_digipot()

err_t clockgen6_set_digipot ( clockgen6_t * ctx,
uint8_t position )

Clock Gen 6 set digipot function.

This function sets the digital potentiometer position by using SPI serial interface.

Parameters
[in]ctx: Click context object. See clockgen6_t object definition for detailed explanation.
[in]position: Digital potentiometer position (0-255).
Returns
  • 0 - Success,
  • -1 - Error. See #err_t definition for detailed explanation.
Note
None.