|
本帖最后由 85968011 于 2022-3-29 10:23 编辑
C:\Users\Administrator\Desktop\NodeMCU_Blinker_DHT22_rtData\NodeMCU_Blinker_DHT22_rtData.ino: In function 'void rtData()':
NodeMCU_Blinker_DHT22_rtData:48:13: error: 'class BlinkerESPMQTT' has no member named 'sendRtData'; did you mean 'textData'?
48 | Blinker.sendRtData("temp", dht22_temp);
| ^~~~~~~~~~
| textData
NodeMCU_Blinker_DHT22_rtData:49:13: error: 'class BlinkerESPMQTT' has no member named 'sendRtData'; did you mean 'textData'?
49 | Blinker.sendRtData("humi", dht22_humidity);
| ^~~~~~~~~~
| textData
NodeMCU_Blinker_DHT22_rtData:50:13: error: 'class BlinkerESPMQTT' has no member named 'printRtData'
50 | Blinker.printRtData();
| ^~~~~~~~~~~
C:\Users\Administrator\Desktop\NodeMCU_Blinker_DHT22_rtData\NodeMCU_Blinker_DHT22_rtData.ino: In function 'void setup()':
NodeMCU_Blinker_DHT22_rtData:89:30: error: no matching function for call to 'BlinkerESPMQTT::attachRTData(void (&)())'
89 | Blinker.attachRTData(rtData);
| ^
In file included from C:\Users\Administrator\Documents\Arduino\libraries\Blinker\src/BlinkerESPMQTT.h:17,
from C:\Users\Administrator\Documents\Arduino\libraries\Blinker\src/Blinker.h:38,
from C:\Users\Administrator\Desktop\NodeMCU_Blinker_DHT22_rtData\NodeMCU_Blinker_DHT22_rtData.ino:9:
C:\Users\Administrator\Documents\Arduino\libraries\Blinker\src/Blinker/BlinkerApi.h:502:18: note: candidate: 'void BlinkerApi::attachRTData(char*, blinker_callback_t)'
502 | void attachRTData(char _name[], blinker_callback_t newFunction)
| ^~~~~~~~~~~~
C:\Users\Administrator\Documents\Arduino\libraries\Blinker\src/Blinker/BlinkerApi.h:502:18: note: candidate expects 2 arguments, 1 provided
"Blinker.h" 对应多个库
已使用: C:\Users\Administrator\Documents\Arduino\libraries\Blinker
未使用:C:\Users\Administrator\Documents\Arduino\libraries\blinker-library-dev_3.0
exit status 1
'class BlinkerESPMQTT' has no member named 'sendRtData'; did you mean 'textData'?
使用库的初衷是节省重复操作的精力,一会用这个库,一会增加功能需要再添加另外一个库,搞来搞去都是错误,要浪费更多的精力去排错,我看好多帖子都是库文件版本问题和冲突;
|
|