iot
橘长_
攻城狮
展开
-
cJSON解析心知天气
cJSON *root = cJSON_Parse(rx_buffer);cJSON *array = cJSON_GetObjectItem(root, "results");cJSON *results0 = cJSON_GetArrayItem(array, 0);cJSON *location = cJSON_GetObjectItem(results0, "location");cJSON *now = cJSON_GetObjectItem(results0, "now");prin原创 2021-10-29 15:47:53 · 642 阅读 · 0 评论 -
esp8266+smartconfig+socket
#include <string.h>#include <stdlib.h>#include "freertos/FreeRTOS.h"#include "freertos/task.h"#include "freertos/event_groups.h"#include "driver/uart.h"#include "esp_err.h"#include "esp_wifi.h"#include "esp_event.h"#include "esp_log.h原创 2021-10-20 16:54:20 · 3742 阅读 · 0 评论 -
esp8266编译环境搭建踩坑
make menuconfig按照github上的wikihttps://github.com/espressif/ESP8266_RTOS_SDK走到这一步:问题一:ubuntu@ubuntu-vpc:~/esp_tools/ESP8266_RTOS_SDK/examples/get-started/hello_world$ make menuconfig make[1]: 进入目录“/home/ubuntu/esp_tools/ESP8266_RTOS_SDK/tools/kconfig”原创 2021-09-05 01:24:18 · 1239 阅读 · 0 评论 -
HSV转RGB
公式C代码实现void HSVtoRGB(uint16_t h, uint16_t s, uint16_t v){ uint8_t r, g, b; // R,G,B from 0-255, H from 0-360, S,V from 0-100 int i; float RGB_min, RGB_max; RGB_max = v*2.55f; RGB_min = RGB_max*(100 - s) / 100.0f; i = h原创 2021-08-30 20:57:21 · 632 阅读 · 0 评论 -
物联网学习之旅(1)搭建mqtt服务器
物联网学习之旅(1)搭建mqtt服务器1.准备centos 7.9云服务器MQTT ExplorerMQTTX2.云服务器安装EMQ安装社区版emq3.添加用户认证# etc/plugins/emqx_auth_username.conf## 第一组认证数据auth.user.1.username = adminauth.user.1.password = public## 第二组认证数据auth.user.2.username = wivwivauth.user.2.p原创 2021-04-11 21:01:23 · 240 阅读 · 1 评论 -
ubuntu18 安装nodejs v14 hpm
ubuntu18云服务器安装hpm1.安装gn, ninja, riscv32-linux-gcc2.安装hpm#====================================================================================================#============================================================================================原创 2021-01-17 20:25:12 · 1040 阅读 · 1 评论 -
ubuntu18安装nodered
ubuntu18安装node redmkdir downloadcd download# 安装nodejswget https://nodejs.org/dist/v9.9.0/node-v9.9.0-linux-x64.tar.xztar xvJf node-v9.9.0-linux-x64.tar.xzsudo mv node-v9.9.0-linux-x64 /usr/local/node-v9sudo ln -s /usr/local/node-v9/bin/node /bin/n原创 2021-01-17 20:21:42 · 827 阅读 · 0 评论