rs2322 2.0.0.0
|
Functions | |
void | rs2322_cfg_setup (rs2322_cfg_t *cfg) |
Config Object Initialization function. | |
RS2322_RETVAL | rs2322_init (rs2322_t *ctx, rs2322_cfg_t *cfg) |
Initialization function. | |
void | rs2322_generic_write (rs2322_t *ctx, char *data_buf, uint16_t len) |
Generic write function. | |
int16_t | rs2322_generic_read (rs2322_t *ctx, char *data_buf, uint16_t max_len) |
Generic read function. | |
void | rs2322_set_dcd (rs2322_t *ctx, uint8_t state) |
This function sets DCD pin state. | |
void | rs2322_set_cts (rs2322_t *ctx, uint8_t state) |
This function sets CTS pin state. | |
void | rs2322_set_ri (rs2322_t *ctx, uint8_t state) |
This function sets RI pin state. | |
uint8_t | rs2322_get_rts (rs2322_t *ctx) |
This function get RST pin state. | |
uint8_t | rs2322_get_dtr (rs2322_t *ctx) |
This function get DTR pin state. | |
void | rs2322_send_command (rs2322_t *ctx, char *command) |
Function for send command. | |
void rs2322_cfg_setup | ( | rs2322_cfg_t * | cfg | ) |
Config Object Initialization function.
cfg | Click configuration structure. |
@description This function initializes click configuration structure to init state.
int16_t rs2322_generic_read | ( | rs2322_t * | ctx, |
char * | data_buf, | ||
uint16_t | max_len ) |
Generic read function.
rs2322 | Click object. |
data_buf | Data buffer for read data. |
max_len | The maximum length of data that can be read. |
void rs2322_generic_write | ( | rs2322_t * | ctx, |
char * | data_buf, | ||
uint16_t | len ) |
Generic write function.
rs2322 | Click object. |
data_buf | Data buffer for sends. |
len | Number of bytes for sends. |
uint8_t rs2322_get_dtr | ( | rs2322_t * | ctx | ) |
This function get DTR pin state.
ctx | Click object. |
@description Ready to receive.
uint8_t rs2322_get_rts | ( | rs2322_t * | ctx | ) |
This function get RST pin state.
ctx | Click object. |
@description Ready to send.
RS2322_RETVAL rs2322_init | ( | rs2322_t * | ctx, |
rs2322_cfg_t * | cfg ) |
Initialization function.
rs2322 | Click object. |
cfg | Click configuration structure. |
@description This function initializes all necessary pins and peripherals used for this click.
void rs2322_send_command | ( | rs2322_t * | ctx, |
char * | command ) |
Function for send command.
ctx | Click object. |
command | Data to be send. |
void rs2322_set_cts | ( | rs2322_t * | ctx, |
uint8_t | state ) |
This function sets CTS pin state.
ctx | Click object. |
state | Set state. |
@description Clear to send.
void rs2322_set_dcd | ( | rs2322_t * | ctx, |
uint8_t | state ) |
This function sets DCD pin state.
ctx | Click object. |
state | Set state. |
@description Carrier Receiving Indication.
void rs2322_set_ri | ( | rs2322_t * | ctx, |
uint8_t | state ) |
This function sets RI pin state.
ctx | Click object. |
state | Set state. |
@description Ring indication.