78 lines
2.2 KiB
C
78 lines
2.2 KiB
C
/****************************************************************************
|
|
|
|
Copyright(c) 2019 by Aerospace C.Power (Chongqing) Microelectronics. ALL RIGHTS RESERVED.
|
|
|
|
This Information is proprietary to Aerospace C.Power (Chongqing) Microelectronics and MAY NOT
|
|
be copied by any method or incorporated into another program without
|
|
the express written consent of Aerospace C.Power. This Information or any portion
|
|
thereof remains the property of Aerospace C.Power. The Information contained herein
|
|
is believed to be accurate and Aerospace C.Power assumes no responsibility or
|
|
liability for its use in any way and conveys no license or title under
|
|
any patent or copyright and makes no representation or warranty that this
|
|
Information is free from patent or copyright infringement.
|
|
|
|
****************************************************************************/
|
|
#ifndef __IOT_CLI_MAC_TEST_H__
|
|
#define __IOT_CLI_MAC_TEST_H__
|
|
|
|
/* common */
|
|
#include "os_types.h"
|
|
|
|
/* mac layer */
|
|
|
|
#ifdef __cplusplus
|
|
extern "C" {
|
|
#endif
|
|
|
|
#define IOT_CLI_MAC_FUN_TEST_ENA 0
|
|
|
|
/* mac test header msg id*/
|
|
#define CLI_MAC_FUN_DUMMY 1
|
|
|
|
/* zc test cmd id */
|
|
#define MAC_FUN_TEST_DUMMY 1
|
|
|
|
#pragma pack(push) // save the pack status
|
|
#pragma pack(1) // 1 byte align
|
|
|
|
typedef struct _cli_mac_test_hdr {
|
|
uint8_t msg_id;
|
|
uint8_t resv0;
|
|
uint8_t resv1;
|
|
uint8_t resv2;
|
|
} cli_mac_test_hdr_t;
|
|
|
|
typedef struct _mac_fun_test_zc_hdr {
|
|
uint8_t cmd_id;
|
|
uint8_t resv0;
|
|
uint8_t resv1;
|
|
uint8_t resv2;
|
|
} mac_fun_test_zc_hdr_t;
|
|
|
|
#pragma pack(pop) // restore the pack status
|
|
|
|
#if IOT_CLI_MAC_FUN_TEST_ENA
|
|
/*
|
|
* @brief cli_mac_fun_test() - cli mac function test entry.
|
|
*
|
|
* @param buffer test message addr
|
|
* for example:
|
|
* 23 23
|
|
* 00 00 00 00 00 00 48 55 5c 03 8f 19
|
|
* 02 00 34 11 A6 00 00 00 08 00 00 00
|
|
* 01 00 00 00 01 00 00 00
|
|
* 40 40
|
|
* @param bufferlen test message length
|
|
* @param src_mac source mac addr, length see IOT_MAC_ADDR_LEN
|
|
*
|
|
* @return none
|
|
*/
|
|
void cli_mac_fun_test(uint8_t *buffer, uint32_t bufferlen, uint8_t *src_mac);
|
|
|
|
#endif
|
|
|
|
#ifdef __cplusplus
|
|
}
|
|
#endif
|
|
|
|
#endif //__IOT_CLI_MAC_TEST_H__
|