Page 1 of 1

argh error!

Posted: Sun Oct 07, 2012 10:46 am
by reefcycle
so frustrated every time I try to code I get color errors or port not specified but I did the reef angel wizard verbatim. I get so frustrated with this! argh!

Code: Select all

// Autogenerated file by RAGen (v1.2.2.171), (10/07/2012 13:43)
// RA_100712_1343.pde
//
// This version designed for v0.8.5 Beta 17 or later

/* The following features are enabled for this File: 
#define DisplayImages
#define DateTimeSetup
#define VersionMenu
#define DisplayLEDPWM
#define wifi
#define RelayExp
#define InstalledRelayExpansionModules 0
#define WDT
#define SIMPLE_MENU
#define RFEXPANSION
#define IOEXPANSION
*/


#include <ReefAngel_Features.h>
#include <ReefAngel_Globals.h>
#include <ReefAngel_Wifi.h>
#include <Wire.h>
#include <OneWire.h>
#include <Time.h>
#include <DS1307RTC.h>
#include <ReefAngel_EEPROM.h>
#include <ReefAngel_NokiaLCD.h>
#include <ReefAngel_ATO.h>
#include <ReefAngel_Joystick.h>
#include <ReefAngel_LED.h>
#include <ReefAngel_TempSensor.h>
#include <ReefAngel_Relay.h>
#include <ReefAngel_PWM.h>
#include <ReefAngel_Timer.h>
#include <ReefAngel_Memory.h>
#include <ReefAngel_RF.h>
#include <ReefAngel.h>

////// Place global variable code below here


////// Place global variable code above here


void setup()
{
    // This must be the first line
    ReefAngel.Init();  //Initialize controller

    // Ports toggled in Feeding Mode
    ReefAngel.FeedingModePorts = B00000000;
    // Ports toggled in Water Change Mode
    ReefAngel.WaterChangePorts = B11000101;
    // Ports turned off when Overheat temperature exceeded
    ReefAngel.OverheatShutoffPorts = B00001100;
    ////// Place additional initialization code below here
    

    ////// Place additional initialization code above here
}

void loop()
{
    // Specific functions that use Internal Memory values
    ReefAngel.StandardLights(Port1);
    ReefAngel.MHLights(Port2);
    ReefAngel.StandardHeater(Port3);
    ReefAngel.StandardFan(Port4);
    ReefAngel.DosingPump1(Port7);
    ReefAngel.DosingPump2(Port8);
    ////// Place your custom code below here
    

    ////// Place your custom code above here
    // This sends all the data to the portal
    // Do not add any custom code that changes any relay status after this line
    // The only code after this line should be the ShowInterface function
    ReefAngel.Portal("reefcycle", "*******");

    // This should always be the last line
    ReefAngel.ShowInterface();
}
I just want port 1 standard port 2 mh port 3 heater port 4 mh port 5 and port 6 not dedicated port 7 dosing pump 1 port 8 dosing pump 2. I have rf expansion water level and i/o hub. I have wifi and thats already working. I just want it all to work. I can sucessfully upload preload code or initial settings but I am doing something simple wrong and it is causing chaos!

Re: argh error!

Posted: Sun Oct 07, 2012 10:53 am
by rimai
Seems you are using headers from old RAGen and code from Wizard.
The headers have changed, so the includes in your code are outdated.
Make sure you use the same headers that Wizard is outputting.

Re: argh error!

Posted: Sun Oct 07, 2012 11:02 am
by reefcycle
Where are those options?

Re: argh error!

Posted: Sun Oct 07, 2012 11:05 am
by rimai
There are no options. Just use the code from Wizard as is.
You don't need to copy and paste the code. Why are you copying and pasting code from wizard to an old code?

Code: Select all

#include <ReefAngel_Features.h>
#include <ReefAngel_Globals.h>
#include <ReefAngel_Wifi.h>
#include <Wire.h>
#include <OneWire.h>
#include <Time.h>
#include <DS1307RTC.h>
#include <ReefAngel_EEPROM.h>
#include <ReefAngel_NokiaLCD.h>
#include <ReefAngel_ATO.h>
#include <ReefAngel_Joystick.h>
#include <ReefAngel_LED.h>
#include <ReefAngel_TempSensor.h>
#include <ReefAngel_Relay.h>
#include <ReefAngel_PWM.h>
#include <ReefAngel_Timer.h>
#include <ReefAngel_Memory.h>
#include <ReefAngel_RF.h>
#include <ReefAngel.h>
These libraries belong to a really old library set that is outdated and no longer works or is supported. You should not use it anymore.

