39#ifdef PREINIT_SUPPORTED
43#ifdef MikroCCoreVersion
44 #if MikroCCoreVersion >= 1
49#include "drv_digital_out.h"
50#include "drv_digital_in.h"
74#define DRV_BUFFER_SIZE 200
92#define RS2323_MAP_MIKROBUS( cfg, mikrobus ) \
93 cfg.tx_pin = MIKROBUS( mikrobus, MIKROBUS_TX ); \
94 cfg.rx_pin = MIKROBUS( mikrobus, MIKROBUS_RX ); \
95 cfg.shd = MIKROBUS( mikrobus, MIKROBUS_RST ); \
96 cfg.en = MIKROBUS( mikrobus, MIKROBUS_CS ); \
97 cfg.on = MIKROBUS( mikrobus, MIKROBUS_PWM ); \
98 cfg.sta = MIKROBUS( mikrobus, MIKROBUS_INT );
#define DRV_BUFFER_SIZE
RS232 3 driver buffer size.
Definition rs2323.h:74
void rs2323_set_enable_pin(rs2323_t *ctx, uint8_t state)
RS232 3 set enable pin function.
err_t rs2323_generic_write(rs2323_t *ctx, char *data_buf, uint16_t len)
RS232 3 data writing function.
err_t rs2323_generic_read(rs2323_t *ctx, char *data_buf, uint16_t max_len)
RS232 3 data reading function.
void rs2323_cfg_setup(rs2323_cfg_t *cfg)
RS232 3 configuration object setup function.
void rs2323_set_online_pin(rs2323_t *ctx, uint8_t state)
RS232 3 set online pin function.
uint8_t rs2323_get_status_pin(rs2323_t *ctx)
RS232 3 get status pin function.
void rs2323_set_shutdown_pin(rs2323_t *ctx, uint8_t state)
RS232 3 set shutdown pin function.
err_t rs2323_init(rs2323_t *ctx, rs2323_cfg_t *cfg)
RS232 3 initialization function.
rs2323_return_value_t
RS232 3 Click return value data.
Definition rs2323.h:156
@ RS2323_OK
Definition rs2323.h:157
@ RS2323_ERROR
Definition rs2323.h:158
RS232 3 Click configuration object.
Definition rs2323.h:131
pin_name_t sta
Definition rs2323.h:140
uint32_t baud_rate
Definition rs2323.h:143
bool uart_blocking
Definition rs2323.h:144
uart_data_bits_t data_bit
Definition rs2323.h:145
pin_name_t on
Definition rs2323.h:139
pin_name_t tx_pin
Definition rs2323.h:134
pin_name_t rx_pin
Definition rs2323.h:133
pin_name_t shd
Definition rs2323.h:137
uart_stop_bits_t stop_bit
Definition rs2323.h:147
pin_name_t en
Definition rs2323.h:138
uart_parity_t parity_bit
Definition rs2323.h:146
RS232 3 Click context object.
Definition rs2323.h:108
digital_in_t sta
Definition rs2323.h:115
digital_out_t on
Definition rs2323.h:112
uart_t uart
Definition rs2323.h:118
digital_out_t en
Definition rs2323.h:111
digital_out_t shd
Definition rs2323.h:110