zczcyc0201 / CrabPixelClock

蟹蟹你像素时钟
9 stars 3 forks source link

Compile Failed #1

Open achenakid opened 3 years ago

achenakid commented 3 years ago

你好,我在编译的时候报如下错误,可以指导下怎么解决吗? In file included from sketch\FuncDHT11.cpp:1:0:

FuncDHT11.h:9:17: error: 'D1' was not declared in this scope

 DHT dht=DHT(D1, DHT11);

             ^

In file included from sketch\DisplayManager.h:3:0,

             from sketch\DisplayManager.cpp:1:

FuncDHT11.h:9:17: error: 'D1' was not declared in this scope

 DHT dht=DHT(D1, DHT11);

             ^

In file included from sketch\DisplayManager.h:3:0,

             from D:\CrabPixelClock\CrabPixelClock.ino:1:

FuncDHT11.h:9:17: error: 'D1' was not declared in this scope

 DHT dht=DHT(D1, DHT11);

             ^

exit status 1 CrabPixelClock:15:24: error: 'D2' was not declared in this scope

define PIN_RTC_CE_RST D2 //DS1302 PIN

                    ^

D:\CrabPixelClock\CrabPixelClock.ino:33:12: note: in expansion of macro 'PIN_RTC_CE_RST'

DS1302 rtc(PIN_RTC_CE_RST, PIN_RTC_DAT_IO, PIN_RTC_CLK);

        ^

CrabPixelClock:16:24: error: 'D3' was not declared in this scope

define PIN_RTC_DAT_IO D3 //DS1302 PIN

                    ^

D:\CrabPixelClock\CrabPixelClock.ino:33:28: note: in expansion of macro 'PIN_RTC_DAT_IO'

DS1302 rtc(PIN_RTC_CE_RST, PIN_RTC_DAT_IO, PIN_RTC_CLK);

                        ^

CrabPixelClock:17:21: error: 'D4' was not declared in this scope

define PIN_RTC_CLK D4 //DS1302 PIN

                 ^

D:\CrabPixelClock\CrabPixelClock.ino:33:44: note: in expansion of macro 'PIN_RTC_CLK'

DS1302 rtc(PIN_RTC_CE_RST, PIN_RTC_DAT_IO, PIN_RTC_CLK);

                                        ^

CrabPixelClock:14:17: error: 'D5' was not declared in this scope

define PIN_LED D5 //定义LED数据使用的PIN

             ^

D:\CrabPixelClock\CrabPixelClock.ino:44:65: note: in expansion of macro 'PIN_LED'

FuncNeoPixelMatrix funcMatrix = FuncNeoPixelMatrix(32, 8, 1, 1, PIN_LED,

                                                             ^

CrabPixelClock:18:20: error: 'D8' was not declared in this scope

define BUTTON_PIN D8 //按钮的gpio接口

                ^

D:\CrabPixelClock\CrabPixelClock.ino:60:30: note: in expansion of macro 'BUTTON_PIN'

OneButton oneBtn = OneButton(BUTTON_PIN, true, true);

                          ^

'D1' was not declared in this scope

zhaoyongqiangqiang commented 2 years ago

我也有这个问题解决了吗??

zhaoyongqiangqiang commented 2 years ago

D:\onedrive\桌面\CrabPixelClock\FuncHttpReq.cpp: In member function 'String FuncHttpReq::getRequest(String, uint8)': FuncHttpReq.cpp:39:18: error: call to 'HTTPClient::begin' declared with attribute error: obsolete API, use ::begin(WiFiClient, url) exit status 1 call to 'HTTPClient::begin' declared with attribute error: obsolete API, use ::begin(WiFiClient, url)

这个报错是我哪里做错了吗??

zhaoyongqiangqiang commented 2 years ago

@zczcyc0201