Reef Pico LED intefacing, 3 watt LED's and RTC
hello lovely people!
after pretty long break picked new arduino mega project sort of started 6 months ago.
long story short, started never finished, life took on , job pick up, i've jsut finished uni exams few months thought i'd have stab.
firstly first project can found here:
http://www.arduino.cc/cgi-bin/yabb2/yabb.pl?num=1269962097/0
the idea build own little reef computer pico tank set up, unfortunatly july 10 had dismantle pico wasnt getting attention needed plus going away on holiday etc ment best. restarted pico last month , restarted interest in arduinos, ordered bits , bobs , have stab @ project.
i deciced buy second mega work on different aspects of project before compiling old (which mess of breadboards, wires, probes etc)
so without wasting more time
ladys , gentle men if choose help.
i want write piece of software utilizes buckpucks of diy led light , fade led's in via pwm , rtc chip.
once ive got basics sorted, incorporate moon light , possibly have fun "random" weather patterns etc.
i've had bit of dabble everning "relearning ropes" coding, last object orientated programing did months go, , poor memory unfortunatly has slipped
so stage im @ far...
....
yup thats nothing!
ok not quite,
i hooked diy rtc chip arduino , pulled on test coding , used sereal monitor check works.
this ment 10-15 minute job before starting more productive coding reason rtc chip isnt working correctly or atleast coding.
for reason "seconds" wont write properly.
when call serial monitor starts 0. edit while typing entry realised needed hash out rtc start program after had been flashed rtc chip can move onto fun bit
heres given test code:
how guys go implimenting form of coding
8:00am = start fading first chain of led's in
8.30am = start fading in second chain of led's in
8.00pm = start fading second chain of led's out
8.30pm = start fading second chain of leds out.
id each chain fade in 0-100% on space of 1hour
would guys use multi argument if statement?
if((ds1307_hr ==
&&(ds1307_min = 0){
....
}
i know consept far new nor application, yes have googled , come across little wanted compile thoughts, code etc own thread.
many in advanced
luke
p.s.
if anyones interested:
my 4ft x 2ftx 2ft mixed reef
http://www.ocean-wonders.co.uk/messageboard/showthread.php/7553-phoenix-s-reef-v3.0/page18
and led driven pico arduino project for:
http://www.ocean-wonders.co.uk/messageboard/showthread.php/6439-phoenix-s-little-suprise/page16
after pretty long break picked new arduino mega project sort of started 6 months ago.
long story short, started never finished, life took on , job pick up, i've jsut finished uni exams few months thought i'd have stab.
firstly first project can found here:
http://www.arduino.cc/cgi-bin/yabb2/yabb.pl?num=1269962097/0
the idea build own little reef computer pico tank set up, unfortunatly july 10 had dismantle pico wasnt getting attention needed plus going away on holiday etc ment best. restarted pico last month , restarted interest in arduinos, ordered bits , bobs , have stab @ project.
i deciced buy second mega work on different aspects of project before compiling old (which mess of breadboards, wires, probes etc)
so without wasting more time
ladys , gentle men if choose help.
i want write piece of software utilizes buckpucks of diy led light , fade led's in via pwm , rtc chip.
once ive got basics sorted, incorporate moon light , possibly have fun "random" weather patterns etc.
i've had bit of dabble everning "relearning ropes" coding, last object orientated programing did months go, , poor memory unfortunatly has slipped

so stage im @ far...
....
yup thats nothing!
ok not quite,
i hooked diy rtc chip arduino , pulled on test coding , used sereal monitor check works.
this ment 10-15 minute job before starting more productive coding reason rtc chip isnt working correctly or atleast coding.
for reason "seconds" wont write properly.
when call serial monitor starts 0.
heres given test code:
code: [select]
#include <wprogram.h>
#include <wire.h>
#include <ds1307.h>
void setup()
{
serial.begin(9600);
rtc.stop();
rtc.set(ds1307_dow,5);
rtc.set(ds1307_date,21);
rtc.set(ds1307_mth,1);
rtc.set(ds1307_yr,11);
rtc.set(ds1307_sec,34);
rtc.set(ds1307_min,46);
rtc.set(ds1307_hr,20);
rtc.start();
}
void loop()
{
serial.print(rtc.get(ds1307_hr,true)); //read hour , update values pushing in true
serial.print(":");
serial.print(rtc.get(ds1307_min,false));//read minutes without update (false)
serial.print(":");
serial.print(rtc.get(ds1307_sec,false));//read seconds
serial.print(" "); // space more happy life
serial.print(rtc.get(ds1307_date,false));//read date
serial.print("/");
serial.print(rtc.get(ds1307_mth,false));//read month
serial.print("/");
serial.print(rtc.get(ds1307_yr,false)); //read year
serial.println();
delay(1000);
}how guys go implimenting form of coding
8:00am = start fading first chain of led's in
8.30am = start fading in second chain of led's in
8.00pm = start fading second chain of led's out
8.30pm = start fading second chain of leds out.
id each chain fade in 0-100% on space of 1hour
would guys use multi argument if statement?
if((ds1307_hr ==
&&(ds1307_min = 0){....
}
i know consept far new nor application, yes have googled , come across little wanted compile thoughts, code etc own thread.
many in advanced
luke
p.s.
if anyones interested:
my 4ft x 2ftx 2ft mixed reef
http://www.ocean-wonders.co.uk/messageboard/showthread.php/7553-phoenix-s-reef-v3.0/page18
and led driven pico arduino project for:
http://www.ocean-wonders.co.uk/messageboard/showthread.php/6439-phoenix-s-little-suprise/page16
quote
8:00am = start fading first chain of led's in
8.30am = start fading in second chain of led's in
8.00pm = start fadingsecond(first?) chain of led's out
8.30pm = start fading second chain of leds out.
sounds interesting project. i'll give few little basic timing values maybe started. having rtc makes pretty simple task think. assume using analogwrite() function pwm led brightness.
analogwrite() function has 0-255 step capacity dimming of 0-100% brightness, , wish fade or down on 12 hour period, means incrementing or decrementing pwm value every 3 mins, close enough think, (3x256) / 60 = 12.8 hours cycle.
so sketch needs keep reading rtc until sees 'start' time , starts pwm analogwrite command starting 0 , incrementing pwm value every 3 mins read rtc. can have o 2 time frames going if wished have overlap time between 2 light assemblies, other wise it's keep reading rtc , see when it's time make move.
lefty
Arduino Forum > Forum 2005-2010 (read only) > Software > Interfacing > Reef Pico LED intefacing, 3 watt LED's and RTC
arduino
Comments
Post a Comment