1 #ifndef __DEV_RESET_API_H__ 2 #define __DEV_RESET_API_H__ 3 4 #include "linkkit/infra/infra_types.h" 5 #include "linkkit/infra/infra_defs.h" 6 7 typedef enum { 8 IOTX_DEVRST_EVT_RECEIVED 9 } iotx_devrst_evt_type_t; 10 11 typedef struct { 12 int msgid; 13 char *payload; 14 uint32_t payload_len; 15 } iotx_devrst_evt_recv_msg_t; 16 17 typedef void (*iotx_devrst_evt_handle_t)(iotx_devrst_evt_type_t evt, void *msg); 18 19 /** 20 * @brief report reset message to cloud. 21 * 22 * @param meta_info. device meta info, only product_key and device_name needed. 23 * @param extended. reserved. 24 * 25 * @retval -1 : failure 26 * @retval 0 : sucess 27 */ 28 int IOT_DevReset_Report(iotx_dev_meta_info_t *meta_info, 29 iotx_devrst_evt_handle_t handle, void *extended); 30 31 #endif 32