rs232 2.0.0.0
rs232.h File Reference

This file contains API for RS232 Click driver. More...

#include "drv_digital_out.h"
#include "drv_digital_in.h"
#include "drv_uart.h"

Go to the source code of this file.

Data Structures

struct  rs232_t
 Click ctx object definition. More...
 
struct  rs232_cfg_t
 Click configuration structure definition. More...
 

Macros

#define RS232_MAP_MIKROBUS(cfg, mikrobus)
 
#define RS232_RETVAL   uint8_t
 
#define RS232_OK   0x00
 
#define RS232_INIT_ERROR   0xFF
 
#define DRV_RX_BUFFER_SIZE   500
 

Typedefs

typedef uint8_t rs232_error_t
 Error type.
 

Functions

void rs232_cfg_setup (rs232_cfg_t *cfg)
 Config Object Initialization function.
 
RS232_RETVAL rs232_init (rs232_t *ctx, rs232_cfg_t *cfg)
 Initialization function.
 
void rs232_generic_write (rs232_t *ctx, char *data_buf, uint16_t len)
 Generic write function.
 
int32_t rs232_generic_read (rs232_t *ctx, char *data_buf, uint16_t max_len)
 Generic read function.
 
uint8_t rs232_get_cts_state (rs232_t *ctx)
 Get CTS pin state (Clear to send)
 
void rs232_set_rts_state (rs232_t *ctx, uint8_t state)
 Set RTS pin state.
 

Detailed Description

This file contains API for RS232 Click driver.