1 /*
2  * Copyright (C) 2015-2018 Alibaba Group Holding Limited
3  */
4 
5 #ifndef _DM_OTA_H_
6 #define _DM_OTA_H_
7 
8 typedef struct {
9     void *ota_handle;
10     char product_key[IOTX_PRODUCT_KEY_LEN + 1];
11     char device_name[IOTX_DEVICE_NAME_LEN + 1];
12 } dm_ota_ctx_t;
13 
14 int dm_ota_init(void);
15 int dm_ota_sub(void);
16 int dm_ota_deinit(void);
17 int dm_ota_get_ota_handle(void **handle);
18 #ifdef DEVICE_MODEL_GATEWAY
19 #ifdef DEVICE_MODEL_SUBDEV_OTA
20 int dm_ota_switch_device(int devid);
21 #endif
22 #endif
23 #endif
24