can't even get my pump to turn on!

New members questions
Post Reply
mineman@mac.com
Posts: 43
Joined: Mon Jan 30, 2012 10:02 pm

can't even get my pump to turn on!

Post by mineman@mac.com »

Thank God the tank isn't completely filled yet!

First off, let me tell you that I finally got this thing working correctly on my 55 when I decided to do an upgrade to a 120. I am using the iPhone app which at this point is the only way I can control most of the tank (manually). I thought I was figuring this thing out but now I'm as lost as the day I bought it. :( At this point, here is what I want it to do:

Relay 1: ATO I have it on low so because I am using an aqualifter
Relay 2: Skimmer (off during feeding)
Relay 3: Lights (not ready to get creative with them yet!)
Relay 4: Pump (I might just move this to a constant 110v)
Relay 5: Wavemaker (I am using an eternal controller but want it turned off during water changes and feeding)
Relay 6: Standard heater (on 79.1; off 80)
Relay 7: Dose pump (one second twice a day, off during feeding and water change)
Relay 8: Dose pump (one second twice a day, off during feeding and water change)

I will need to modify this eventually so if all notes would be appreciated! Here are my codes>

Code: Select all

#include <ReefAngel_Features.h>
#include <Globals.h>
#include <Time.h>
#include <OneWire.h>
#include <RA_NokiaLCD.h>
#include <avr/pgmspace.h>
#include <InternalEEPROM.h>
#include <Wire.h>
#include <Memory.h>

RA_NokiaLCD e;

void setup()
{
    e.Init();
    e.Clear(COLOR_WHITE,0,0,132,132);
    e.BacklightOn();

    InternalMemory.MHOnHour_write(0);
    InternalMemory.MHOnMinute_write(0);
    InternalMemory.MHOffHour_write(0);
    InternalMemory.MHOffMinute_write(0);
    InternalMemory.MHDelay_write(0);
    InternalMemory.StdLightsOnHour_write(15);
    InternalMemory.StdLightsOnMinute_write(30);
    InternalMemory.StdLightsOffHour_write(20);
    InternalMemory.StdLightsOffMinute_write(30);
    InternalMemory.DP1OnHour_write(20);
    InternalMemory.DP1OnMinute_write(0);
    InternalMemory.DP2OnHour_write(22);
    InternalMemory.DP2OnMinute_write(30);
    InternalMemory.DP1Timer_write(4);
    InternalMemory.DP2Timer_write(4);
    InternalMemory.DP1RepeatInterval_write(60);
    InternalMemory.DP2RepeatInterval_write(60);
    InternalMemory.ATOTimeout_write(255);
    InternalMemory.ATOHighTimeout_write(60);
    InternalMemory.ATOHourInterval_write(0);
    InternalMemory.ATOHighHourInterval_write(0);
    InternalMemory.FeedingTimer_write(900);
    InternalMemory.LCDTimer_write(600);
    InternalMemory.LEDPWMActinic_write(100);
    InternalMemory.LEDPWMDaylight_write(100);
    InternalMemory.WM1Timer_write(0);
    InternalMemory.WM2Timer_write(0);
    InternalMemory.HeaterTempOn_write(791);
    InternalMemory.HeaterTempOff_write(800);
    InternalMemory.ChillerTempOn_write(774);
    InternalMemory.ChillerTempOff_write(770);
    InternalMemory.OverheatTemp_write(1500);
    InternalMemory.PHMax_write(830);
    InternalMemory.PHMin_write(540);
    InternalMemory.SalMax_write(2550);
    InternalMemory.RFMode_write(Constant);
    InternalMemory.RFSpeed_write(140);
    InternalMemory.RFDuration_write(8);
    InternalMemory.RFDuration_write(8);
    InternalMemory.PWMSlopeStartD_write(15);
    InternalMemory.PWMSlopeEndD_write(100);
    InternalMemory.PWMSlopeDurationD_write(60);
    InternalMemory.PWMSlopeStartA_write(15);
    InternalMemory.PWMSlopeEndA_write(100);
    InternalMemory.PWMSlopeDurationA_write(60);
    InternalMemory.IMCheck_write(0x5241494D);
}

