New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
'TKD2' was not declared in this scope #98
Comments
I had the same issue! There is a conflict with the new(?) RobotIRremote-Library of Arduino IDE 1.0.6. |
Yes, this is a known issue and we've submitted a patch to the Arduino project but haven't heard back yet on it. I'm going to close this one because its already covered by #91 |
I see, cool. Since you guys probably know about IR receivers, I want to ask a question real quick: (I'm trying to debug if my receiver even works.) |
You can't just measure it cause there is a digital signal coming from the receiver. Have a look at the datasheet of your IR receiver. For example here at page 3 and 4: http://www.vishay.com/docs/82459/tsop48.pdf Be sure to hook it up correctly according to your specific IR receiver. |
This issue is caused by someone changing the stock library to suit the RS Components robot board on which the pins are called TK whatever so TKD2 is a pin on that robot board . Now this interferes with the examples and the library must be deleted and replaced for it to compile properly. Arduino 1.5.8 wrongly includes this adulterated library as RobotIRRemote. It needs to be replaced with the original correct IRRemote library in the next releases |
Hai, Just rename your Folder library... Like this From "IR" to "IRremote" |
Yes, it's out of our hands unless we rename the whole library, which I'd prefer not to do. |
did you try restarting the IDE? |
Yes I've did it sir |
I've downloaded the arduino IR remote master from this website..but my error when RobotIRremote out of the Arduino-libraries folder it shows the error. C:\Program Files\Arduino\examples\Arduino-IRremote-master\examples\IRrecvDemo\IRrecvDemo.ino:9:22: fatal error: IRremote.h: No such file or directory |
Please copy it to arduino/libraries not examples in your documents directory |
A simple solution... open IRremoteTools.cpp which is in "C:\Program Files\Arduino\libraries\RobotIRremote\src" and replace TKD2 with any number. I put 1. now try arduino code.. it works like a charm!!!! if you use "results" variable in your code there you may get a "(.text+0x0): multiple definition of `results'" error. change your variable to "results1"... ;) |
@ramnath555 A better solution is to remove RobotIRremote altogether |
Removing "RobotIRremote" will give "'IRremote.h' not found" - :) . It you use older IRLib.h then most of the remotes will give 0 value for all keys |
You should not be using robotics irremote along with this library. They conflict |
@z3t0 : So, I've read the multiple issues on this over the last 2 years. Of course, there seems to be no way to force the IDE to use my local libraries over its own, and it still ignores include "foo." vs include <foo.h> it seems when it could have used it as a hint/workaround. So, is there really no long term fix to this? Everyone must delete libraries/RobotIRremote forever on every copy of the arduino IDE they ever install? |
@marcmerlin You have made a really good point that honestly I have never considered! I very rarely update Arduino and I don't even recall if I needed to delete RobotIRremote the last time. But considering what you have said I will certainly find a way to fix this. If I recall, the issue was that RobotIRremote was initially a fork of this library (or something like that) and so there are symbols that are duplicates in both instances. I will go ahead and prioritize this as a new issue |
It took me about an hour, but I finally figured out a solution. 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! I did try several other suggestions mentioned above. However, each of them failed. For other instructors we will include this fix in the CoderDojo robot book. |
[SOLVED] P.S: I renamed it into IRremote (without "-master") |
I have the same problem and until now I can't solve it my project is stopped because the IR |
|
I have encountered the same problem. corrected and successful |
Seems to be fixed in the latest IDE |
The text was updated successfully, but these errors were encountered: