Arduino error : TKD2 was not declared in this scop

2019-09-10 16:43发布

i am a beginner in arduino and that's my first IR project and yet i have a problem with compiling ...

Arduino error : TKD2 was not declared in this scope

About the code i used is the example IRrecvDemo .

4条回答
做个烂人
2楼-- · 2019-09-10 16:59

I've just bought an arduino beginner pack (sunfounder) and I had the same issue. What I did is:

查看更多
▲ chillily
3楼-- · 2019-09-10 17:09

just delete RobotIRremote file in the libraries and download the IRremote-master againly copy paste into the libraries file

查看更多
Luminary・发光体
4楼-- · 2019-09-10 17:10

Most like you have already googled the answer or given up. Well, hoping for the first option, I have not seen into this in detail but I found two workarounds.

Seems to me that the Robot IR Remote library has an issue there.

You can either remove the files IRremoteTools.cpp and IRremoteTools.h from your directory C:/programs/arduino/libraries/Robot_IR_Remote/src/ (or the approriate path for your OS) or go to

https://github.com/z3t0/Arduino-IRremote

and get yourself an IR remote library that is working as it is.

Seems to me the numeric values to a given IR signal vary between both libraries. But then again I did not go into any details there. Perhaps someone else can elaborate on that point.

Good luck.

查看更多
等我变得足够好
5楼-- · 2019-09-10 17:17

On the Mac I used the Terminal application and did a "cd /Applications/Arduino.app" followed by an "open .". That opened up the Finder inside the Arduino application. I then navigated to the contents/Java/libraries and removed the RobotIRRemote folder. I then went to main Arduino/Sketch/Include Library.../Manage Libraries and did a search for the IRRemote library. After I imported that the libraries complied without any problem!

查看更多
登录 后发表回答