I tried to upload the new ArduCopter 2.5.5 firmware in order to test whether or not everything was in order, and I get a specific compile error. I am using the patched version of Arduino (the "relax" patch), I set up the sketchbook and board settings as to the best of my knowledge, and I have not altered anything. I am uploading the code to an APM 1 setup, and I am running Arduino in Administrator mode, as that "fixed" another error I was receiving before.
I am attaching the screen I get after I try to verify or compile the code. A compass is being used on the drone, so I'm not sure how safe it would be to start commenting out parts of the code without having bad repercussions.
Any ideas as to what I should do?
Why dont you upload it using mission planner?
Because I will be modifying the code, and I wanted to confirm that I could upload it through Arduino. I've uploaded the software to the Arduino before through the mission planner, but I want to see if I can upload it this way.
O.K have you checked your libraries are in the correct folders, and the preferences set in Arduino ide to find them?
That is probably the problem? I will explain further if necessary?
I set the sketchbook location to the folder on the desktop containing my two folders "Arducopter" and "libraries". I literally took the Arducopter 2.5.5 .zip folder from the downloads, unzipped it, and then made that unzipped folder my sketchbook location.
Could it be remotely possible that there is a problem with the "null_offset" function? I noticed that it's defined in the code as requiring a void input, but the line in the error message mentions an input there in the parentheses.
Forgive me if I seem a little new at this, programming is not exactly my strength, but I did make sure that I followed the instructions as closely as possible, and I am still getting issues. On monday I'm going to see if I can validate a compile of the 2.5.3 version, as that was the last version before some changes that I think might be tripping me up.
The code in your picture is not 2.5.5 as it does not have the option of retro loiter in that section of the code? unless you have removed it?
I think I may know what the problem might be? If you have set your sketchbook location correctly in the preferences, that is a good start, so have you tried opening the file directly? in arduino ide go to file - open then browse for the file arducopter.pde in the 2.5.5 folder you have unzipped to your desktop. Open that and then it should load the correct firmware and the libraries will be understood.
This code IS version 2.5.5 for Arducopter. I didn't remove or change anything, just tried to do a straight up compile in Arduino. I can quite assure you it's 2.5.5. Not trying to sound mean, but I am absolutely positive of this.
The method you just described is how I opened the file in the first place. I might have designated the sketchbook location after I opened the file, but I don't think that could cause the problem, could it?
This is from 2.5.5 where the option for using retro loiter was included in the coding? So unless my 2.5.5 is different to yours? i.e the coding may have changed? and retro loiter is placed elsewhere in your version? its worth looking at, if you search the pde for "retro" it mat show up somewhere else?
When you open Arduino the libraries are loaded from the sketchbook location, so if you change the location in the preferences, you must then close Arduino and then reload in order for that change to take effect.
I'll take a look and see where this snippet of code is soon. The part in my picture shows up in the medium loop (50 Hz), perhaps there is just some confusion as to where we are looking?
Alright, so that probably is just the problem, I did it backwards. I didn't know that that would cause a problem. The more you know, I guess. Thanks, I'll try to post in here any updates if I have any further issues.
I set up the sketchbook preferences in the right order, and that solved the problem with the compiling. Thanks for the reminder.