33 lines
547 B
C
33 lines
547 B
C
#ifndef __CHRG_NORTH_H__
|
|
#define __CHRG_NORTH_H__
|
|
|
|
#include <rtthread.h>
|
|
|
|
#include "chrg_tty.h"
|
|
#include "chrg_switch.h"
|
|
|
|
|
|
#define THR_NAME_NORTH "thr.nor"
|
|
#define DEV_NAME_NORTH "uart3"
|
|
|
|
struct chrg_north_t {
|
|
const char *name;
|
|
const char *devname;
|
|
struct rt_thread *tid;
|
|
struct rt_mutex lock;
|
|
|
|
struct chrg_tty_t *tty;
|
|
rt_uint16_t rx_len;
|
|
rt_uint8_t rx_buf[SIZE_BUF_TTY];
|
|
|
|
struct chrg_switch_t sw[TOTAL_CHS];
|
|
};
|
|
|
|
extern struct chrg_north_t chrgnorth;
|
|
|
|
extern int chrg_north_send (rt_uint8_t *data, rt_size_t length);
|
|
|
|
|
|
#endif
|
|
|