HELP Dosing function use as a food timer on port 2

Requests for new functions or software apps
User avatar
Posts: 31
Joined: Fri May 04, 2012 10:13 am
PostPosted: Fri Jan 05, 2018 5:22 am
I think there must be another way. If I can have someone help me write a code to kill the power of port 2 for 5 sec only every time it reboot. This should work perfect. I dont want to risk having another device and later find out it starts to be unstable and end up almost crashing my tank. The best is kill the power for 5 sec after reboot. I hope someone can help me hack the system. Im sure this can be done. Only on 1 port not all the ports.

Posts: 12200
Joined: Fri Mar 18, 2011 6:47 pm
PostPosted: Fri Jan 05, 2018 10:13 am
Try this:
Code: Select all
ReefAngel.DosingPumpRepeat( Box1_Port2,0,180,2 );
if (millis()<60000) ReefAngel.Relay.Off( Box1_Port2 );
Roberto.
User avatar
Posts: 31
Joined: Fri May 04, 2012 10:13 am
PostPosted: Sat Jan 06, 2018 8:26 am
sorry I tried the code it did not work.

ReefAngel.DosingPumpRepeat( Box1_Port2,0,180,2 );
if (millis()<60000) ReefAngel.Relay.Off( Box1_Port2 );

I Even tried increasing it to <1100000
and still did not work. It still turn, it must be powering port 2 cause if there is no power it should not turn.

I wonder whats going on
Im including the specification of my power supply below.

This is the spec of the DC power supply for my food timer.

INPUT AC100-240V 50/60hz
Output DC 5v 3A

Even if the RA now i believe is stable as I dont see it shutting OFF AND ON.

I firmly believe as a SAFETY FEATURE I need a code to keep the power not entering.
This port 2 which i am using with the food timer should not spin at all.

I almost crash my tank 2x, i wont sleep well at night if i now anytime it can happen again.
so for me this is very important that I get this code command not to give power on this particular port.

Posts: 12200
Joined: Fri Mar 18, 2011 6:47 pm
PostPosted: Sat Jan 06, 2018 11:16 am
Can you post your code?
Roberto.
User avatar
Posts: 31
Joined: Fri May 04, 2012 10:13 am
PostPosted: Sat Jan 06, 2018 2:47 pm
CHECK YOUR emailed.

Also You cannot instruct it not to feed at any time because it can sense electricity in the port.

Posts: 12200
Joined: Fri Mar 18, 2011 6:47 pm
PostPosted: Sat Jan 06, 2018 6:33 pm
Others can't see my email.
Roberto.
User avatar
Posts: 31
Joined: Fri May 04, 2012 10:13 am
PostPosted: Wed Jan 10, 2018 8:46 am
Ok I did not understand what you wanted me to do. Now I get it, you want me to post the code created by the wizard.
Last edited by mikedizon on Sat Jan 13, 2018 5:03 am, edited 1 time in total.

Posts: 12200
Joined: Fri Mar 18, 2011 6:47 pm
PostPosted: Wed Jan 10, 2018 9:23 am
PMing me doesn't help.
Nobody can see it.
Roberto.
User avatar
Posts: 31
Joined: Fri May 04, 2012 10:13 am
PostPosted: Sat Jan 13, 2018 5:10 am
#include <Salinity.h>
#include <ReefAngel_Features.h>
#include <Globals.h>
#include <RA_TS.h>
#include <RA_TouchLCD.h>
#include <RA_TFT.h>
#include <RA_TS.h>
#include <Font.h>
#include <RA_Wifi.h>
#include <RA_Wiznet5100.h>
#include <SD.h>
#include <SPI.h>
#include <Ethernet.h>
#include <EthernetDHCP.h>
#include <PubSubClient.h>
#include <Wire.h>
#include <OneWire.h>
#include <Time.h>
#include <DS1307RTC.h>
#include <InternalEEPROM.h>
#include <RA_ATO.h>
#include <LED.h>
#include <RA_TempSensor.h>
#include <Relay.h>
#include <RA_PWM.h>
#include <Timer.h>
#include <Memory.h>
#include <InternalEEPROM.h>
#include <RA_Colors.h>
#include <RA_CustomColors.h>
#include <RA_CustomLabels.h>
#include <RF.h>
#include <IO.h>
#include <ORP.h>
#include <AI.h>
#include <PH.h>
#include <WaterLevel.h>
#include <Humidity.h>
#include <PAR.h>
#include <DCPump.h>
#include <ReefAngel.h>
#include <SoftwareSerial.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
ReefAngel.Star();
ReefAngel.AddSalinityExpansion(); // Salinity Expansion Module
ReefAngel.AddWaterLevelExpansion(); // Water Level Expansion Module
ReefAngel.SetTemperatureUnit( Celsius ); // set to Celsius Temperature
// Ports toggled in Feeding Mode
ReefAngel.FeedingModePorts = 0;
ReefAngel.FeedingModePortsE[0] = 0;
ReefAngel.FeedingModePortsE[1] = 0;
// Ports toggled in Water Change Mode
ReefAngel.WaterChangePorts = 0;
ReefAngel.WaterChangePortsE[0] = 0;
ReefAngel.WaterChangePortsE[1] = 0;
// Ports turned off when Overheat temperature exceeded
ReefAngel.OverheatShutoffPorts = 0;
ReefAngel.OverheatShutoffPortsE[0] = 0;
ReefAngel.OverheatShutoffPortsE[1] = 0;
// Ports toggled when Lights On / Off menu entry selected
ReefAngel.LightsOnPorts = 0;
ReefAngel.LightsOnPortsE[0] = 0;
ReefAngel.LightsOnPortsE[1] = 0;
// Use T1 probe as temperature and overheat functions
ReefAngel.TempProbe = T1_PROBE;
ReefAngel.OverheatProbe = T1_PROBE;
// Set the Overheat temperature setting
InternalMemory.OverheatTemp_write( 335 );

