39#ifdef PREINIT_SUPPORTED
43#ifdef MikroCCoreVersion
44 #if MikroCCoreVersion >= 1
49#include "drv_digital_out.h"
50#include "drv_digital_in.h"
51#include "drv_analog_in.h"
52#include "drv_i2c_master.h"
74#define MICROWAVE6_ADC_RESOLUTION 0x0FFF
75#define MICROWAVE6_VREF_3V3 3.3
76#define MICROWAVE6_VREF_5V 5.0
83#define MICROWAVE6_SET_DEV_ADDR 0x4D
101#define MICROWAVE6_MAP_MIKROBUS( cfg, mikrobus ) \
102 cfg.an = MIKROBUS( mikrobus, MIKROBUS_AN ); \
103 cfg.scl = MIKROBUS( mikrobus, MIKROBUS_SCL ); \
104 cfg.sda = MIKROBUS( mikrobus, MIKROBUS_SDA )
err_t microwave6_set_vref(microwave6_t *ctx, float vref)
Microwave 6 set vref function.
err_t microwave6_init(microwave6_t *ctx, microwave6_cfg_t *cfg)
Microwave 6 initialization function.
err_t microwave6_read_voltage(microwave6_t *ctx, float *voltage)
Microwave 6 read voltage level function.
void microwave6_cfg_setup(microwave6_cfg_t *cfg)
Microwave 6 configuration object setup function.
void microwave6_drv_interface_selection(microwave6_cfg_t *cfg, microwave6_drv_t drv_sel)
Microwave 6 driver interface setup function.
err_t microwave6_read_raw_adc(microwave6_t *ctx, uint16_t *raw_adc)
Microwave 6 read raw ADC value function.
microwave6_drv_t
Microwave 6 Click driver selector.
Definition microwave6.h:114
@ MICROWAVE6_DRV_SEL_ADC
Definition microwave6.h:115
@ MICROWAVE6_DRV_SEL_I2C
Definition microwave6.h:116
microwave6_return_value_t
Microwave 6 Click return value data.
Definition microwave6.h:160
@ MICROWAVE6_OK
Definition microwave6.h:161
@ MICROWAVE6_ERROR
Definition microwave6.h:162
Microwave 6 Click configuration object.
Definition microwave6.h:140
analog_in_resolution_t resolution
Definition microwave6.h:145
float vref
Definition microwave6.h:146
uint32_t i2c_speed
Definition microwave6.h:148
pin_name_t scl
Definition microwave6.h:142
microwave6_drv_t drv_sel
Definition microwave6.h:151
pin_name_t sda
Definition microwave6.h:143
pin_name_t an
Definition microwave6.h:141
uint8_t i2c_address
Definition microwave6.h:149
Microwave 6 Click context object.
Definition microwave6.h:125
float vref
Definition microwave6.h:130
i2c_master_t i2c
Definition microwave6.h:127
uint8_t slave_address
Definition microwave6.h:129
microwave6_drv_t drv_sel
Definition microwave6.h:131
analog_in_t adc
Definition microwave6.h:126