Re: argh error!

Posted: Sun Oct 07, 2012 11:09 am
by reefcycle
I started from fresh since I was able to use my desktop since I purchased USB power cable. So I downloaded all new. I am so confused lol

Re: argh error!

Posted: Sun Oct 07, 2012 11:25 am
by rimai
The code you posted says this on top

Code: Select all

// Autogenerated file by RAGen (v1.2.2.171), (10/07/2012 13:43)
// RA_100712_1343.pde
//
That tells me that you generated this code from RAGen and not Wizard.

Re: argh error!

Posted: Sun Oct 07, 2012 11:27 am
by reefcycle
I don't know how. I am not denying it happened im just at a loss for how. Should I uninstall and try again

Re: argh error!

Posted: Sun Oct 07, 2012 11:28 am
by rimai
Can you go through the wizard again and choose "Generate Only" at the end.
Then paste the code here once again.
Just to be sure. You are using Wizard by using menu Tools->Reef Angel Wizard, right?

Re: argh error!

Posted: Sun Oct 07, 2012 11:36 am
by reefcycle
it has it on top again this is from wizard

Code: Select all

// Autogenerated file by RAGen (v1.2.2.171), (10/07/2012 14:34)
// RA_100712_1434.pde
//
// This version designed for v0.8.5 Beta 17 or later

/* The following features are enabled for this File: 
#define DisplayImages
#define DateTimeSetup
#define VersionMenu
#define DisplayLEDPWM
#define wifi
#define RelayExp
#define InstalledRelayExpansionModules 0
#define WDT
#define SIMPLE_MENU
#define RFEXPANSION
#define IOEXPANSION
*/


#include <ReefAngel_Features.h>
#include <ReefAngel_Globals.h>
#include <ReefAngel_Wifi.h>
#include <Wire.h>
#include <OneWire.h>
#include <Time.h>
#include <DS1307RTC.h>
#include <ReefAngel_EEPROM.h>
#include <ReefAngel_NokiaLCD.h>
#include <ReefAngel_ATO.h>
#include <ReefAngel_Joystick.h>
#include <ReefAngel_LED.h>
#include <ReefAngel_TempSensor.h>
#include <ReefAngel_Relay.h>
#include <ReefAngel_PWM.h>
#include <ReefAngel_Timer.h>
#include <ReefAngel_Memory.h>
#include <ReefAngel_RF.h>
#include <ReefAngel.h>

////// Place global variable code below here


////// Place global variable code above here


void setup()
{
    // This must be the first line
    ReefAngel.Init();  //Initialize controller

    ////// Place additional initialization code below here
    

    ////// Place additional initialization code above here
}

void loop()
{
    // Specific functions that use Internal Memory values
    ReefAngel.StandardLights(Port1);
    ReefAngel.MHLights(Port2);
    ReefAngel.StandardHeater(Port3);
    ReefAngel.StandardFan(Port4);
    ReefAngel.DosingPump1(Port7);
    ReefAngel.DosingPump2(Port8);
    ////// Place your custom code below here
    

    ////// Place your custom code above here
    // This sends all the data to the portal
    // Do not add any custom code that changes any relay status after this line
    // The only code after this line should be the ShowInterface function
    ReefAngel.Portal("reefcycle", "zzxx4118");

    // This should always be the last line
    ReefAngel.ShowInterface();
}

Re: argh error!

Posted: Sun Oct 07, 2012 11:41 am
by rimai
rimai wrote: Just to be sure. You are using Wizard by using menu Tools->Reef Angel Wizard, right?
RAGen is not the same as Wizard.
I'm pretty sure you are using RAGen.

Re: argh error!

Posted: Sun Oct 07, 2012 11:45 am
by reefcycle
Wizard created it, and then it launches arduino

Re: argh error!

Posted: Sun Oct 07, 2012 11:47 am
by rimai
That's what I mean.
You are not using Wizard. You are using RAGen, which is deprecated.
http://forum.reefangel.com/viewtopic.php?f=8&t=1297
Open Arduino and go to menu Tools->Reef Angel Wizard

Re: argh error!

Posted: Sun Oct 07, 2012 11:58 am
by reefcycle
wow I didnt even know that was there I am an idiot