ESP8266+BLINKER一键配网-Arduino中文社区 - Powered by Discuz!

Arduino中文社区

 找回密码
 立即注册

QQ登录

只需一步,快速开始

查看: 1132|回复: 7

[已解答] ESP8266+BLINKER一键配网

[复制链接]
发表于 2022-2-12 17:06 | 显示全部楼层 |阅读模式
本帖最后由 pyq208 于 2022-2-13 23:13 编辑

我用Mixly对ESP8266
图1:
BLINKER一键配网可以自动配网,  但是另存为ARDUINO后
图H
找不到  Blinker.reset();  怎么样?
//=======程序======:
#define BLINKER_WIFI
#define BLINKER_ESP_SMARTCONFIG
#define BLINKER_PRINT Serial
#include "OneButton.h"
#include <Blinker.h>
void deviceReset() {
  Blinker.reset();
}
OneButton button(0, false);
char auth[] = "f42a87XXXXXX";
void setup() {
  Serial.begin(9600);
  BLINKER_DEBUG.stream(BLINKER_PRINT);
  Blinker.begin(auth);
  button.attachLongPressStop(deviceReset);
}
void loop() {
  button.tick();
  Blinker.run();
}

H.png
1.jpg
发表于 2022-2-12 22:18 | 显示全部楼层
确保你使用的库,是点灯官方文档中下载的
 楼主| 发表于 2022-2-13 00:10 | 显示全部楼层
coloz 发表于 2022-2-12 22:18
确保你使用的库,是点灯官方文档中下载的

我把arduino、点灯官方库重新安装一片,还是一个样
发表于 2022-2-13 00:59 | 显示全部楼层
pyq208 发表于 2022-2-13 00:10
我把arduino、点灯官方库重新安装一片,还是一个样

串口调试可以看库的版本,贴出来版本
 楼主| 发表于 2022-2-13 01:04 | 显示全部楼层
coloz 发表于 2022-2-13 00:59
串口调试可以看库的版本,贴出来版本

Arduino:1.8.13 (Windows 7), 开发板:"NodeMCU 1.0 (ESP-12E Module), 80 MHz, Flash, Legacy (new can return nullptr), All SSL ciphers (most compatible), 4MB (FS:2MB OTA:~1019KB), 2, v2 Lower Memory, Disabled, None, Only Sketch, 115200"





















C:\Program Files (x86)\Arduino\arduino-builder -dump-prefs -logger=machine -hardware C:\Program Files (x86)\Arduino\hardware -hardware C:\Users\Administrator\AppData\Local\Arduino15\packages -tools C:\Program Files (x86)\Arduino\tools-builder -tools C:\Program Files (x86)\Arduino\hardware\tools\avr -tools C:\Users\Administrator\AppData\Local\Arduino15\packages -built-in-libraries C:\Program Files (x86)\Arduino\libraries -libraries C:\Users\Administrator\Documents\Arduino\libraries -fqbn=esp8266:esp8266:nodemcuv2:xtal=80,vt=flash,exception=legacy,ssl=all,eesz=4M2M,led=2,ip=lm2f,dbg=Disabled,lvl=None____,wipe=none,baud=115200 -ide-version=10813 -build-path C:\Users\ADMINI~1\AppData\Local\Temp\arduino_build_450580 -warnings=none -build-cache C:\Users\ADMINI~1\AppData\Local\Temp\arduino_cache_864352 -prefs=build.warn_data_percentage=75 -prefs=runtime.tools.python3.path=C:\Users\Administrator\AppData\Local\Arduino15\packages\esp8266\tools\python3\3.7.2-post1 -prefs=runtime.tools.python3-3.7.2-post1.path=C:\Users\Administrator\AppData\Local\Arduino15\packages\esp8266\tools\python3\3.7.2-post1 -prefs=runtime.tools.mkspiffs.path=C:\Users\Administrator\AppData\Local\Arduino15\packages\esp8266\tools\mkspiffs\2.5.0-4-b40a506 -prefs=runtime.tools.mkspiffs-2.5.0-4-b40a506.path=C:\Users\Administrator\AppData\Local\Arduino15\packages\esp8266\tools\mkspiffs\2.5.0-4-b40a506 -prefs=runtime.tools.mklittlefs.path=C:\Users\Administrator\AppData\Local\Arduino15\packages\esp8266\tools\mklittlefs\2.5.0-4-69bd9e6 -prefs=runtime.tools.mklittlefs-2.5.0-4-69bd9e6.path=C:\Users\Administrator\AppData\Local\Arduino15\packages\esp8266\tools\mklittlefs\2.5.0-4-69bd9e6 -prefs=runtime.tools.xtensa-lx106-elf-gcc.path=C:\Users\Administrator\AppData\Local\Arduino15\packages\esp8266\tools\xtensa-lx106-elf-gcc\2.5.0-4-b40a506 -prefs=runtime.tools.xtensa-lx106-elf-gcc-2.5.0-4-b40a506.path=C:\Users\Administrator\AppData\Local\Arduino15\packages\esp8266\tools\xtensa-lx106-elf-gcc\2.5.0-4-b40a506 -verbose C:\Users\Administrator\Desktop\Blink\02\02.ino

