Control port with pH value ??

Related to the development libraries, released by Curt Binder
Post Reply
AquaO
Posts: 61
Joined: Sun May 27, 2012 11:22 am

Control port with pH value ??

Post by AquaO »

Hi, I would like to Know if is possible to control one port with a pH value??

Exemple: pH under 7,5 air pump On
pH 8 air pump Off

Thank for you help
Image

Osaka 40g with 55g sump
Radion, 2X Tunze 6045, Swc-160 mini cone
rimai
Posts: 12881
Joined: Fri Mar 18, 2011 6:47 pm

Re: Control port with pH value ??

Post by rimai »

What version of libs are you using?
On v0.9.9, you can use:

Code: Select all

ReefAngel.PHControl( Port1,750,800);
Roberto.
AquaO
Posts: 61
Joined: Sun May 27, 2012 11:22 am

Control port with pH value ??

Post by AquaO »

Wow!!!

You never sleep Roberto? ;)

Thank you very much i will try this (tup)
Image

Osaka 40g with 55g sump
Radion, 2X Tunze 6045, Swc-160 mini cone
AquaO
Posts: 61
Joined: Sun May 27, 2012 11:22 am

Re: Control port with pH value ??

Post by AquaO »

rimai wrote:What version of libs are you using?
On v0.9.9, you can use:

Code: Select all

ReefAngel.PHControl( Port1,750,800);

I try this for test and not work, I have libs v0.9.9
This is my code generate with de wizard and mod for PH control, sorry i'm very newbie to make a code ;)

Code: Select all

#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 <InternalEEPROM.h>
#include <RA_Colors.h>
#include <RA_CustomColors.h>
#include <Salinity.h>
#include <RF.h>
#include <IO.h>
#include <ORP.h>
#include <AI.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 = Port1Bit | Port2Bit | Port3Bit | Port4Bit | Port5Bit | Port6Bit | Port7Bit;
    // Ports toggled in Water Change Mode
    ReefAngel.WaterChangePorts = 0;
    // Ports toggled when Lights On / Off menu entry selected
    ReefAngel.LightsOnPorts = 0;
    // Ports turned off when Overheat temperature exceeded
    ReefAngel.OverheatShutoffPorts = 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( 869 );


    // Ports that are always on
    ReefAngel.Relay.On( Port1 );
    ReefAngel.Relay.On( Port2 );
    ReefAngel.Relay.On( Port3 );
    ReefAngel.Relay.On( Port4 );
    ReefAngel.Relay.On( Port5 );
    ReefAngel.Relay.On( Port7 );

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

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

void loop()
{
    ReefAngel.DosingPumpRepeat( Port8,0,60,6 );
    ////// Place your custom code below here
    ReefAngel.PHControl( Port6,750,800);

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

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

Thank you very much
Image

Osaka 40g with 55g sump
Radion, 2X Tunze 6045, Swc-160 mini cone
rimai
Posts: 12881
Joined: Fri Mar 18, 2011 6:47 pm

Re: Control port with pH value ??

Post by rimai »

This code works just fine for me.
Turns on when pH is less than 7.50 and off when pH is over 8.00
Roberto.
AquaO
Posts: 61
Joined: Sun May 27, 2012 11:22 am

Re: Control port with pH value ??

Post by AquaO »

Ok it's work fine...the problem was my interpretation

When i tested, the Ph in my tank indicate 7.8 and the Ph control is on 7.5 and off 8.0 my port is On, cause my ph is 7.8 (i was thinking is Off) i have try with different value like on 7.5 and off 7.7 and its work, my port is off cause my ph is 7.8

I dont know if i'm clear, but the most important it's this code is good

thank you very much, the Reef Angel is the best controller in the world i'm very happy with my purchase
Image

Osaka 40g with 55g sump
Radion, 2X Tunze 6045, Swc-160 mini cone
Post Reply