ReefAngel_Features.h

Do you have a question on how to do something.
Ask in here.
Post Reply
thekameleon
Posts: 137
Joined: Sat Feb 16, 2013 7:44 am

ReefAngel_Features.h

Post by thekameleon »

I may be asking a silly question here, but when I try to add #define StandardLightSetup so it shows up in my menu into the ReefAngel_Features.h file under my libraries directly. Everytime I try to upload it, it seems that it gets overwritten every time. Why is this happening and how can I stop it?
rimai
Posts: 12857
Joined: Fri Mar 18, 2011 6:47 pm

Re: ReefAngel_Features.h

Post by rimai »

You can't.
It's a feature that I placed in the Arduino IDE to makes things easier to everyone.
The Arduino IDE does that everytime you compile or upload a code based on keywords it finds in the code itself.
The list of keywords along with the defines it will automatically add to ReefAngel.h is located inside the file features.txt.
"Document\Arduino\update" folder.
You can add this to your code:

Code: Select all

ReefAngel.AddStandardMenu();
This will trigger the standard menu to be used instead of the simple menu.
In the past, we had lots of confusion because we had to manually add things to ReefAngel.h file and was very confusing for users to understand and compile codes.
Ever since I created this auto features detection capability, we've had zero problems with compiling codes due to missing defines :)
Roberto.
thekameleon
Posts: 137
Joined: Sat Feb 16, 2013 7:44 am

Re: ReefAngel_Features.h

Post by thekameleon »

So it automatically creates the Features.h file based on code in the you but in the ino by matching strings... That is pretty awesome. So if I add a new library I should edit the keywords.txt file correct?

Reason, I ask is cause I am really confused how this works... I expected to see AddStandardMenu in the keywords.txt file, so the mapping could occur and it is not there? It did work though, so is it hard coded or am I missing something?
rimai
Posts: 12857
Joined: Fri Mar 18, 2011 6:47 pm

Re: ReefAngel_Features.h

Post by rimai »

not keyword.txt...
features.txt inside folder "Document\Arduino\update"
Roberto.
thekameleon
Posts: 137
Joined: Sat Feb 16, 2013 7:44 am

Re: ReefAngel_Features.h

Post by thekameleon »

So yes that is what I meant
Post Reply