#endif
//int test_number_array[] = {1012744,864594,698914,532908,402542,317532,235462,168856,142664,109818,42654};
+#if 0
cJSON * json_send = cJSON_CreateObject();
cJSON_AddItemToObject(json_send, "app_key", cJSON_CreateString(HENGAI_HTTP_POST_APP_KEY));
cJSON_AddItemToObject(json_send, "mac", cJSON_CreateString(imei));
char * post_data = cJSON_Print(json_send);
cJSON_Delete(json_send);
json_send = NULL;
+#else
+
+int temp_len = 0;
+ char * post_data = lv_mem_alloc(MMI_HENGAI_BP_RAW_DATA_LEN * 9 + 256);
+ if(NULL == post_data)
+ return ;
+ _lv_memset_00(post_data, (MMI_HENGAI_BP_RAW_DATA_LEN * 9 + 256));
+
+ temp_len += sprintf(post_data + temp_len, "{\"app_key\":\"%s\",", HENGAI_HTTP_POST_APP_KEY);
+
+ temp_len += sprintf(post_data + temp_len, "\"mac\":\"%s\",", imei);
+
+ temp_len += sprintf(post_data + temp_len, "\"begin_time\":\"%s\",", begin_time_str);
+
+ temp_len += sprintf(post_data + temp_len, "\"end_time\":\"%s\",", end_time_str);
+
+ uint16_t i = 0;
+ int * temp_int_ptr = mmi_hengai_bp_raw_data_ptr_get();
+ int temp_int_len = mmi_hengai_bp_raw_data_len_get();
+ temp_len += sprintf(post_data + temp_len, "\"pulse_wave\":[");
+ for(i = 0; i < temp_int_len; i++)
+ {
+ if(i == (temp_int_len - 1))
+ {
+ temp_len += sprintf(post_data + temp_len, "%d]", temp_int_ptr[i]);
+ }
+ else
+ {
+ temp_len += sprintf(post_data + temp_len, "%d,", temp_int_ptr[i]);
+ }
+ }
+
+ temp_len += sprintf(post_data + temp_len, "\"sample_rate\":%d}", MMI_HENGAI_BP_RAW_DATA_SAMPLE_RATE);
+#endif
char url[256] = {0};
char * url_suffix = "/health/bp/measurement";
}
}
+
+ lv_mem_free(post_data);
+ post_data = NULL;
+
+
if(NULL != s_hengai_http_revceive_buf)
{
lv_mem_free(s_hengai_http_revceive_buf);