void loop()
{
    // display the values
    char buf[128];
    sprintf(buf, "MH %2d:%02d-%2d:%02d,%d", InternalMemory.MHOnHour_read(), InternalMemory.MHOnMinute_read(),
                                         InternalMemory.MHOffHour_read(), InternalMemory.MHOffMinute_read(),
                                         InternalMemory.MHDelay_read());
    e.DrawText(COLOR_BLACK, COLOR_WHITE, MENU_START_COL, MENU_START_ROW, buf);
    sprintf(buf, "Std %2d:%02d-%2d:%02d", InternalMemory.StdLightsOnHour_read(), InternalMemory.StdLightsOnMinute_read(),
                                          InternalMemory.StdLightsOffHour_read(), InternalMemory.StdLightsOffMinute_read());
    e.DrawText(COLOR_BLACK, COLOR_WHITE, MENU_START_COL, MENU_START_ROW*2, buf);
    sprintf(buf, "LED A: %d%% D: %d%%", InternalMemory.LEDPWMActinic_read(), InternalMemory.LEDPWMDaylight_read());
    e.DrawText(COLOR_BLACK, COLOR_WHITE, MENU_START_COL, MENU_START_ROW*3, buf);
    sprintf(buf, "WM1: %ds", InternalMemory.WM1Timer_read());
    e.DrawText(COLOR_BLACK, COLOR_WHITE, MENU_START_COL, MENU_START_ROW*4, buf);
    sprintf(buf, "WM2: %ds", InternalMemory.WM2Timer_read());
    e.DrawText(COLOR_BLACK, COLOR_WHITE, MENU_START_COL, MENU_START_ROW*5, buf);
    sprintf(buf, "F: %ds", InternalMemory.FeedingTimer_read());
    e.DrawText(COLOR_BLACK, COLOR_WHITE, MENU_START_COL, MENU_START_ROW*6, buf);
    sprintf(buf, "S: %ds", InternalMemory.LCDTimer_read());
    e.DrawText(COLOR_BLACK, COLOR_WHITE, MENU_START_COL, MENU_START_ROW*7, buf);
    sprintf(buf, "H On: %d -> %d", InternalMemory.HeaterTempOn_read(), InternalMemory.HeaterTempOff_read());
    e.DrawText(COLOR_BLACK, COLOR_WHITE, MENU_START_COL, MENU_START_ROW*9, buf);
    sprintf(buf, "C On: %d -> %d", InternalMemory.ChillerTempOn_read(), InternalMemory.ChillerTempOff_read());
    e.DrawText(COLOR_BLACK, COLOR_WHITE, MENU_START_COL, MENU_START_ROW*10, buf);
    sprintf(buf, "PH %d - %d", InternalMemory.PHMax_read(), InternalMemory.PHMin_read());
    e.DrawText(COLOR_BLACK, COLOR_WHITE, MENU_START_COL, MENU_START_ROW*11, buf);

    delay(10000);
    e.Clear(COLOR_WHITE,0,0,132,132);

    sprintf(buf, "OH: %dF", InternalMemory.OverheatTemp_read());
    e.DrawText(COLOR_BLACK, COLOR_WHITE, MENU_START_COL, MENU_START_ROW, buf);
    sprintf(buf, "ATO L: %ds (%dh)", InternalMemory.ATOTimeout_read(), InternalMemory.ATOHourInterval_read());
    e.DrawText(COLOR_BLACK, COLOR_WHITE, MENU_START_COL, MENU_START_ROW*2, buf);
    sprintf(buf, "ATO H: %ds (%dh)", InternalMemory.ATOHighTimeout_read(), InternalMemory.ATOHighHourInterval_read());
    e.DrawText(COLOR_BLACK, COLOR_WHITE, MENU_START_COL, MENU_START_ROW*3, buf);

    sprintf(buf, "DP1: %2d:%02d", InternalMemory.DP1OnHour_read(), InternalMemory.DP1OnMinute_read());
    e.DrawText(COLOR_BLACK, COLOR_WHITE, MENU_START_COL, MENU_START_ROW*5, buf);
    sprintf(buf, "     %ds", InternalMemory.DP1Timer_read());
    e.DrawText(COLOR_BLACK, COLOR_WHITE, MENU_START_COL, MENU_START_ROW*6, buf);
    sprintf(buf, "DP2: %2d:%02d", InternalMemory.DP2OnHour_read(), InternalMemory.DP2OnMinute_read());
    e.DrawText(COLOR_BLACK, COLOR_WHITE, MENU_START_COL, MENU_START_ROW*7, buf);
    sprintf(buf, "     %ds", InternalMemory.DP2Timer_read());
    e.DrawText(COLOR_BLACK, COLOR_WHITE, MENU_START_COL, MENU_START_ROW*8, buf);

    delay(10000);
    e.Clear(COLOR_WHITE,0,0,132,132);
}
[code]

and 

[code]#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 <ReefAngel.h>

void setup()
{// Starting from the left, it's Ports 87654321;
  ReefAngel.FeedingModePorts = B01001011;
  ReefAngel.WaterChangePorts = B10110011;
  ReefAngel.Init();  //Initialize controller
}

