digipot5 2.0.0.0
|
This file contains API for DIGI POT 5 Click driver. More...
#include "drv_spi_master.h"
Go to the source code of this file.
Data Structures | |
struct | digipot5_t |
Click context object definition. More... | |
struct | digipot5_cfg_t |
Click configuration structure definition. More... | |
Macros | |
#define | DIGIPOT5_RETVAL uint8_t |
#define | DIGIPOT5_OK 0x00 |
#define | DIGIPOT5_INIT_ERROR 0xFF |
#define | DIGIPOT5_RES_ZEROSCALE 0x00 |
#define | DIGIPOT5_RES_1KOHM 0x1A |
#define | DIGIPOT5_RES_2KOHM 0x34 |
#define | DIGIPOT5_RES_3KOHM 0x4E |
#define | DIGIPOT5_RES_5KOHM_HALFSCALE 0x80 |
#define | DIGIPOT5_RES_7KOHM 0xB6 |
#define | DIGIPOT5_RES_8KOHM 0xD0 |
#define | DIGIPOT5_RES_10KOHM_FULLSCALE 0x100 |
#define | DIGIPOT5_MAP_MIKROBUS(cfg, mikrobus) |
Enumerations | |
enum | digipot5_err_t { DIGIPOT5_STATUS_OK , DIGIPOT5_ERROR_CMD , DIGIPOT5_ERROR_INIT_DRV , DIGIPOT5_ERROR_REG_ADDR } |
Click error code definition. More... | |
enum | digipot5_reg_t { DIGIPOT5_REG_WIPER0_VOL , DIGIPOT5_REG_WIPER1_VOL , DIGIPOT5_REG_WIPER0_NONVOL , DIGIPOT5_REG_WIPER1_NONVOL , DIGIPOT5_REG_TCON0_VOL , DIGIPOT5_REG_STATUS_VOL , DIGIPOT5_REG_WIPER2_VOL , DIGIPOT5_REG_WIPER3_VOL , DIGIPOT5_REG_WIPER2_NONVOL , DIGIPOT5_REG_WIPER3_NONVOL , DIGIPOT5_REG_TCON1_VOL , DIGIPOT5_REG_EEPROM0_NONVOL , DIGIPOT5_REG_EEPROM1_NONVOL , DIGIPOT5_REG_EEPROM2_NONVOL , DIGIPOT5_REG_EEPROM3_NONVOL , DIGIPOT5_REG_EEPROM4_NONVOL } |
Click register address definition. More... | |
Functions | |
void | digipot5_cfg_setup (digipot5_cfg_t *cfg) |
Configuration Object Setup function. | |
digipot5_err_t | digipot5_init (digipot5_t *ctx, digipot5_cfg_t *cfg) |
Click Initialization function. | |
void | digipot5_reset (digipot5_t *ctx) |
Reset function. | |
void | digipot5_default_cfg (digipot5_t *ctx) |
Click Default Configuration function. | |
digipot5_err_t | digipot5_generic_write (digipot5_t *ctx, digipot5_reg_t reg_addr, uint16_t data_in) |
Generic Write function. | |
digipot5_err_t | digipot5_generic_read (digipot5_t *ctx, digipot5_reg_t reg_addr, uint16_t *data_out) |
Generic Read function. | |
digipot5_reg_t | digipot5_increment_wiper (digipot5_t *ctx, digipot5_reg_t reg_addr) |
Increment Wiper function. | |
digipot5_reg_t | digipot5_decrement_wiper (digipot5_t *ctx, digipot5_reg_t reg_addr) |
Decrement Wiper function. | |
This file contains API for DIGI POT 5 Click driver.