8266编译不过如果可以解决发红包-Arduino中文社区 - Powered by Discuz!

Arduino中文社区

 找回密码
 立即注册

QQ登录

只需一步,快速开始

查看: 3661|回复: 7

8266编译不过如果可以解决发红包

[复制链接]
发表于 2019-1-7 19:31 | 显示全部楼层 |阅读模式










C:\Users\xuansir\Documents\Arduino\sketch_jan07f\sketch_jan07f.ino: In function 'void button1_callback(const String&)':


sketch_jan07f:38:18: error: 'D3' was not declared in this scope


     digitalWrite(D3, HIGH);


                  ^


sketch_jan07f:43:18: error: 'D3' was not declared in this scope


     digitalWrite(D3, LOW);


                  ^


C:\Users\xuansir\Documents\Arduino\sketch_jan07f\sketch_jan07f.ino: In function 'void setup()':


sketch_jan07f:50:13: error: 'D3' was not declared in this scope


     pinMode(D3, OUTPUT);


             ^


sketch_jan07f:54:29: error: no matching function for call to 'BlinkerESPMQTT::begin(char [11], char [11])'


     Blinker.begin(ssid, pswd);


                             ^


C:\Users\xuansir\Documents\Arduino\sketch_jan07f\sketch_jan07f.ino:54:29: note: candidates are:


In file included from C:\Users\xuansir\Documents\Arduino\libraries\Blinker\src/Blinker.h:149:0,


                 from C:\Users\xuansir\Documents\Arduino\sketch_jan07f\sketch_jan07f.ino:23:


C:\Users\xuansir\Documents\Arduino\libraries\Blinker\src/BlinkerESPMQTT.h:34:14: note: void BlinkerESPMQTT::begin(const char*)


         void begin(const char* _auth)


              ^


C:\Users\xuansir\Documents\Arduino\libraries\Blinker\src/BlinkerESPMQTT.h:34:14: note:   candidate expects 1 argument, 2 provided


C:\Users\xuansir\Documents\Arduino\libraries\Blinker\src/BlinkerESPMQTT.h:63:14: note: void BlinkerESPMQTT::begin(const char*, const char*, const char*)


         void begin( const char* _auth,


              ^


C:\Users\xuansir\Documents\Arduino\libraries\Blinker\src/BlinkerESPMQTT.h:63:14: note:   candidate expects 3 arguments, 2 provided


C:\Users\xuansir\Documents\Arduino\sketch_jan07f\sketch_jan07f.ino: In function 'void loop()':


sketch_jan07f:63:56: error: 'class BlinkerESPMQTT' has no member named 'readString'


         BLINKER_LOG2("Blinker.readString(): ", Blinker.readString());


                                                        ^


sketch_jan07f:63:68: error: 'BLINKER_LOG2' was not declared in this scope


         BLINKER_LOG2("Blinker.readString(): ", Blinker.readString());


                                                                    ^


exit status 1
'D3' was not declared in this scope


C:\Users\xuansir\Documents\Arduino\sketch_jan07f\sketch_jan07f.ino: In function 'void button1_callback(const String&)':


sketch_jan07f:38:18: error: 'D3' was not declared in this scope


     digitalWrite(D3, HIGH);


                  ^


sketch_jan07f:43:18: error: 'D3' was not declared in this scope


     digitalWrite(D3, LOW);


                  ^


C:\Users\xuansir\Documents\Arduino\sketch_jan07f\sketch_jan07f.ino: In function 'void setup()':


sketch_jan07f:50:13: error: 'D3' was not declared in this scope


     pinMode(D3, OUTPUT);


             ^


sketch_jan07f:54:29: error: no matching function for call to 'BlinkerESPMQTT::begin(char [11], char [11])'


     Blinker.begin(ssid, pswd);


                             ^


C:\Users\xuansir\Documents\Arduino\sketch_jan07f\sketch_jan07f.ino:54:29: note: candidates are:


In file included from C:\Users\xuansir\Documents\Arduino\libraries\Blinker\src/Blinker.h:149:0,


                 from C:\Users\xuansir\Documents\Arduino\sketch_jan07f\sketch_jan07f.ino:23:


C:\Users\xuansir\Documents\Arduino\libraries\Blinker\src/BlinkerESPMQTT.h:34:14: note: void BlinkerESPMQTT::begin(const char*)


         void begin(const char* _auth)


              ^


C:\Users\xuansir\Documents\Arduino\libraries\Blinker\src/BlinkerESPMQTT.h:34:14: note:   candidate expects 1 argument, 2 provided


C:\Users\xuansir\Documents\Arduino\libraries\Blinker\src/BlinkerESPMQTT.h:63:14: note: void BlinkerESPMQTT::begin(const char*, const char*, const char*)


         void begin( const char* _auth,


              ^


C:\Users\xuansir\Documents\Arduino\libraries\Blinker\src/BlinkerESPMQTT.h:63:14: note:   candidate expects 3 arguments, 2 provided


C:\Users\xuansir\Documents\Arduino\sketch_jan07f\sketch_jan07f.ino: In function 'void loop()':


sketch_jan07f:63:56: error: 'class BlinkerESPMQTT' has no member named 'readString'


         BLINKER_LOG2("Blinker.readString(): ", Blinker.readString());


                                                        ^


sketch_jan07f:63:68: error: 'BLINKER_LOG2' was not declared in this scope


         BLINKER_LOG2("Blinker.readString(): ", Blinker.readString());


                                                                    ^


exit status 1
'D3' was not declared in this scope

发表于 2019-1-7 19:44 | 显示全部楼层
你这个板子没有D3,或者你选的开发板没有D3,看看啥板子,上面印的啥,直接写上面印的数字即可
 楼主| 发表于 2019-1-7 19:53 | 显示全部楼层
开发板可以看图

微信图片_20190107195200.jpg
 楼主| 发表于 2019-1-7 19:54 | 显示全部楼层
coloz 发表于 2019-1-7 19:44
你这个板子没有D3,或者你选的开发板没有D3,看看啥板子,上面印的啥,直接写上面印的数字即可 ...

这开发版有D3口
发表于 2019-1-7 20:20 | 显示全部楼层
heysir 发表于 2019-1-7 19:54
这开发版有D3口

写得有不代表你ide选的板子定义的有
发表于 2019-1-8 09:02 | 显示全部楼层
还没有解决吗?    怀疑你的编译板子选错了;参考我的:
微信截图_20190108090042.png
发表于 2019-1-8 13:27 | 显示全部楼层
肯定是没选板子类型的,选Generic ESP8266 Module 再编译就可以了。
发表于 2019-1-16 09:36 | 显示全部楼层
D3,你应该填写0
您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

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

GMT+8, 2024-11-28 15:56 , Processed in 0.082472 second(s), 18 queries .

Powered by Discuz! X3.4

Copyright © 2001-2021, Tencent Cloud.

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