Commit 72bd42c0 authored by whmaizmy's avatar whmaizmy

【修改内容】1,增加comom下面的hal目录;2,增加kk_topic_mng.c,通过product type跟product code订阅

【提交人】陈伟灿
parent a3d22f20
...@@ -15,6 +15,6 @@ LDFLAGS += -lapi_com ...@@ -15,6 +15,6 @@ LDFLAGS += -lapi_com
LDFLAGS += -L$(TOP_DIR)/common/nanomsg -static -lnanomsg LDFLAGS += -L$(TOP_DIR)/common/nanomsg -static -lnanomsg
LDFLAGS += -L$(TOP_DIR)/common/ev -static -lev LDFLAGS += -L$(TOP_DIR)/common/ev -static -lev
LDFLAGS += -L$(TOP_DIR)/output/release/lib -static -lapi_com LDFLAGS += -L$(TOP_DIR)/output/release/lib -static -lapi_com
LDFLAGS += -liot_cjson -liot_mqtt -lsqlite -ldl -lm -lanl LDFLAGS += -liot_cjson -liot_mqtt -lsqlite -ldl -lm -lanl -lkk_hal
...@@ -13,5 +13,8 @@ ...@@ -13,5 +13,8 @@
#define PASSWORD "2ca1442865ff4cb99870f60f2c646190" #define PASSWORD "2ca1442865ff4cb99870f60f2c646190"
#define AUTO_CONN 1 #define AUTO_CONN 1
#define CONNECT_TIMEOUT 3 #define CONNECT_TIMEOUT 3
#endif #endif
...@@ -21,10 +21,9 @@ ...@@ -21,10 +21,9 @@
#include "MQTTAsync.h" #include "MQTTAsync.h"
#include "mqtt_api.h" #include "mqtt_api.h"
#include "com_api.h" #include "com_api.h"
#include "kk_product.h"
#define THREAD_NUM 10
static int mqtt_start(void) static int mqtt_start(void)
{ {
int count = 0; int count = 0;
...@@ -66,8 +65,9 @@ int main(int argc, char* argv[]) ...@@ -66,8 +65,9 @@ int main(int argc, char* argv[])
//KK_Data_Hdl_Init(); //KK_Data_Hdl_Init();
/*set the callback to get the device date to cloud*/ /*set the callback to get the device date to cloud*/
HAL_SetProduct_Type(PRODUCT_TPYE);
HAL_SetProduct_Code(PRODUCT_CODE);
kk_ipc_init(IPC_APP2MID,KK_Sendto_CloudData); kk_ipc_init(IPC_APP2MID,KK_Sendto_CloudData);
rc = mqtt_start(); rc = mqtt_start();
return rc; return rc;
......
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include "kk_product.h"
const char KK_URI_SYS_PREFIX[] = "/sys/%s/%s/#";
int _kk_client_subscribe(char productType[PRODUCT_TYPE_LEN], char productCode[PRODUCT_CODE_LEN])
{
int res = 0, index = 0, fail_count = 0;
int url_len = 0;
printf("[%s][%d] \n",__FUNCTION__,__LINE__);
url_len = strlen(KK_URI_SYS_PREFIX) + strlen(productType) + strlen(productCode) + 1;
char *url = malloc(url_len);
if (url == NULL) {
return -1;
}
memset(url, 0, url_len);
snprintf(url, url_len, KK_URI_SYS_PREFIX, productType, productCode);
printf("[%s][%d] URL:%s\n",__FUNCTION__,__LINE__,url);
res = KK_MQTT_SubTopic(url);
free(url);
return 0;
}
int KK_Client_Gateway_Subscribe(void)
{
char prpductType[PRODUCT_TYPE_LEN];
char prpductCode[PRODUCT_CODE_LEN];
HAL_GetProduct_Type(prpductType);
HAL_GetProduct_Code(prpductCode);
return _kk_client_subscribe(prpductType,prpductCode);
}
...@@ -124,7 +124,7 @@ static void onConnectBuild(void *context, char *cause) ...@@ -124,7 +124,7 @@ static void onConnectBuild(void *context, char *cause)
{ {
int rc = 0; int rc = 0;
INFO_PRINT("onConnectBuild:%s \n",cause); INFO_PRINT("onConnectBuild:%s \n",cause);
rc = KK_MQTT_SubTopic(TOPIC); rc = KK_Client_Gateway_Subscribe();
if(rc != 0) if(rc != 0)
{ {
ERROR_PRINT("KK_MQTT_SubTopic ERROR rc = %d\n",rc); ERROR_PRINT("KK_MQTT_SubTopic ERROR rc = %d\n",rc);
......
/*
* Copyright (C) 2015-2018 Alibaba Group Holding Limited
*/
#include <stdio.h>
#include <stdlib.h>
#include <stdarg.h>
#include <memory.h>
#include <pthread.h>
#include <unistd.h>
#include <sys/prctl.h>
#include <sys/time.h>
#include <semaphore.h>
#include <errno.h>
#include <assert.h>
#include <net/if.h> // struct ifreq
#include <sys/socket.h>
#include <netinet/in.h>
#include <arpa/inet.h>
#include <sys/ioctl.h>
#include <sys/reboot.h>
#include <sys/time.h>
#include <time.h>
#include <signal.h>
#include "kk_product.h"
//#include "iot_import.h"
char g_product_type[PRODUCT_TYPE_LEN];
char g_product_code[PRODUCT_CODE_LEN];
char g_device_code[DEVICE_CODE_LEN];
#define PLATFORM_WAIT_INFINITE (~0)
void *HAL_Malloc(_IN_ uint32_t size)
{
return malloc(size);
}
void *HAL_Realloc(_IN_ void *ptr, _IN_ uint32_t size)
{
return realloc(ptr, size);
}
void *HAL_Calloc(_IN_ uint32_t nmemb, _IN_ uint32_t size)
{
return calloc(nmemb, size);
}
void HAL_Free(_IN_ void *ptr)
{
free(ptr);
}
void *HAL_MutexCreate(void)
{
int err_num;
pthread_mutex_t *mutex = (pthread_mutex_t *)HAL_Malloc(sizeof(pthread_mutex_t));
if (NULL == mutex) {
return NULL;
}
if (0 != (err_num = pthread_mutex_init(mutex, NULL))) {
printf("create mutex failed");
HAL_Free(mutex);
return NULL;
}
return mutex;
}
void HAL_MutexDestroy(_IN_ void *mutex)
{
int err_num;
if (!mutex) {
printf("mutex want to destroy is NULL!");
return;
}
if (0 != (err_num = pthread_mutex_destroy((pthread_mutex_t *)mutex))) {
printf("destroy mutex failed");
}
HAL_Free(mutex);
}
void HAL_MutexLock(_IN_ void *mutex)
{
int err_num;
if (0 != (err_num = pthread_mutex_lock((pthread_mutex_t *)mutex))) {
printf("lock mutex failed: - '%s' (%d)", strerror(err_num), err_num);
}
}
void HAL_MutexUnlock(_IN_ void *mutex)
{
int err_num;
if (0 != (err_num = pthread_mutex_unlock((pthread_mutex_t *)mutex))) {
printf("unlock mutex failed - '%s' (%d)", strerror(err_num), err_num);
}
}
uint64_t HAL_UptimeMs(void)
{
uint64_t time_ms;
struct timespec ts;
clock_gettime(CLOCK_MONOTONIC, &ts);
time_ms = ((uint64_t)ts.tv_sec * (uint64_t)1000) + (ts.tv_nsec / 1000 / 1000);
return time_ms;
}
char *HAL_GetTimeStr(_IN_ char *buf, _IN_ int len)
{
struct timeval tv;
struct tm tm;
int str_len = 0;
if (buf == NULL || len < 28) {
return NULL;
}
gettimeofday(&tv, NULL);
localtime_r(&tv.tv_sec, &tm);
strftime(buf, 28, "%m-%d %H:%M:%S", &tm);
str_len = strlen(buf);
if (str_len + 3 < len) {
snprintf(buf + str_len, len, ".%3.3d", (int)(tv.tv_usec) / 1000);
}
return buf;
}
void HAL_SleepMs(_IN_ uint32_t ms)
{
usleep(1000 * ms);
}
void HAL_Srandom(uint32_t seed)
{
srandom(seed);
}
uint32_t HAL_Random(uint32_t region)
{
return (region > 0) ? (random() % region) : 0;
}
int HAL_Snprintf(_IN_ char *str, const int len, const char *fmt, ...)
{
va_list args;
int rc;
va_start(args, fmt);
rc = vsnprintf(str, len, fmt, args);
va_end(args);
return rc;
}
int HAL_Vsnprintf(_IN_ char *str, _IN_ const int len, _IN_ const char *format, va_list ap)
{
return vsnprintf(str, len, format, ap);
}
void HAL_Printf(_IN_ const char *fmt, ...)
{
va_list args;
va_start(args, fmt);
vprintf(fmt, args);
va_end(args);
fflush(stdout);
}
int HAL_SetProduct_Type(_IN_ char *product_type)
{
int len = strlen(product_type);
if (len > PRODUCT_TYPE_LEN) {
return -1;
}
memset(g_product_type, 0x0, PRODUCT_TYPE_LEN);
strncpy(g_product_type, product_type, len);
return len;
}
int HAL_SetProduct_Code(_IN_ char *product_code)
{
int len = strlen(product_code);
if (len > PRODUCT_CODE_LEN) {
return -1;
}
memset(g_product_code, 0x0, PRODUCT_CODE_LEN);
strncpy(g_product_code, product_code, len);
return len;
}
int HAL_SetDevice_Code(_IN_ char *device_code)
{
int len = strlen(device_code);
if (len > DEVICE_CODE_LEN) {
return -1;
}
memset(g_device_code, 0x0, DEVICE_CODE_LEN);
strncpy(g_device_code, DEVICE_CODE_LEN, len);
return len;
}
int HAL_GetProduct_Type(_OU_ char *product_type)
{
int len = strlen(g_product_type);
memset(product_type, 0x0, PRODUCT_TYPE_LEN);
strncpy(product_type, g_product_type, len);
return len;
}
int HAL_GetProduct_Code(_OU_ char *product_code)
{
int len = strlen(g_product_code);
memset(product_code, 0x0, PRODUCT_CODE_LEN);
strncpy(product_code, g_product_code, len);
return len;
}
int HAL_GetDevice_Code(_OU_ char *device_code)
{
int len = strlen(g_device_code);
memset(device_code, 0x0, DEVICE_CODE_LEN);
strncpy(device_code, g_device_code, len);
return len;
}
/*
* This need to be same with app version as in uOTA module (ota_version.h)
#ifndef SYSINFO_APP_VERSION
#define SYSINFO_APP_VERSION "app-1.0.0-20180101.1000"
#endif
*
*/
int HAL_GetFirmwareVersion(_OU_ char *version)
{
char *ver = "app-1.0.0-20180101.1000";
int len = strlen(ver);
memset(version, 0x0, FIRMWARE_VERSION_MAXLEN);
strncpy(version, ver, len);
version[len] = '\0';
return strlen(version);
}
void *HAL_SemaphoreCreate(void)
{
sem_t *sem = (sem_t *)malloc(sizeof(sem_t));
if (NULL == sem) {
return NULL;
}
if (0 != sem_init(sem, 0, 0)) {
free(sem);
return NULL;
}
return sem;
}
void HAL_SemaphoreDestroy(_IN_ void *sem)
{
sem_destroy((sem_t *)sem);
free(sem);
}
void HAL_SemaphorePost(_IN_ void *sem)
{
sem_post((sem_t *)sem);
}
int HAL_SemaphoreWait(_IN_ void *sem, _IN_ uint32_t timeout_ms)
{
if (PLATFORM_WAIT_INFINITE == timeout_ms) {
sem_wait(sem);
return 0;
} else {
struct timespec ts;
int s;
/* Restart if interrupted by handler */
do {
if (clock_gettime(CLOCK_REALTIME, &ts) == -1) {
return -1;
}
s = 0;
ts.tv_nsec += (timeout_ms % 1000) * 1000000;
if (ts.tv_nsec >= 1000000000) {
ts.tv_nsec -= 1000000000;
s = 1;
}
ts.tv_sec += timeout_ms / 1000 + s;
} while (((s = sem_timedwait(sem, &ts)) != 0) && errno == EINTR);
return (s == 0) ? 0 : -1;
}
}
int HAL_ThreadCreate(
_OU_ void **thread_handle,
_IN_ void *(*work_routine)(void *),
_IN_ void *arg,
_OU_ int *stack_used)
{
int ret = -1;
ret = pthread_create((pthread_t *)thread_handle, NULL, work_routine, arg);
return ret;
}
void HAL_ThreadDetach(_IN_ void *thread_handle)
{
pthread_detach((pthread_t)thread_handle);
}
void HAL_ThreadDelete(_IN_ void *thread_handle)
{
if (NULL == thread_handle) {
pthread_exit(0);
} else {
/*main thread delete child thread*/
pthread_cancel((pthread_t)thread_handle);
pthread_join((pthread_t)thread_handle, 0);
}
}
#if 0
static FILE *fp;
#define otafilename "/tmp/alinkota.bin"
void HAL_Firmware_Persistence_Start(void)
{
#ifdef __DEMO__
fp = fopen(otafilename, "w");
// assert(fp);
#endif
return;
}
int HAL_Firmware_Persistence_Write(_IN_ char *buffer, _IN_ uint32_t length)
{
#ifdef __DEMO__
unsigned int written_len = 0;
written_len = fwrite(buffer, 1, length, fp);
if (written_len != length) {
return -1;
}
#endif
return 0;
}
int HAL_Firmware_Persistence_Stop(void)
{
#ifdef __DEMO__
if (fp != NULL) {
fclose(fp);
}
#endif
/* check file md5, and burning it to flash ... finally reboot system */
return 0;
}
int HAL_Config_Write(const char *buffer, int length)
{
FILE *fp;
size_t written_len;
char filepath[128] = {0};
if (!buffer || length <= 0) {
return -1;
}
snprintf(filepath, sizeof(filepath), "./%s", "alinkconf");
fp = fopen(filepath, "w");
if (!fp) {
return -1;
}
written_len = fwrite(buffer, 1, length, fp);
fclose(fp);
return ((written_len != length) ? -1 : 0);
}
int HAL_Config_Read(char *buffer, int length)
{
FILE *fp;
size_t read_len;
char filepath[128] = {0};
if (!buffer || length <= 0) {
return -1;
}
snprintf(filepath, sizeof(filepath), "./%s", "alinkconf");
fp = fopen(filepath, "r");
if (!fp) {
return -1;
}
read_len = fread(buffer, 1, length, fp);
fclose(fp);
return ((read_len != length) ? -1 : 0);
}
#define REBOOT_CMD "reboot"
void HAL_Reboot(void)
{
if (system(REBOOT_CMD)) {
perror("HAL_Reboot failed");
}
}
#define ROUTER_INFO_PATH "/proc/net/route"
#define ROUTER_RECORD_SIZE 256
char *_get_default_routing_ifname(char *ifname, int ifname_size)
{
FILE *fp = NULL;
char line[ROUTER_RECORD_SIZE] = {0};
char iface[IFNAMSIZ] = {0};
char *result = NULL;
unsigned int destination, gateway, flags, mask;
unsigned int refCnt, use, metric, mtu, window, irtt;
fp = fopen(ROUTER_INFO_PATH, "r");
if (fp == NULL) {
perror("fopen");
return result;
}
char *buff = fgets(line, sizeof(line), fp);
if (buff == NULL) {
perror("fgets");
goto out;
}
while (fgets(line, sizeof(line), fp)) {
if (11 !=
sscanf(line, "%s %08x %08x %x %d %d %d %08x %d %d %d",
iface, &destination, &gateway, &flags, &refCnt, &use,
&metric, &mask, &mtu, &window, &irtt)) {
perror("sscanf");
continue;
}
/*default route */
if ((destination == 0) && (mask == 0)) {
strncpy(ifname, iface, ifname_size - 1);
result = ifname;
break;
}
}
out:
if (fp) {
fclose(fp);
}
return result;
}
uint32_t HAL_Wifi_Get_IP(char ip_str[NETWORK_ADDR_LEN], const char *ifname)
{
struct ifreq ifreq;
int sock = -1;
char ifname_buff[IFNAMSIZ] = {0};
if ((NULL == ifname || strlen(ifname) == 0) &&
NULL == (ifname = _get_default_routing_ifname(ifname_buff, sizeof(ifname_buff)))) {
perror("get default routeing ifname");
return -1;
}
if ((sock = socket(AF_INET, SOCK_DGRAM, 0)) < 0) {
perror("socket");
return -1;
}
ifreq.ifr_addr.sa_family = AF_INET; //ipv4 address
strncpy(ifreq.ifr_name, ifname, IFNAMSIZ - 1);
if (ioctl(sock, SIOCGIFADDR, &ifreq) < 0) {
close(sock);
perror("ioctl");
return -1;
}
close(sock);
strncpy(ip_str,
inet_ntoa(((struct sockaddr_in *)&ifreq.ifr_addr)->sin_addr),
NETWORK_ADDR_LEN);
return ((struct sockaddr_in *)&ifreq.ifr_addr)->sin_addr.s_addr;
}
#if 0
static kv_file_t *kvfile = NULL;
int HAL_Kv_Set(const char *key, const void *val, int len, int sync)
{
if (!kvfile) {
kvfile = kv_open("/tmp/kvfile.db");
if (!kvfile) {
return -1;
}
}
return kv_set_blob(kvfile, (char *)key, (char *)val, len);
}
int HAL_Kv_Get(const char *key, void *buffer, int *buffer_len)
{
if (!kvfile) {
kvfile = kv_open("/tmp/kvfile.db");
if (!kvfile) {
return -1;
}
}
return kv_get_blob(kvfile, (char *)key, buffer, buffer_len);
}
int HAL_Kv_Del(const char *key)
{
if (!kvfile) {
kvfile = kv_open("/tmp/kvfile.db");
if (!kvfile) {
return -1;
}
}
return kv_del(kvfile, (char *)key);
}
#endif
static long long os_time_get(void)
{
struct timeval tv;
long long ms;
gettimeofday(&tv, NULL);
ms = tv.tv_sec * 1000LL + tv.tv_usec / 1000;
return ms;
}
static long long delta_time = 0;
void HAL_UTC_Set(long long ms)
{
delta_time = ms - os_time_get();
}
long long HAL_UTC_Get(void)
{
return delta_time + os_time_get();
}
void *HAL_Timer_Create(const char *name, void (*func)(void *), void *user_data)
{
timer_t *timer = NULL;
struct sigevent ent;
/* check parameter */
if (func == NULL) {
return NULL;
}
timer = (timer_t *)malloc(sizeof(time_t));
/* Init */
memset(&ent, 0x00, sizeof(struct sigevent));
/* create a timer */
ent.sigev_notify = SIGEV_THREAD;
ent.sigev_notify_function = (void (*)(union sigval))func;
ent.sigev_value.sival_ptr = user_data;
printf("HAL_Timer_Create\n");
if (timer_create(CLOCK_MONOTONIC, &ent, timer) != 0) {
free(timer);
return NULL;
}
return (void *)timer;
}
int HAL_Timer_Start(void *timer, int ms)
{
struct itimerspec ts;
/* check parameter */
if (timer == NULL) {
return -1;
}
/* it_interval=0: timer run only once */
ts.it_interval.tv_sec = 0;
ts.it_interval.tv_nsec = 0;
/* it_value=0: stop timer */
ts.it_value.tv_sec = ms / 1000;
ts.it_value.tv_nsec = (ms % 1000) * 1000;
return timer_settime(*(timer_t *)timer, 0, &ts, NULL);
}
int HAL_Timer_Stop(void *timer)
{
struct itimerspec ts;
/* check parameter */
if (timer == NULL) {
return -1;
}
/* it_interval=0: timer run only once */
ts.it_interval.tv_sec = 0;
ts.it_interval.tv_nsec = 0;
/* it_value=0: stop timer */
ts.it_value.tv_sec = 0;
ts.it_value.tv_nsec = 0;
return timer_settime(*(timer_t *)timer, 0, &ts, NULL);
}
int HAL_Timer_Delete(void *timer)
{
int ret = 0;
/* check parameter */
if (timer == NULL) {
return -1;
}
ret = timer_delete(*(timer_t *)timer);
free(timer);
return ret;
}
#endif
LIBA_TARGET := libkk_hal.a
\ No newline at end of file
#ifndef __KK_PRODUCT_H__
#define __KK_PRODUCT_H__
#include <stdio.h>
#ifndef _IN_
#define _IN_
#endif
#ifndef _OU_
#define _OU_
#endif
#define PRODUCT_TYPE_LEN (32+1)
#define PRODUCT_CODE_LEN (32+1)
#define DEVICE_CODE_LEN (64+1)
#define MAC_ADDR_LEN_MAX (10)
#define PID_STRLEN_MAX (64)
#define MID_STRLEN_MAX (64)
#define IOTX_URI_MAX_LEN (135) /* IoTx CoAP/HTTP uri & MQTT topic maximal length */
#define PID_STR_MAXLEN (64)
#define MID_STR_MAXLEN (64)
#define PRODUCT_SECRET_MAXLEN (64 + 1)
#define FIRMWARE_VERSION_MAXLEN (32 + 1)
#define HAL_CID_LEN (64 + 1)
#define PRODUCT_TPYE "a1OYuSBt23u"
#define PRODUCT_CODE "aIqEbWno8yDdsjCX15iq"
int HAL_SetProduct_Type(_IN_ char *product_type);
int HAL_SetProduct_Code(_IN_ char *product_code);
int HAL_SetDevice_Code(_IN_ char *device_code);
int HAL_GetProduct_Type(_OU_ char *product_type);
int HAL_GetProduct_Code(_OU_ char *product_code);
int HAL_GetDevice_Code(_OU_ char *device_code);
#endif
...@@ -18,6 +18,7 @@ SUBDIRS += common/api ...@@ -18,6 +18,7 @@ SUBDIRS += common/api
SUBDIRS += common/nanomsg SUBDIRS += common/nanomsg
SUBDIRS += common/ev SUBDIRS += common/ev
SUBDIRS += common/sqlite SUBDIRS += common/sqlite
SUBDIRS += common/hal
#SUBDIRS += platform/zigbee #SUBDIRS += platform/zigbee
$(call Append_Conditional, SUBDIRS) $(call Append_Conditional, SUBDIRS)
......
/*
* please modify this string follow as product's TSL.
*/
static const char TSL_STRING[] =
"{\"schema\":\"https://iotx-tsl.oss-ap-southeast-1.aliyuncs.com/"
"schema.json\",\"profile\":{\"productKey\":\"a1X2bEnP82z\"},\"services\":[{"
"\"outputData\":[],\"identifier\":\"set\",\"inputData\":[{\"identifier\":"
"\"LightSwitch\",\"dataType\":{\"specs\":{\"0\":\"关闭\",\"1\":\"开启\"},"
"\"type\":\"bool\"},\"name\":\"主灯开关\"},{\"identifier\":\"WIFI_Band\","
"\"dataType\":{\"specs\":{\"length\":\"255\"},\"type\":\"text\"},\"name\":"
"\"频段\"},{\"identifier\":\"WiFI_RSSI\",\"dataType\":{\"specs\":{\"min\":\"-"
"127\",\"unitName\":\"无\",\"max\":\"-1\",\"step\":\"1\"},\"type\":\"int\"},"
"\"name\":\"信号强度\"},{\"identifier\":\"WIFI_AP_BSSID\",\"dataType\":{"
"\"specs\":{\"length\":\"255\"},\"type\":\"text\"},\"name\":\"热点BSSID\"},{"
"\"identifier\":\"WIFI_Channel\",\"dataType\":{\"specs\":{\"min\":\"1\","
"\"unitName\":\"无\",\"max\":\"255\",\"step\":\"1\"},\"type\":\"int\"},"
"\"name\":\"信道\"},{\"identifier\":\"WiFI_SNR\",\"dataType\":{\"specs\":{"
"\"min\":\"-127\",\"unitName\":\"无\",\"max\":\"127\",\"step\":\"1\"},"
"\"type\":\"int\"},\"name\":\"信噪比\"},{\"identifier\":\"WIFI_Tx_Rate\","
"\"dataType\":{\"specs\":{\"min\":\"0\",\"max\":\"99999\",\"step\":\"1\"},"
"\"type\":\"int\"},\"name\":\"WIFI_Tx_Rate_Name\"},{\"identifier\":\"WIFI_Rx_"
"Rate\",\"dataType\":{\"specs\":{\"min\":\"0\",\"max\":\"99999\",\"step\":"
"\"1\"},\"type\":\"int\"},\"name\":\"WIFI_Rx_Rate_Name\"},{\"identifier\":"
"\"RGBColor\",\"dataType\":{\"specs\":[{\"identifier\":\"Red\",\"dataType\":{"
"\"specs\":{\"min\":\"0\",\"unitName\":\"无\",\"max\":\"255\",\"step\":\"1\"}"
",\"type\":\"int\"},\"name\":\"红色\"},{\"identifier\":\"Green\","
"\"dataType\":{\"specs\":{\"min\":\"0\",\"unitName\":\"无\",\"max\":\"255\","
"\"step\":\"1\"},\"type\":\"int\"},\"name\":\"绿色\"},{\"identifier\":"
"\"Blue\",\"dataType\":{\"specs\":{\"min\":\"0\",\"unitName\":\"无\",\"max\":"
"\"255\",\"step\":\"1\"},\"type\":\"int\"},\"name\":\"蓝色\"}],\"type\":"
"\"struct\"},\"name\":\"RGB调色\"},{\"identifier\":\"HSVColor\",\"dataType\":"
"{\"specs\":[{\"identifier\":\"Hue\",\"dataType\":{\"specs\":{\"unit\":\"°\","
"\"min\":\"0\",\"unitName\":\"度\",\"max\":\"360\",\"step\":\"0.01\"},"
"\"type\":\"double\"},\"name\":\"色调\"},{\"identifier\":\"Saturation\","
"\"dataType\":{\"specs\":{\"unit\":\"%\",\"min\":\"0\",\"unitName\":"
"\"百分比\",\"max\":\"100\",\"step\":\"0.01\"},\"type\":\"double\"},\"name\":"
"\"饱和度\"},{\"identifier\":\"Value\",\"dataType\":{\"specs\":{\"unit\":\"%"
"\",\"min\":\"0\",\"unitName\":\"百分比\",\"max\":\"100\",\"step\":\"0.01\"},"
"\"type\":\"double\"},\"name\":\"明度\"}],\"type\":\"struct\"},\"name\":"
"\"HSV调色\"},{\"identifier\":\"HSLColor\",\"dataType\":{\"specs\":[{"
"\"identifier\":\"Hue\",\"dataType\":{\"specs\":{\"unit\":\"°\",\"min\":"
"\"0\",\"unitName\":\"度\",\"max\":\"360\",\"step\":\"0.01\"},\"type\":"
"\"double\"},\"name\":\"色调\"},{\"identifier\":\"Saturation\",\"dataType\":{"
"\"specs\":{\"unit\":\"%\",\"min\":\"0\",\"unitName\":\"百分比\",\"max\":"
"\"100\",\"step\":\"0.01\"},\"type\":\"double\"},\"name\":\"饱和度\"},{"
"\"identifier\":\"Lightness\",\"dataType\":{\"specs\":{\"unit\":\"%\","
"\"min\":\"0\",\"unitName\":\"百分比\",\"max\":\"100\",\"step\":\"0.01\"},"
"\"type\":\"double\"},\"name\":\"亮度\"}],\"type\":\"struct\"},\"name\":"
"\"HSL调色\"},{\"identifier\":\"WorkMode\",\"dataType\":{\"specs\":{\"0\":"
"\"手动\",\"1\":\"阅读\",\"2\":\"影院\",\"3\":\"夜灯\",\"4\":\"生活\",\"5\":"
"\"柔和\"},\"type\":\"enum\"},\"name\":\"工作模式\"},{\"identifier\":"
"\"NightLightSwitch\",\"dataType\":{\"specs\":{\"0\":\"关闭\",\"1\":\"开启\"}"
",\"type\":\"bool\"},\"name\":\"夜灯开关\"},{\"identifier\":\"Brightness\","
"\"dataType\":{\"specs\":{\"unit\":\"%\",\"min\":\"0\",\"unitName\":"
"\"百分比\",\"max\":\"100\",\"step\":\"1\"},\"type\":\"int\"},\"name\":"
"\"明暗度\"},{\"identifier\":\"ColorTemperature\",\"dataType\":{\"specs\":{"
"\"unit\":\"K\",\"min\":\"2000\",\"unitName\":\"开尔文\",\"max\":\"7000\","
"\"step\":\"1\"},\"type\":\"int\"},\"name\":\"冷暖色温\"},{\"identifier\":"
"\"PropertyCharacter\",\"dataType\":{\"specs\":{\"length\":\"255\"},\"type\":"
"\"text\"},\"name\":\"PropertyCharacter_Name\"},{\"identifier\":"
"\"Propertypoint\",\"dataType\":{\"specs\":{\"min\":\"-100\",\"max\":\"100\","
"\"step\":\"0.01\"},\"type\":\"double\"},\"name\":\"Propertypoint_Name\"}],"
"\"method\":\"thing.service.property.set\",\"name\":\"set\",\"required\":"
"true,\"callType\":\"async\",\"desc\":\"属性设置\"},{\"outputData\":[{"
"\"identifier\":\"LightSwitch\",\"dataType\":{\"specs\":{\"0\":\"关闭\","
"\"1\":\"开启\"},\"type\":\"bool\"},\"name\":\"主灯开关\"},{\"identifier\":"
"\"WIFI_Band\",\"dataType\":{\"specs\":{\"length\":\"255\"},\"type\":"
"\"text\"},\"name\":\"频段\"},{\"identifier\":\"WiFI_RSSI\",\"dataType\":{"
"\"specs\":{\"min\":\"-127\",\"unitName\":\"无\",\"max\":\"-1\",\"step\":"
"\"1\"},\"type\":\"int\"},\"name\":\"信号强度\"},{\"identifier\":\"WIFI_AP_"
"BSSID\",\"dataType\":{\"specs\":{\"length\":\"255\"},\"type\":\"text\"},"
"\"name\":\"热点BSSID\"},{\"identifier\":\"WIFI_Channel\",\"dataType\":{"
"\"specs\":{\"min\":\"1\",\"unitName\":\"无\",\"max\":\"255\",\"step\":\"1\"}"
",\"type\":\"int\"},\"name\":\"信道\"},{\"identifier\":\"WiFI_SNR\","
"\"dataType\":{\"specs\":{\"min\":\"-127\",\"unitName\":\"无\",\"max\":"
"\"127\",\"step\":\"1\"},\"type\":\"int\"},\"name\":\"信噪比\"},{"
"\"identifier\":\"WIFI_Tx_Rate\",\"dataType\":{\"specs\":{\"min\":\"0\","
"\"max\":\"99999\",\"step\":\"1\"},\"type\":\"int\"},\"name\":\"WIFI_Tx_Rate_"
"Name\"},{\"identifier\":\"WIFI_Rx_Rate\",\"dataType\":{\"specs\":{\"min\":"
"\"0\",\"max\":\"99999\",\"step\":\"1\"},\"type\":\"int\"},\"name\":\"WIFI_"
"Rx_Rate_Name\"},{\"identifier\":\"RGBColor\",\"dataType\":{\"specs\":[{"
"\"identifier\":\"Red\",\"dataType\":{\"specs\":{\"min\":\"0\",\"unitName\":"
"\"无\",\"max\":\"255\",\"step\":\"1\"},\"type\":\"int\"},\"name\":\"红色\"},"
"{\"identifier\":\"Green\",\"dataType\":{\"specs\":{\"min\":\"0\","
"\"unitName\":\"无\",\"max\":\"255\",\"step\":\"1\"},\"type\":\"int\"},"
"\"name\":\"绿色\"},{\"identifier\":\"Blue\",\"dataType\":{\"specs\":{"
"\"min\":\"0\",\"unitName\":\"无\",\"max\":\"255\",\"step\":\"1\"},\"type\":"
"\"int\"},\"name\":\"蓝色\"}],\"type\":\"struct\"},\"name\":\"RGB调色\"},{"
"\"identifier\":\"HSVColor\",\"dataType\":{\"specs\":[{\"identifier\":"
"\"Hue\",\"dataType\":{\"specs\":{\"unit\":\"°\",\"min\":\"0\",\"unitName\":"
"\"度\",\"max\":\"360\",\"step\":\"0.01\"},\"type\":\"double\"},\"name\":"
"\"色调\"},{\"identifier\":\"Saturation\",\"dataType\":{\"specs\":{\"unit\":"
"\"%\",\"min\":\"0\",\"unitName\":\"百分比\",\"max\":\"100\",\"step\":\"0."
"01\"},\"type\":\"double\"},\"name\":\"饱和度\"},{\"identifier\":\"Value\","
"\"dataType\":{\"specs\":{\"unit\":\"%\",\"min\":\"0\",\"unitName\":"
"\"百分比\",\"max\":\"100\",\"step\":\"0.01\"},\"type\":\"double\"},\"name\":"
"\"明度\"}],\"type\":\"struct\"},\"name\":\"HSV调色\"},{\"identifier\":"
"\"HSLColor\",\"dataType\":{\"specs\":[{\"identifier\":\"Hue\",\"dataType\":{"
"\"specs\":{\"unit\":\"°\",\"min\":\"0\",\"unitName\":\"度\",\"max\":\"360\","
"\"step\":\"0.01\"},\"type\":\"double\"},\"name\":\"色调\"},{\"identifier\":"
"\"Saturation\",\"dataType\":{\"specs\":{\"unit\":\"%\",\"min\":\"0\","
"\"unitName\":\"百分比\",\"max\":\"100\",\"step\":\"0.01\"},\"type\":"
"\"double\"},\"name\":\"饱和度\"},{\"identifier\":\"Lightness\",\"dataType\":"
"{\"specs\":{\"unit\":\"%\",\"min\":\"0\",\"unitName\":\"百分比\",\"max\":"
"\"100\",\"step\":\"0.01\"},\"type\":\"double\"},\"name\":\"亮度\"}],"
"\"type\":\"struct\"},\"name\":\"HSL调色\"},{\"identifier\":\"WorkMode\","
"\"dataType\":{\"specs\":{\"0\":\"手动\",\"1\":\"阅读\",\"2\":\"影院\",\"3\":"
"\"夜灯\",\"4\":\"生活\",\"5\":\"柔和\"},\"type\":\"enum\"},\"name\":"
"\"工作模式\"},{\"identifier\":\"NightLightSwitch\",\"dataType\":{\"specs\":{"
"\"0\":\"关闭\",\"1\":\"开启\"},\"type\":\"bool\"},\"name\":\"夜灯开关\"},{"
"\"identifier\":\"Brightness\",\"dataType\":{\"specs\":{\"unit\":\"%\","
"\"min\":\"0\",\"unitName\":\"百分比\",\"max\":\"100\",\"step\":\"1\"},"
"\"type\":\"int\"},\"name\":\"明暗度\"},{\"identifier\":\"ColorTemperature\","
"\"dataType\":{\"specs\":{\"unit\":\"K\",\"min\":\"2000\",\"unitName\":"
"\"开尔文\",\"max\":\"7000\",\"step\":\"1\"},\"type\":\"int\"},\"name\":"
"\"冷暖色温\"},{\"identifier\":\"PropertyCharacter\",\"dataType\":{\"specs\":"
"{\"length\":\"255\"},\"type\":\"text\"},\"name\":\"PropertyCharacter_Name\"}"
",{\"identifier\":\"Propertypoint\",\"dataType\":{\"specs\":{\"min\":\"-"
"100\",\"max\":\"100\",\"step\":\"0.01\"},\"type\":\"double\"},\"name\":"
"\"Propertypoint_Name\"}],\"identifier\":\"get\",\"inputData\":["
"\"LightSwitch\",\"WIFI_Band\",\"WiFI_RSSI\",\"WIFI_AP_BSSID\",\"WIFI_"
"Channel\",\"WiFI_SNR\",\"WIFI_Tx_Rate\",\"WIFI_Rx_Rate\",\"RGBColor\","
"\"HSVColor\",\"HSLColor\",\"WorkMode\",\"NightLightSwitch\",\"Brightness\","
"\"ColorTemperature\",\"PropertyCharacter\",\"Propertypoint\"],\"method\":"
"\"thing.service.property.get\",\"name\":\"get\",\"required\":true,"
"\"callType\":\"async\",\"desc\":\"属性获取\"}],\"properties\":[{"
"\"identifier\":\"LightSwitch\",\"dataType\":{\"specs\":{\"0\":\"关闭\","
"\"1\":\"开启\"},\"type\":\"bool\"},\"name\":\"主灯开关\",\"accessMode\":"
"\"rw\",\"required\":true},{\"identifier\":\"WIFI_Band\",\"dataType\":{"
"\"specs\":{\"length\":\"255\"},\"type\":\"text\"},\"name\":\"频段\","
"\"accessMode\":\"rw\",\"required\":true},{\"identifier\":\"WiFI_RSSI\","
"\"dataType\":{\"specs\":{\"min\":\"-127\",\"unitName\":\"无\",\"max\":\"-"
"1\",\"step\":\"1\"},\"type\":\"int\"},\"name\":\"信号强度\",\"accessMode\":"
"\"rw\",\"required\":true},{\"identifier\":\"WIFI_AP_BSSID\",\"dataType\":{"
"\"specs\":{\"length\":\"255\"},\"type\":\"text\"},\"name\":\"热点BSSID\","
"\"accessMode\":\"rw\",\"required\":true},{\"identifier\":\"WIFI_Channel\","
"\"dataType\":{\"specs\":{\"min\":\"1\",\"unitName\":\"无\",\"max\":\"255\","
"\"step\":\"1\"},\"type\":\"int\"},\"name\":\"信道\",\"accessMode\":\"rw\","
"\"required\":true},{\"identifier\":\"WiFI_SNR\",\"dataType\":{\"specs\":{"
"\"min\":\"-127\",\"unitName\":\"无\",\"max\":\"127\",\"step\":\"1\"},"
"\"type\":\"int\"},\"name\":\"信噪比\",\"accessMode\":\"rw\",\"required\":"
"true},{\"identifier\":\"WIFI_Tx_Rate\",\"dataType\":{\"specs\":{\"min\":"
"\"0\",\"max\":\"99999\",\"step\":\"1\"},\"type\":\"int\"},\"name\":\"WIFI_"
"Tx_Rate_Name\",\"accessMode\":\"rw\",\"required\":false},{\"identifier\":"
"\"WIFI_Rx_Rate\",\"dataType\":{\"specs\":{\"min\":\"0\",\"max\":\"99999\","
"\"step\":\"1\"},\"type\":\"int\"},\"name\":\"WIFI_Rx_Rate_Name\","
"\"accessMode\":\"rw\",\"required\":false},{\"identifier\":\"RGBColor\","
"\"dataType\":{\"specs\":[{\"identifier\":\"Red\",\"dataType\":{\"specs\":{"
"\"min\":\"0\",\"unitName\":\"无\",\"max\":\"255\",\"step\":\"1\"},\"type\":"
"\"int\"},\"name\":\"红色\"},{\"identifier\":\"Green\",\"dataType\":{"
"\"specs\":{\"min\":\"0\",\"unitName\":\"无\",\"max\":\"255\",\"step\":\"1\"}"
",\"type\":\"int\"},\"name\":\"绿色\"},{\"identifier\":\"Blue\",\"dataType\":"
"{\"specs\":{\"min\":\"0\",\"unitName\":\"无\",\"max\":\"255\",\"step\":"
"\"1\"},\"type\":\"int\"},\"name\":\"蓝色\"}],\"type\":\"struct\"},\"name\":"
"\"RGB调色\",\"accessMode\":\"rw\",\"required\":false},{\"identifier\":"
"\"HSVColor\",\"dataType\":{\"specs\":[{\"identifier\":\"Hue\",\"dataType\":{"
"\"specs\":{\"unit\":\"°\",\"min\":\"0\",\"unitName\":\"度\",\"max\":\"360\","
"\"step\":\"0.01\"},\"type\":\"double\"},\"name\":\"色调\"},{\"identifier\":"
"\"Saturation\",\"dataType\":{\"specs\":{\"unit\":\"%\",\"min\":\"0\","
"\"unitName\":\"百分比\",\"max\":\"100\",\"step\":\"0.01\"},\"type\":"
"\"double\"},\"name\":\"饱和度\"},{\"identifier\":\"Value\",\"dataType\":{"
"\"specs\":{\"unit\":\"%\",\"min\":\"0\",\"unitName\":\"百分比\",\"max\":"
"\"100\",\"step\":\"0.01\"},\"type\":\"double\"},\"name\":\"明度\"}],"
"\"type\":\"struct\"},\"name\":\"HSV调色\",\"accessMode\":\"rw\","
"\"required\":false},{\"identifier\":\"HSLColor\",\"dataType\":{\"specs\":[{"
"\"identifier\":\"Hue\",\"dataType\":{\"specs\":{\"unit\":\"°\",\"min\":"
"\"0\",\"unitName\":\"度\",\"max\":\"360\",\"step\":\"0.01\"},\"type\":"
"\"double\"},\"name\":\"色调\"},{\"identifier\":\"Saturation\",\"dataType\":{"
"\"specs\":{\"unit\":\"%\",\"min\":\"0\",\"unitName\":\"百分比\",\"max\":"
"\"100\",\"step\":\"0.01\"},\"type\":\"double\"},\"name\":\"饱和度\"},{"
"\"identifier\":\"Lightness\",\"dataType\":{\"specs\":{\"unit\":\"%\","
"\"min\":\"0\",\"unitName\":\"百分比\",\"max\":\"100\",\"step\":\"0.01\"},"
"\"type\":\"double\"},\"name\":\"亮度\"}],\"type\":\"struct\"},\"name\":"
"\"HSL调色\",\"accessMode\":\"rw\",\"required\":false},{\"identifier\":"
"\"WorkMode\",\"dataType\":{\"specs\":{\"0\":\"手动\",\"1\":\"阅读\",\"2\":"
"\"影院\",\"3\":\"夜灯\",\"4\":\"生活\",\"5\":\"柔和\"},\"type\":\"enum\"},"
"\"name\":\"工作模式\",\"accessMode\":\"rw\",\"required\":false},{"
"\"identifier\":\"NightLightSwitch\",\"dataType\":{\"specs\":{\"0\":\"关闭\","
"\"1\":\"开启\"},\"type\":\"bool\"},\"name\":\"夜灯开关\",\"accessMode\":"
"\"rw\",\"required\":false},{\"identifier\":\"Brightness\",\"dataType\":{"
"\"specs\":{\"unit\":\"%\",\"min\":\"0\",\"unitName\":\"百分比\",\"max\":"
"\"100\",\"step\":\"1\"},\"type\":\"int\"},\"name\":\"明暗度\","
"\"accessMode\":\"rw\",\"required\":false},{\"identifier\":"
"\"ColorTemperature\",\"dataType\":{\"specs\":{\"unit\":\"K\",\"min\":"
"\"2000\",\"unitName\":\"开尔文\",\"max\":\"7000\",\"step\":\"1\"},\"type\":"
"\"int\"},\"name\":\"冷暖色温\",\"accessMode\":\"rw\",\"required\":false},{"
"\"identifier\":\"PropertyCharacter\",\"dataType\":{\"specs\":{\"length\":"
"\"255\"},\"type\":\"text\"},\"name\":\"PropertyCharacter_Name\","
"\"accessMode\":\"rw\",\"required\":false},{\"identifier\":\"Propertypoint\","
"\"dataType\":{\"specs\":{\"min\":\"-100\",\"max\":\"100\",\"step\":\"0.01\"}"
",\"type\":\"double\"},\"name\":\"Propertypoint_Name\",\"accessMode\":\"rw\","
"\"required\":false}],\"events\":[{\"outputData\":[{\"identifier\":"
"\"LightSwitch\",\"dataType\":{\"specs\":{\"0\":\"关闭\",\"1\":\"开启\"},"
"\"type\":\"bool\"},\"name\":\"主灯开关\"},{\"identifier\":\"WIFI_Band\","
"\"dataType\":{\"specs\":{\"length\":\"255\"},\"type\":\"text\"},\"name\":"
"\"频段\"},{\"identifier\":\"WiFI_RSSI\",\"dataType\":{\"specs\":{\"min\":\"-"
"127\",\"unitName\":\"无\",\"max\":\"-1\",\"step\":\"1\"},\"type\":\"int\"},"
"\"name\":\"信号强度\"},{\"identifier\":\"WIFI_AP_BSSID\",\"dataType\":{"
"\"specs\":{\"length\":\"255\"},\"type\":\"text\"},\"name\":\"热点BSSID\"},{"
"\"identifier\":\"WIFI_Channel\",\"dataType\":{\"specs\":{\"min\":\"1\","
"\"unitName\":\"无\",\"max\":\"255\",\"step\":\"1\"},\"type\":\"int\"},"
"\"name\":\"信道\"},{\"identifier\":\"WiFI_SNR\",\"dataType\":{\"specs\":{"
"\"min\":\"-127\",\"unitName\":\"无\",\"max\":\"127\",\"step\":\"1\"},"
"\"type\":\"int\"},\"name\":\"信噪比\"},{\"identifier\":\"WIFI_Tx_Rate\","
"\"dataType\":{\"specs\":{\"min\":\"0\",\"max\":\"99999\",\"step\":\"1\"},"
"\"type\":\"int\"},\"name\":\"WIFI_Tx_Rate_Name\"},{\"identifier\":\"WIFI_Rx_"
"Rate\",\"dataType\":{\"specs\":{\"min\":\"0\",\"max\":\"99999\",\"step\":"
"\"1\"},\"type\":\"int\"},\"name\":\"WIFI_Rx_Rate_Name\"},{\"identifier\":"
"\"RGBColor\",\"dataType\":{\"specs\":[{\"identifier\":\"Red\",\"dataType\":{"
"\"specs\":{\"min\":\"0\",\"unitName\":\"无\",\"max\":\"255\",\"step\":\"1\"}"
",\"type\":\"int\"},\"name\":\"红色\"},{\"identifier\":\"Green\","
"\"dataType\":{\"specs\":{\"min\":\"0\",\"unitName\":\"无\",\"max\":\"255\","
"\"step\":\"1\"},\"type\":\"int\"},\"name\":\"绿色\"},{\"identifier\":"
"\"Blue\",\"dataType\":{\"specs\":{\"min\":\"0\",\"unitName\":\"无\",\"max\":"
"\"255\",\"step\":\"1\"},\"type\":\"int\"},\"name\":\"蓝色\"}],\"type\":"
"\"struct\"},\"name\":\"RGB调色\"},{\"identifier\":\"HSVColor\",\"dataType\":"
"{\"specs\":[{\"identifier\":\"Hue\",\"dataType\":{\"specs\":{\"unit\":\"°\","
"\"min\":\"0\",\"unitName\":\"度\",\"max\":\"360\",\"step\":\"0.01\"},"
"\"type\":\"double\"},\"name\":\"色调\"},{\"identifier\":\"Saturation\","
"\"dataType\":{\"specs\":{\"unit\":\"%\",\"min\":\"0\",\"unitName\":"
"\"百分比\",\"max\":\"100\",\"step\":\"0.01\"},\"type\":\"double\"},\"name\":"
"\"饱和度\"},{\"identifier\":\"Value\",\"dataType\":{\"specs\":{\"unit\":\"%"
"\",\"min\":\"0\",\"unitName\":\"百分比\",\"max\":\"100\",\"step\":\"0.01\"},"
"\"type\":\"double\"},\"name\":\"明度\"}],\"type\":\"struct\"},\"name\":"
"\"HSV调色\"},{\"identifier\":\"HSLColor\",\"dataType\":{\"specs\":[{"
"\"identifier\":\"Hue\",\"dataType\":{\"specs\":{\"unit\":\"°\",\"min\":"
"\"0\",\"unitName\":\"度\",\"max\":\"360\",\"step\":\"0.01\"},\"type\":"
"\"double\"},\"name\":\"色调\"},{\"identifier\":\"Saturation\",\"dataType\":{"
"\"specs\":{\"unit\":\"%\",\"min\":\"0\",\"unitName\":\"百分比\",\"max\":"
"\"100\",\"step\":\"0.01\"},\"type\":\"double\"},\"name\":\"饱和度\"},{"
"\"identifier\":\"Lightness\",\"dataType\":{\"specs\":{\"unit\":\"%\","
"\"min\":\"0\",\"unitName\":\"百分比\",\"max\":\"100\",\"step\":\"0.01\"},"
"\"type\":\"double\"},\"name\":\"亮度\"}],\"type\":\"struct\"},\"name\":"
"\"HSL调色\"},{\"identifier\":\"WorkMode\",\"dataType\":{\"specs\":{\"0\":"
"\"手动\",\"1\":\"阅读\",\"2\":\"影院\",\"3\":\"夜灯\",\"4\":\"生活\",\"5\":"
"\"柔和\"},\"type\":\"enum\"},\"name\":\"工作模式\"},{\"identifier\":"
"\"NightLightSwitch\",\"dataType\":{\"specs\":{\"0\":\"关闭\",\"1\":\"开启\"}"
",\"type\":\"bool\"},\"name\":\"夜灯开关\"},{\"identifier\":\"Brightness\","
"\"dataType\":{\"specs\":{\"unit\":\"%\",\"min\":\"0\",\"unitName\":"
"\"百分比\",\"max\":\"100\",\"step\":\"1\"},\"type\":\"int\"},\"name\":"
"\"明暗度\"},{\"identifier\":\"ColorTemperature\",\"dataType\":{\"specs\":{"
"\"unit\":\"K\",\"min\":\"2000\",\"unitName\":\"开尔文\",\"max\":\"7000\","
"\"step\":\"1\"},\"type\":\"int\"},\"name\":\"冷暖色温\"},{\"identifier\":"
"\"PropertyCharacter\",\"dataType\":{\"specs\":{\"length\":\"255\"},\"type\":"
"\"text\"},\"name\":\"PropertyCharacter_Name\"},{\"identifier\":"
"\"Propertypoint\",\"dataType\":{\"specs\":{\"min\":\"-100\",\"max\":\"100\","
"\"step\":\"0.01\"},\"type\":\"double\"},\"name\":\"Propertypoint_Name\"}],"
"\"identifier\":\"post\",\"method\":\"thing.event.property.post\",\"name\":"
"\"post\",\"type\":\"info\",\"required\":true,\"desc\":\"属性上报\"},{"
"\"outputData\":[{\"identifier\":\"ErrorCode\",\"dataType\":{\"specs\":{"
"\"0\":\"恢复正常\"},\"type\":\"enum\"},\"name\":\"故障代码\"}],"
"\"identifier\":\"Error\",\"method\":\"thing.event.Error.post\",\"name\":"
"\"故障上报\",\"type\":\"error\",\"required\":true}]}";
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment