Internal memory code without metal halide.

Do you have a question on how to do something.
Ask in here.
Post Reply
abhi_123
Posts: 216
Joined: Tue Mar 20, 2012 8:34 am

Internal memory code without metal halide.

Post by abhi_123 »

Hi All,

I Recently ordered my Reef Angel controller & eagerly waiting for it to reach me asap.

While browsing thru Ragen I find that in internal memory coding option we have to go for both standard light values as well as for metal halide value as i am planning to use Led light for my tank i don't want memory values for mh as well as only one relay for lighting options. how to do it as i want to save memory for expansion module which i m planning to add in near future.

I generated a test code & m planning to upload the same when i will get my device.
// Autogenerated file by RAGen (v1.2.1.158), (04/22/2012 12:20)
// Memory_042212_1220.ino
//
// This file sets the default values to the Internal Memory
//


#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(8);
    InternalMemory.MHOnMinute_write(0);
    InternalMemory.MHOffHour_write(15);
    InternalMemory.MHOffMinute_write(0);
    InternalMemory.MHDelay_write(0);
    InternalMemory.StdLightsOnHour_write(8);
    InternalMemory.StdLightsOnMinute_write(0);
    InternalMemory.StdLightsOffHour_write(15);
    InternalMemory.StdLightsOffMinute_write(0);
    InternalMemory.DP1OnHour_write(0);
    InternalMemory.DP1OnMinute_write(0);
    InternalMemory.DP2OnHour_write(22);
    InternalMemory.DP2OnMinute_write(30);
    InternalMemory.DP1Timer_write(0);
    InternalMemory.DP2Timer_write(0);
    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(960);
    InternalMemory.LCDTimer_write(300);
    InternalMemory.LEDPWMActinic_write(0);
    InternalMemory.LEDPWMDaylight_write(0);
    InternalMemory.WM1Timer_write(200);
    InternalMemory.WM2Timer_write(354);
    InternalMemory.HeaterTempOn_write(780);
    InternalMemory.HeaterTempOff_write(791);
    InternalMemory.ChillerTempOn_write(810);
    InternalMemory.ChillerTempOff_write(785);
    InternalMemory.OverheatTemp_write(1500);
    InternalMemory.PHMax_write(840);
    InternalMemory.PHMin_write(480);
    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(128);
    InternalMemory.PWMSlopeDurationD_write(60);
    InternalMemory.PWMSlopeStartA_write(15);
    InternalMemory.PWMSlopeEndA_write(128);
    InternalMemory.PWMSlopeDurationA_write(60);
    InternalMemory.IMCheck_write(0x5241494D);
}

void loop()
{
    // display success screen
    e.DrawText(COLOR_BLACK, COLOR_WHITE, MENU_START_COL, MENU_START_ROW*2, "Internal Memory Set");
    e.DrawText(COLOR_BLACK, COLOR_WHITE, MENU_START_COL, MENU_START_ROW*4, "Now load your");
    e.DrawText(COLOR_BLACK, COLOR_WHITE, MENU_START_COL, MENU_START_ROW*5, " RA code file");
    delay(5000);
}
How to remove Metal halides values from it. i am a newbie & i have next to zero knowledge of programming please be patient with me for next few days.
Image
binder
Posts: 2865
Joined: Fri Mar 18, 2011 6:20 pm
Location: Illinois
Contact:

Re: Internal memory code without metal halide.

Post by binder »

The Internal Memory values do not affect code space for your program. There is specific "storage" space on the controller (think like saving values to the windows registry or your saved settings with applications). Then there is "code" space where the program code that runs the controller gets placed. These 2 spaces are completely separate from each other. Having values stored in the Internal Memory will not affect anything at all. They are just sitting there waiting for you to use them (if you ever do).

So what you are worrying about is something you shouldn't worry about at all.
abhi_123
Posts: 216
Joined: Tue Mar 20, 2012 8:34 am

Re: Internal memory code without metal halide.

Post by abhi_123 »

The main reason for my worry is that i want to have only one relay port for my led lights. as i am planning to add something else on the port assigned for mh.
Image
binder
Posts: 2865
Joined: Fri Mar 18, 2011 6:20 pm
Location: Illinois
Contact:

Re: Internal memory code without metal halide.

Post by binder »

No need to worry about that. You just need to not include or use the Metal Halide device when creating your code.
Post Reply