|
rfswitch 2.2.0
|
API for configuring and manipulating RF Switch Click driver. More...
Topics | |
| RF Switch Registers Settings | |
| Settings for registers of RF Switch Click driver. | |
| RF Switch MikroBUS Map | |
| MikroBUS pin mapping of RF Switch Click driver. | |
Functions | |
| void | rfswitch_cfg_setup (rfswitch_cfg_t *cfg) |
| RF Switch configuration object setup function. | |
| err_t | rfswitch_init (rfswitch_t *ctx, rfswitch_cfg_t *cfg) |
| RF Switch initialization function. | |
| void | rfswitch_power_on (rfswitch_t *ctx) |
| RF Switch power on function. | |
| void | rfswitch_on_pin_set (rfswitch_t *ctx, uint8_t enable) |
| RF Switch ON pin setting function. | |
| void | rfswitch_sel_pin_set (rfswitch_t *ctx, uint8_t enable) |
| RF Switch SEL pin setting function. | |
| void | rfswitch_switch_channel (rfswitch_t *ctx) |
| RF Switch switch channel function. | |
| void | rfswitch_select_channel (rfswitch_t *ctx, uint8_t select_channel) |
| RF Switch select channel function. | |
API for configuring and manipulating RF Switch Click driver.
Any initialization code needed for MCU to function properly. Do not remove this line or clock might not be set correctly.
| void rfswitch_cfg_setup | ( | rfswitch_cfg_t * | cfg | ) |
RF Switch configuration object setup function.
This function initializes Click configuration structure to initial values.
| [out] | cfg | : Click configuration structure. See rfswitch_cfg_t object definition for detailed explanation. |
| err_t rfswitch_init | ( | rfswitch_t * | ctx, |
| rfswitch_cfg_t * | cfg ) |
RF Switch initialization function.
This function initializes all necessary pins and peripherals used for this Click board.
| [out] | ctx | : Click context object. See rfswitch_t object definition for detailed explanation. |
| [in] | cfg | : Click configuration structure. See rfswitch_cfg_t object definition for detailed explanation. |
0 - Success, -1 - Error.| void rfswitch_on_pin_set | ( | rfswitch_t * | ctx, |
| uint8_t | enable ) |
RF Switch ON pin setting function.
This function sets the ON pin on the high level or low level of RF Switch Click board.
| [in] | ctx | : Click context object. See rfswitch_t object definition for detailed explanation. |
| [in] | enable | : State of the ON pin. |
| void rfswitch_power_on | ( | rfswitch_t * | ctx | ) |
RF Switch power on function.
This function is used to power up RF Switch Click board.
| [in] | ctx | : Click context object. See rfswitch_t object definition for detailed explanation. |
| void rfswitch_sel_pin_set | ( | rfswitch_t * | ctx, |
| uint8_t | enable ) |
RF Switch SEL pin setting function.
This function sets the SEL pin on the high level or low level of RF Switch Click board.
| [in] | ctx | : Click context object. See rfswitch_t object definition for detailed explanation. |
| [in] | enable | : State of the SEL pin. |
| void rfswitch_select_channel | ( | rfswitch_t * | ctx, |
| uint8_t | select_channel ) |
RF Switch select channel function.
This function enables users to select from channel 1 or channel 2 of the RF Switch Click board.
| [in] | ctx | : Click context object. See rfswitch_t object definition for detailed explanation. |
| [in] | select_channel | : Selected channel. |
| void rfswitch_switch_channel | ( | rfswitch_t * | ctx | ) |
RF Switch switch channel function.
This function toggles the SEL pin from high to low levels of RF Switch Click board, and vice versa, therefore changing the channel.
| [in] | ctx | : Click context object. See rfswitch_t object definition for detailed explanation. |