#ifndef _DEV_RS485_H_
#define _DEV_RS485_H_

#include "hdl_usart.h"

#define RS485_CTRL_PORT (GPIO_PORT_C)
#define RS485_CTRL_PIN  (GPIO_PIN_07)

typedef void (*dev_rs485_cb_t)(uint8_t dat);

extern int dev_rs485_init(void);

extern void dev_rs485_send(uint8_t *buf, int len);

extern int dev_rs485_read(uint8_t *buf, int len);

extern int dev_rs485_rx_register(dev_rs485_cb_t fnCallback);

extern int dev_rs485_deinit(void);
  
#endif

