Skip to content

Error in arduino debug with two files #4468

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

Closed
ManuelGonzalezR opened this issue Jan 22, 2016 · 4 comments
Closed

Error in arduino debug with two files #4468

ManuelGonzalezR opened this issue Jan 22, 2016 · 4 comments
Labels
Type: Duplicate Another item already exists for this topic
Milestone

Comments

@ManuelGonzalezR
Copy link

I have discovered and interesting error in the debug of arduino, it is when there is two related files in arduino IDE, and you are compiling, the error can be from the two files but arduino IDE don´t say the file where it is origined only say what line is.

I hope it can be usefull for you. Best Regards.

@per1234
Copy link
Collaborator

per1234 commented Jan 22, 2016

Would you mind providing a simple example of files that cause this issue and the error please.

@ManuelGonzalezR
Copy link
Author

ARDUINO1.zip

This is the example file, the principal file is Arduino 1, and there is a second file related to it called Arduino2. The Arduino 1 has an error and when you compile it, the debugger send you to the Arduino 2, but with the line of the Arduino 1.

@per1234
Copy link
Collaborator

per1234 commented Jan 22, 2016

Thanks, I reported this issue at arduino/arduino-builder#99 a few days ago. Until the bug is fixed the workaround is to either manually declare the function prototypes for any function defined after the first tab, so you would change ARDUINO1.ino to:

void hola();  //function prototype for hola()
void setup() {
  // put your setup code here, to run once:
Serial.begin(9600);
Serial.println("Hello world");

}

void loop() {
  // put your main code here, to run repeatedly:

  //Here I am going to put and error.
a=3;
}

or you can use Arduino IDE 1.6.6 which doesn't have this bug. Neither are very good options I know, hopefully the developers will fix this serious issue soon.

@ManuelGonzalezR
Copy link
Author

Ok... Many thanks for your answer.

@matthijskooijman matthijskooijman added the Type: Duplicate Another item already exists for this topic label Jan 25, 2016
@agdl agdl added this to the Release 1.6.8 milestone Jan 26, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Type: Duplicate Another item already exists for this topic
Projects
None yet
Development

No branches or pull requests

4 participants