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.
33 lines
1.1 KiB
33 lines
1.1 KiB
#pragma once
|
|
#include "sdk/hal/zhal.hpp"
|
|
#include "transmit_disinfection_protocol_v1\transmit_disinfection_protocol_v1.hpp"
|
|
#define Cmdheader_t transmit_disinfection_protocol_header_t
|
|
namespace iflytop {
|
|
namespace zcr {
|
|
|
|
|
|
} // namespace zcr
|
|
} // namespace iflytop
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
* @brief
|
|
* PROCESS_CMD
|
|
* 这个宏定义只用用来处理小于1100的相关指令
|
|
* 大于1100的指令,
|
|
* 下发的指令格式均为 param0(4byte),param1(4byte),param2(4byte)....
|
|
* 回执均为 ack0 (4byte),ack1 (4byte),ack2 (4byte)....
|
|
*
|
|
*/
|
|
#define PROCESS_CMD(cmd, _subcmdid, id) \
|
|
if ((cmdheader->cmdid == (uint16_t)cmd) && (cmdheader->subcmdid == _subcmdid) && cmdheader->data[0] == id) { \
|
|
matching = true; \
|
|
} \
|
|
if ((cmdheader->cmdid == (uint16_t)cmd) && (cmdheader->subcmdid == _subcmdid) && cmdheader->data[0] == id)
|
|
|
|
/**
|
|
* @brief
|
|
*/
|