Hi. I want to use the ATO as a regular. This means that I want the ATO pump to activate when the low switch is down and shut down when the low switch is up. I would like to allow the second switch (upper switch) to act as a back-up (always on until the excess water moves it up and shuts it down).
Can someone help me with this code?
thanks!
Regular ATO function
Re: Regular ATO function
Try this:
Code: Select all
if (ReefAngel.HighATO.IsActive()) ReefAngel.SingleATOLow(Port1); else ReefAngel.Relay.Off(Port1);
Roberto.
Re: Regular ATO function
The key is connecting the high and low switches to the correct port on the RA, this info can be found in the manual
Re: Regular ATO function
Thanks. I tried to do this but now I get "sketch too big" when it is very short. I copied the whole sketch below, maybe someone can help me:
Code: Select all
/* The following features are enabled for this File:
#define DisplayImages
#define DateTimeSetup
#define VersionMenu
#define wifi
#define SIMPLE_MENU
#define ENABLE_ATO_LOGGING
*/
#include <ReefAngel_Features.h>
#include <Globals.h>
#include <RA_Wifi.h>
#include <Wire.h>
#include <OneWire.h>
#include <Time.h>
#include <DS1307RTC.h>
#include <InternalEEPROM.h>
#include <RA_NokiaLCD.h>
#include <RA_ATO.h>
#include <RA_Joystick.h>
#include <LED.h>
#include <RA_TempSensor.h>
#include <Relay.h>
#include <RA_PWM.h>
#include <Timer.h>
#include <Memory.h>
#include <ReefAngel.h>
prog_char id_label[] PROGMEM = "Lito";
prog_char probe1_label[] PROGMEM = "Sump";
prog_char probe2_label[] PROGMEM = "Refugium";
prog_char probe3_label[] PROGMEM = "Room";
prog_char relay1_label[] PROGMEM = "Actinic";
prog_char relay2_label[] PROGMEM = "Main%20Lights";
prog_char relay3_label[] PROGMEM = "Light%20Fans";
prog_char relay4_label[] PROGMEM = "Sump%20Lights";
prog_char relay5_label[] PROGMEM = "ATO";
prog_char relay6_label[] PROGMEM = "Heater";
prog_char relay7_label[] PROGMEM = "Skimmer";
prog_char relay8_label[] PROGMEM = "Return%20Pump";
PROGMEM const char *webbanner_items[] = {
id_label, probe1_label, probe2_label, probe3_label, relay1_label, relay2_label,
relay3_label, relay4_label, relay5_label, relay6_label, relay7_label, relay8_label};
void setup()
{
ReefAngel.Init(); //Initialize controller
// Ports that are always on
ReefAngel.Relay.On(Port8); // Return pump
ReefAngel.Relay.On(Port7); //Skimmer
CheckWifi();
}
void loop()
{
// Specific functions that use Internal Memory values
ReefAngel.StandardLights(Port1,10,0,22,30); //Actinic lights
ReefAngel.StandardLights(Port2,11,30,20,30); //Main lights
ReefAngel.StandardLights(Port3,10,30,21,0); //Lights fan
ReefAngel.StandardLights(Port4,18,0,11,0); //Sump Lights
ReefAngel.StandardHeater(Port6,788,79.2);
if (ReefAngel.HighATO.IsActive())
{
ReefAngel.SingleATOLow(Port1);
}
else
{
ReefAngel.Relay.Off(Port1);
}
ReefAngel.Portal("lucho");
ReefAngel.ShowInterface();
}