41#ifdef PREINIT_SUPPORTED
45#ifdef MikroCCoreVersion
46 #if MikroCCoreVersion >= 1
51#include "drv_digital_out.h"
52#include "drv_digital_in.h"
66#define IQRF_MAP_MIKROBUS( cfg, mikrobus ) \
67 cfg.tx_pin = MIKROBUS( mikrobus, MIKROBUS_TX ); \
68 cfg.rx_pin = MIKROBUS( mikrobus, MIKROBUS_RX ); \
69 cfg.adc = MIKROBUS( mikrobus, MIKROBUS_AN ); \
70 cfg.io = MIKROBUS( mikrobus, MIKROBUS_RST ); \
71 cfg.cs = MIKROBUS( mikrobus, MIKROBUS_CS ); \
72 cfg.pwm = MIKROBUS( mikrobus, MIKROBUS_PWM ); \
73 cfg.int_pin = MIKROBUS( mikrobus, MIKROBUS_INT )
80#define IQRF_RETVAL uint8_t
83#define IQRF_INIT_ERROR 0xFF
90#define DRV_RX_BUFFER_SIZE 500
164 // End constants group
173 // End variable group
#define DRV_RX_BUFFER_SIZE
Definition iqrf.h:90
#define IQRF_RETVAL
Definition iqrf.h:80
void iqrf_default_cfg(iqrf_t *ctx)
Click Default Configuration function.
void iqrf_cfg_setup(iqrf_cfg_t *cfg)
Config Object Initialization function.
void iqrf_generic_multi_write(iqrf_t *ctx, char *data_buf, uint8_t len)
Generic multi write function.
char iqrf_generic_single_read(iqrf_t *ctx)
Generic single read function.
void iqrf_generic_single_write(iqrf_t *ctx, char tx_data)
Generic single write function.
IQRF_RETVAL iqrf_init(iqrf_t *ctx, iqrf_cfg_t *cfg)
Initialization function.
uint8_t iqrf_get_interrupt(iqrf_t *ctx)
Interrupt function.
void iqrf_generic_multi_read(iqrf_t *ctx, char *data_buf, uint8_t len)
Generic multi read function.
void iqrf_hw_reset(iqrf_t *ctx)
Hardware reset function.
Click configuration structure definition.
Definition iqrf.h:131
uint32_t baud_rate
Definition iqrf.h:147
pin_name_t io
Definition iqrf.h:140
pin_name_t adc
Definition iqrf.h:139
bool uart_blocking
Definition iqrf.h:148
uart_data_bits_t data_bit
Definition iqrf.h:149
pin_name_t tx_pin
Definition iqrf.h:135
pin_name_t rx_pin
Definition iqrf.h:134
uart_stop_bits_t stop_bit
Definition iqrf.h:151
pin_name_t int_pin
Definition iqrf.h:143
pin_name_t pwm
Definition iqrf.h:142
uart_parity_t parity_bit
Definition iqrf.h:150
pin_name_t cs
Definition iqrf.h:141
Click ctx object definition.
Definition iqrf.h:106
digital_out_t cs
Definition iqrf.h:110
digital_out_t pwm
Definition iqrf.h:111
digital_out_t io
Definition iqrf.h:109
uart_t uart
Definition iqrf.h:120
digital_in_t int_pin
Definition iqrf.h:116
digital_in_t adc
Definition iqrf.h:115