C:\Program Files (x86)\Arduino\arduino-builder -compile -logger=machine -hardware C:\Program Files (x86)\Arduino\hardware -hardware C:\Users\Administrator\AppData\Local\Arduino15\packages -tools C:\Program Files (x86)\Arduino\tools-builder -tools C:\Program Files (x86)\Arduino\hardware\tools\avr -tools C:\Users\Administrator\AppData\Local\Arduino15\packages -built-in-libraries C:\Program Files (x86)\Arduino\libraries -libraries C:\Users\Administrator\Documents\Arduino\libraries -fqbn=esp8266:esp8266:nodemcuv2:xtal=80,vt=flash,exception=legacy,ssl=all,eesz=4M2M,led=2,ip=lm2f,dbg=Disabled,lvl=None____,wipe=none,baud=115200 -ide-version=10813 -build-path C:\Users\ADMINI~1\AppData\Local\Temp\arduino_build_450580 -warnings=none -build-cache C:\Users\ADMINI~1\AppData\Local\Temp\arduino_cache_864352 -prefs=build.warn_data_percentage=75 -prefs=runtime.tools.python3.path=C:\Users\Administrator\AppData\Local\Arduino15\packages\esp8266\tools\python3\3.7.2-post1 -prefs=runtime.tools.python3-3.7.2-post1.path=C:\Users\Administrator\AppData\Local\Arduino15\packages\esp8266\tools\python3\3.7.2-post1 -prefs=runtime.tools.mkspiffs.path=C:\Users\Administrator\AppData\Local\Arduino15\packages\esp8266\tools\mkspiffs\2.5.0-4-b40a506 -prefs=runtime.tools.mkspiffs-2.5.0-4-b40a506.path=C:\Users\Administrator\AppData\Local\Arduino15\packages\esp8266\tools\mkspiffs\2.5.0-4-b40a506 -prefs=runtime.tools.mklittlefs.path=C:\Users\Administrator\AppData\Local\Arduino15\packages\esp8266\tools\mklittlefs\2.5.0-4-69bd9e6 -prefs=runtime.tools.mklittlefs-2.5.0-4-69bd9e6.path=C:\Users\Administrator\AppData\Local\Arduino15\packages\esp8266\tools\mklittlefs\2.5.0-4-69bd9e6 -prefs=runtime.tools.xtensa-lx106-elf-gcc.path=C:\Users\Administrator\AppData\Local\Arduino15\packages\esp8266\tools\xtensa-lx106-elf-gcc\2.5.0-4-b40a506 -prefs=runtime.tools.xtensa-lx106-elf-gcc-2.5.0-4-b40a506.path=C:\Users\Administrator\AppData\Local\Arduino15\packages\esp8266\tools\xtensa-lx106-elf-gcc\2.5.0-4-b40a506 -verbose C:\Users\Administrator\Desktop\Blink\02\02.ino

Using board 'nodemcuv2' from platform in folder: C:\Users\Administrator\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\2.6.3

Using core 'esp8266' from platform in folder: C:\Users\Administrator\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\2.6.3

Detecting libraries used...

"C:\\Users\\Administrator\\AppData\\Local\\Arduino15\\packages\\esp8266\\tools\\xtensa-lx106-elf-gcc\\2.5.0-4-b40a506/bin/xtensa-lx106-elf-g++" -D__ets__ -DICACHE_FLASH -U__STRICT_ANSI__ "-IC:\\Users\\Administrator\\AppData\\Local\\Arduino15\\packages\\esp8266\\hardware\\esp8266\\2.6.3/tools/sdk/include" "-IC:\\Users\\Administrator\\AppData\\Local\\Arduino15\\packages\\esp8266\\hardware\\esp8266\\2.6.3/tools/sdk/lwip2/include" "-IC:\\Users\\Administrator\\AppData\\Local\\Arduino15\\packages\\esp8266\\hardware\\esp8266\\2.6.3/tools/sdk/libc/xtensa-lx106-elf/include" "-IC:\\Users\\ADMINI~1\\AppData\\Local\\Temp\\arduino_build_450580/core" -c -w -Os -g -mlongcalls -mtext-section-literals -fno-rtti -falign-functions=4 -std=gnu++11 -ffunction-sections -fdata-sections -fno-exceptions -w -x c++ -E -CC -DNONOSDK22x_190703=1 -DF_CPU=80000000L -DLWIP_OPEN_SRC -DTCP_MSS=536 -DLWIP_FEATURES=1 -DLWIP_IPV6=0 -DARDUINO=10813 -DARDUINO_ESP8266_NODEMCU -DARDUINO_ARCH_ESP8266 "-DARDUINO_BOARD=\"ESP8266_NODEMCU\"" -DLED_BUILTIN=2 -DFLASHMODE_DIO -DESP8266 "-IC:\\Users\\Administrator\\AppData\\Local\\Arduino15\\packages\\esp8266\\hardware\\esp8266\\2.6.3\\cores\\esp8266" "-IC:\\Users\\Administrator\\AppData\\Local\\Arduino15\\packages\\esp8266\\hardware\\esp8266\\2.6.3\\variants\\nodemcu" "C:\\Users\\ADMINI~1\\AppData\\Local\\Temp\\arduino_build_450580\\sketch\\02.ino.cpp" -o nul -DARDUINO_LIB_DISCOVERY_PHASE