void loop()
{
  ReefAngel.SingleATOLow(Port1);
  ReefAngel.StandardLights(Port3);
  ReefAngel.Wavemaker1(Port5);
  ReefAngel.StandardHeater(Port6);
    if (now()%43200<1) ReefAngel.Relay.On(Port7); 
  else ReefAngel.Relay.Off(Port7); 
    if (now()%43200<1) ReefAngel.Relay.On(Port8); 
  else ReefAngel.Relay.Off(Port8); 
  // You can only increment the dosing in seconds
  // 43200 the frequency in seconds that the dosing pump will be activated. 24hrs= 86400s, 12hrs= 43200s
  // 1 is the number of seconds that the dosing pump will stay on.

  ReefAngel.Portal("mineman@mac.com");
  ReefAngel.ShowInterface();
}
[code]
Image
rossbryant1956
Posts: 471
Joined: Sat Jan 14, 2012 2:08 pm
Location: Montgomery Village, MD

Re: can't even get my pump to turn on!

Post by rossbryant1956 »

I guess the one thing I am doing separately from you is taking things one device at at time. I started with pump and heaters; added lights, and stopped. After that was working I added wavemakers, and stopped.

I am now adding float valve control with a buzzer to control a pump, and will stop.

I have learned several things in my many years with computers: never work on more than one thing at a time, if you have trouble you will not know what is broke, and then finally ( and it is very successful on this board) Ask very specific questions...

Thx and good luck
Roscoe's Reefs - Starting Over Again:

Building new 29g Nano after landlord went berserk over my 4 75 gallon tanks, Multiple RA's, Water mixing stations, etc. Your help welcomed in remembering all I've forgotten.
rimai
Posts: 12857
Joined: Fri Mar 18, 2011 6:47 pm

Re: can't even get my pump to turn on!

Post by rimai »

Have you tried using the Reef Angel Wizard?
Download the new Reef Angel Installer from http://reefangel.com/Download.ashx
Then go to menu Tools->Reef Angel Wizard
Give it a try and if you still have problems, come back here.
Roberto.
mineman@mac.com
Posts: 43
Joined: Mon Jan 30, 2012 10:02 pm

Re: can't even get my pump to turn on!

Post by mineman@mac.com »

rimai wrote:Have you tried using the Reef Angel Wizard?
Download the new Reef Angel Installer from http://reefangel.com/Download.ashx
Then go to menu Tools->Reef Angel Wizard
Give it a try and if you still have problems, come back here.
I just downloaded it but there is no "Reef Angel Wizard" under tools.
Image
rossbryant1956
Posts: 471
Joined: Sat Jan 14, 2012 2:08 pm
Location: Montgomery Village, MD

Re: can't even get my pump to turn on!

Post by rossbryant1956 »

had the same problem, make sure you have the 0.9.9 libraries.
Roscoe's Reefs - Starting Over Again:

Building new 29g Nano after landlord went berserk over my 4 75 gallon tanks, Multiple RA's, Water mixing stations, etc. Your help welcomed in remembering all I've forgotten.
rimai
Posts: 12857
Joined: Fri Mar 18, 2011 6:47 pm

Re: can't even get my pump to turn on!

Post by rimai »

I know you are using Mac. You have to also move the Arduino folder to the Documents folder.
Roberto.
mineman@mac.com
Posts: 43
Joined: Mon Jan 30, 2012 10:02 pm

Re: can't even get my pump to turn on!

Post by mineman@mac.com »

ok, I now have Arduino in the documents folder as well as apps. How do I verify that I have 0.9.9 libraries?
Image
mineman@mac.com
Posts: 43
Joined: Mon Jan 30, 2012 10:02 pm

Re: can't even get my pump to turn on!

Post by mineman@mac.com »

Still no wizard...
Image
mineman@mac.com
Posts: 43
Joined: Mon Jan 30, 2012 10:02 pm

Re: can't even get my pump to turn on!

Post by mineman@mac.com »

ok, got into the wizard. I will let you know how it goes.... Thanks.
Image
mineman@mac.com
Posts: 43
Joined: Mon Jan 30, 2012 10:02 pm

Re: can't even get my pump to turn on!

Post by mineman@mac.com »

Ok... Wizard is great! but.... I get this error now:

The following feature was automatically added:
Watchdog Timer
Version Menu

The following features were detected:
Dimming Signal
ORP Expansion Module
Wifi
Custom Main Screen
Simple Menu
Binary sketch size: 29,742 bytes (of a 32,256 byte maximum)
dyld: Library not loaded: /usr/lib/libedit.3.dylib
Referenced from: /Applications/Arduino.app/Contents/Resources/Java/hardware/tools/avr/bin/avrdude
Reason: image not found
Image
rimai
Posts: 12857
Joined: Fri Mar 18, 2011 6:47 pm

Re: can't even get my pump to turn on!

Post by rimai »

I googled the error and this came up.
http://www.ludicroussoftware.com/blog/2 ... w-leopard/
Try it and let me know if it works.
Roberto.
mineman@mac.com
Posts: 43
Joined: Mon Jan 30, 2012 10:02 pm

Re: can't even get my pump to turn on!

Post by mineman@mac.com »

Once again... Roberto, you the man!
Image
Post Reply