// Ports that are always on
ReefAngel.Relay.On( Box1_Port1 );
ReefAngel.Relay.On( Box1_Port3 );
ReefAngel.Relay.On( Box1_Port4 );
ReefAngel.Relay.On( Box1_Port5 );
ReefAngel.Relay.On( Box1_Port7 );
ReefAngel.Relay.On( Box1_Port8 );

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


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

void loop()
{
ReefAngel.DosingPumpRepeat( Box1_Port2,0,180,2 );
ReefAngel.StandardLights( Box1_Port6,10,30,14,0 );

boolean buzzer=false;
if ( ReefAngel.isOverheat() ) buzzer=true;
if ( ReefAngel.isBusLock() ) buzzer=true;
if ( buzzer ) ReefAngel.BuzzerOn(2); else ReefAngel.BuzzerOff();

////// Place your custom code below here
if ((hour()>19 && minute()>29) || (hour()<8 && minute()<30)) ReefAngel.Relay.Off(Box1_Port2 );


////// Place your custom code above here

ReefAngel.Network.Cloud();
// This should always be the last line
ReefAngel.ShowTouchInterface();
}



// RA_STRING1=U2FsdGVkX1+4VN0SJWgbihJGhrPoZNW48utW3/7MRgQ=
// RA_STRING2=U2FsdGVkX1+XHP8X+u5QIW7n+ZpRlTkBCSo6V2xVozs=
// RA_STRING3=Greenhouse
// RA_LABEL LABEL_ACTINIC=Actinic
// RA_LABEL LABEL_ACTINIC2=Actinic 2
// RA_LABEL LABEL_DAYLIGHT=Daylight
// RA_LABEL LABEL_DAYLIGHT2=Daylight 2
// RA_LABEL LABEL_PORT1=Port 1
// RA_LABEL LABEL_PORT11=Pump 1
// RA_LABEL LABEL_PORT12=Food Timer
// RA_LABEL LABEL_PORT13=Pump 2
// RA_LABEL LABEL_PORT14=Pump 3
// RA_LABEL LABEL_PORT15=Pump 4
// RA_LABEL LABEL_PORT16=Ozone
// RA_LABEL LABEL_PORT17=Skimmer 2
// RA_LABEL LABEL_PORT18=Skimmer 1
// RA_LABEL LABEL_PORT2=Port 2
// RA_LABEL LABEL_PORT21=Port 21
// RA_LABEL LABEL_PORT22=Port 22
// RA_LABEL LABEL_PORT23=Port 23
// RA_LABEL LABEL_PORT24=Port 24
// RA_LABEL LABEL_PORT25=Port 25
// RA_LABEL LABEL_PORT26=Port 26
// RA_LABEL LABEL_PORT27=Port 27
// RA_LABEL LABEL_PORT28=Port 28
// RA_LABEL LABEL_PORT3=Port 3
// RA_LABEL LABEL_PORT4=Port 4
// RA_LABEL LABEL_PORT5=Port 5
// RA_LABEL LABEL_PORT6=Port 6
// RA_LABEL LABEL_PORT7=Port 7
// RA_LABEL LABEL_PORT8=Port 8
Previous

Return to Requests

Who is online

Users browsing this forum: Google [Bot] and 1 guest