Alternatives for OneButton.h: [OneButton-2.0.4@2.0.4]

ResolveLibrary(OneButton.h)

  -> candidates: [OneButton-2.0.4@2.0.4]

"C:\\Users\\Administrator\\AppData\\Local\\Arduino15\\packages\\esp8266\\tools\\xtensa-lx106-elf-gcc\\2.5.0-4-b40a506/bin/xtensa-lx106-elf-g++" -D__ets__ -DICACHE_FLASH -U__STRICT_ANSI__ "-IC:\\Users\\Administrator\\AppData\\Local\\Arduino15\\packages\\esp8266\\hardware\\esp8266\\2.6.3/tools/sdk/include" "-IC:\\Users\\Administrator\\AppData\\Local\\Arduino15\\packages\\esp8266\\hardware\\esp8266\\2.6.3/tools/sdk/lwip2/include" "-IC:\\Users\\Administrator\\AppData\\Local\\Arduino15\\packages\\esp8266\\hardware\\esp8266\\2.6.3/tools/sdk/libc/xtensa-lx106-elf/include" "-IC:\\Users\\ADMINI~1\\AppData\\Local\\Temp\\arduino_build_450580/core" -c -w -Os -g -mlongcalls -mtext-section-literals -fno-rtti -falign-functions=4 -std=gnu++11 -ffunction-sections -fdata-sections -fno-exceptions -w -x c++ -E -CC -DNONOSDK22x_190703=1 -DF_CPU=80000000L -DLWIP_OPEN_SRC -DTCP_MSS=536 -DLWIP_FEATURES=1 -DLWIP_IPV6=0 -DARDUINO=10813 -DARDUINO_ESP8266_NODEMCU -DARDUINO_ARCH_ESP8266 "-DARDUINO_BOARD=\"ESP8266_NODEMCU\"" -DLED_BUILTIN=2 -DFLASHMODE_DIO -DESP8266 "-IC:\\Users\\Administrator\\AppData\\Local\\Arduino15\\packages\\esp8266\\hardware\\esp8266\\2.6.3\\cores\\esp8266" "-IC:\\Users\\Administrator\\AppData\\Local\\Arduino15\\packages\\esp8266\\hardware\\esp8266\\2.6.3\\variants\\nodemcu" "-IC:\\Users\\Administrator\\Documents\\Arduino\\libraries\\OneButton-2.0.4\\src" "C:\\Users\\ADMINI~1\\AppData\\Local\\Temp\\arduino_build_450580\\sketch\\02.ino.cpp" -o nul -DARDUINO_LIB_DISCOVERY_PHASE

Alternatives for Blinker.h: []02:5:21: fatal error: Blinker.h: No such file or directory



ResolveLibrary(Blinker.h) #include <Blinker.h>



  -> candidates: []                     ^



compilation terminated.

使用 2.0.4  版本的库 OneButton-2.0.4 在文件夹: C:\Users\Administrator\Documents\Arduino\libraries\OneButton-2.0.4

exit status 1

Blinker.h: No such file or directory

发表于 2022-2-13 10:34 | 显示全部楼层
继续关注 并学习中。
发表于 2022-2-13 16:16 | 显示全部楼层
pyq208 发表于 2022-2-13 01:04
Arduino:1.8.13 (Windows 7), 开发板:"NodeMCU 1.0 (ESP-12E Module), 80 MHz, Flash, Legacy (new can  ...

您贴出的这个信息表明,您没有装 blinker lib
 楼主| 发表于 2022-2-13 23:05 | 显示全部楼层
coloz 发表于 2022-2-13 16:16
您贴出的这个信息表明,您没有装 blinker lib

我把库blinker-library-master当成blinker-library-0.3.0.3.80211227 了,改正后通过了。谢谢您!
您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

小黑屋|Archiver|手机版|Arduino中文社区

GMT+8, 2024-11-28 10:37 , Processed in 0.120786 second(s), 18 queries .

Powered by Discuz! X3.4

Copyright © 2001-2021, Tencent Cloud.

快速回复 返回顶部 返回列表