You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
|
|
|
|
|
|
|
|
#ifndef APP_TYPES_H
|
|
|
|
|
#define APP_TYPES_H
|
|
|
|
|
|
|
|
|
|
#include "r_cg_macrodriver.h"
|
|
|
|
|
|
|
|
|
|
#define APP_JOB_PAYLOAD_MAX 160
|
|
|
|
|
|
|
|
|
|
typedef enum {
|
|
|
|
|
APP_CMD_SRC_PC = 0,
|
|
|
|
|
APP_CMD_SRC_RS485 = 1
|
|
|
|
|
} app_cmd_src_t;
|
|
|
|
|
|
|
|
|
|
typedef enum {
|
|
|
|
|
APP_JOB_NONE = 0,
|
|
|
|
|
APP_JOB_SCAN_ADDR,
|
|
|
|
|
APP_JOB_PROTO_OW,
|
|
|
|
|
APP_JOB_PROTO_OR,
|
|
|
|
|
APP_JOB_FORWARD_LINE,
|
|
|
|
|
APP_JOB_LOCAL_EXEC
|
|
|
|
|
} app_job_type_t;
|
|
|
|
|
|
|
|
|
|
typedef enum {
|
|
|
|
|
APP_PROTO_NONE = 0,
|
|
|
|
|
APP_PROTO_OWIW,
|
|
|
|
|
APP_PROTO_OWIT,
|
|
|
|
|
APP_PROTO_OWIR
|
|
|
|
|
} app_proto_t;
|
|
|
|
|
|
|
|
|
|
typedef struct {
|
|
|
|
|
app_job_type_t type;
|
|
|
|
|
app_cmd_src_t src;
|
|
|
|
|
|
|
|
|
|
uint8_t addr;
|
|
|
|
|
uint8_t channel;
|
|
|
|
|
char mode;
|
|
|
|
|
uint8_t hash_on;
|
|
|
|
|
uint8_t anaout_on;
|
|
|
|
|
uint8_t check_on;
|
|
|
|
|
|
|
|
|
|
app_proto_t proto;
|
|
|
|
|
uint8_t id;
|
|
|
|
|
uint16_t len;
|
|
|
|
|
uint8_t payload[APP_JOB_PAYLOAD_MAX];
|
|
|
|
|
|
|
|
|
|
/* fallback�� ª�� line�� ���� */
|
|
|
|
|
char line[256];
|
|
|
|
|
} app_job_t;
|
|
|
|
|
|
|
|
|
|
#endif
|