Weather Simulation for Dimming expansion module

Share you PDE file with our community
rimai
Posts: 12881
Joined: Fri Mar 18, 2011 6:47 pm

Re: Weather Simulation for Dimming expansion module

Post by rimai »

If it is just the lightning you are trying to achieve, you can use this:
http://forum.reefangel.com/viewtopic.php?f=14&t=288
Roberto.
binder
Posts: 2871
Joined: Fri Mar 18, 2011 6:20 pm
Location: Illinois
Contact:

Re: Weather Simulation for Dimming expansion module

Post by binder »

Sacohen wrote:Did this ever get ported to the head unit with any luck?
I'm working on getting my LED's running and would love to have a storm mode set up, but I have no idea how to dow this.
i havent gotten a response back with the base code to try to turn into a library because i was told there were changes made from what was originally posted. so theres not been any progress that im aware but thats not saying much anymore. :-)


Sent from my iPad mini
User avatar
Sacohen
Posts: 1833
Joined: Sun Apr 21, 2013 6:25 am
Location: Davie, FL

Re: Weather Simulation for Dimming expansion module

Post by Sacohen »

Ok. Thanks

Sent from my HTC One VX using Tapatalk
User avatar
Sacohen
Posts: 1833
Joined: Sun Apr 21, 2013 6:25 am
Location: Davie, FL

Re: Weather Simulation for Dimming expansion module

Post by Sacohen »

rimai wrote:If it is just the lightning you are trying to achieve, you can use this:
http://forum.reefangel.com/viewtopic.php?f=14&t=288

What I would like to do is the following...

1) Sunrise/sunset (not necessarily accurate to the actual sunrise sunset)
2) Random Lightning
3) Random Cloud cover

Possibly Moonlight cycle later. That I would want tied to the actual Moon Phase.
User avatar
lnevo
Posts: 5430
Joined: Fri Jul 20, 2012 9:42 am

Re: Weather Simulation for Dimming expansion module

Post by lnevo »

Steve,

The Sunrise/Sunet you could get from my SunLocaltion class that binder helped to isolate. The Moon cycle, you could also get from my Moon class. This would give you daily rise/set moontime or you could use your own schedule and use MoonPhase() as the parameter.

Random lightning and random cloud cover could then just be done with the standalone weather effects that Roberto linked to.
User avatar
Sacohen
Posts: 1833
Joined: Sun Apr 21, 2013 6:25 am
Location: Davie, FL

Re: Weather Simulation for Dimming expansion module

Post by Sacohen »

Ok. Cool.

Sent from my HTC One VX using Tapatalk
User avatar
heatdissipation
Posts: 52
Joined: Wed Aug 14, 2013 5:25 am

Re: Weather Simulation for Dimming expansion module

Post by heatdissipation »

Will this program work with sixteen channels, Roberto is making me a custom 16 channel expansion and this is exactly what I would like to do. How difficult would it be to use sixteen channels.
User avatar
lnevo
Posts: 5430
Joined: Fri Jul 20, 2012 9:42 am

Re: Weather Simulation for Dimming expansion module

Post by lnevo »

The code was meant to live on the old dimming modules. However the code does nothing special that couldnt be done with 16 channels, but the code will take a bit of tweaking.

I have a standalone class that determines sun rise/set and roberto has a weather effect somewhere thats a lot simpler
User avatar
heatdissipation
Posts: 52
Joined: Wed Aug 14, 2013 5:25 am

Re: Weather Simulation for Dimming expansion module

Post by heatdissipation »

Ya. I just got done reading all nine pages and came to that conclusion also. I'm reading both of those codes you just mentioned now. Just trying to find the time with my work schedule to compile the different codes I need is a task in and of itself.
User avatar
lnevo
Posts: 5430
Joined: Fri Jul 20, 2012 9:42 am

Re: Weather Simulation for Dimming expansion module

Post by lnevo »

Easier to add a feature at a time and take it slow :) Same as reefing to me.. No good code happens quickly.
User avatar
Sacohen
Posts: 1833
Joined: Sun Apr 21, 2013 6:25 am
Location: Davie, FL

Re: Weather Simulation for Dimming expansion module

Post by Sacohen »

Lee;

So your Moon class will simulate the actual moon cycles, where the MoonPhase() will just do a moon rise and set according to the time I set, correct?
User avatar
lnevo
Posts: 5430
Joined: Fri Jul 20, 2012 9:42 am

Re: Weather Simulation for Dimming expansion module

Post by lnevo »

Correct the Moon class gives you rise and set times based on the gos coordinate. I dont think it lines up right because we dont adjust for timezone and RA thinks it is GMT. But otherwise provides a very nice rhythm of moon rise and set.
morn623
Posts: 19
Joined: Fri May 16, 2014 4:25 pm

Re: Weather Simulation for Dimming expansion module

Post by morn623 »

I just wanted to confirm this simulation will not work on the newer version of the dimming expansion and has not yet been coded for the head unit? Thanks!
User avatar
lnevo
Posts: 5430
Joined: Fri Jul 20, 2012 9:42 am

Re: Weather Simulation for Dimming expansion module

Post by lnevo »

Correct.

It should not be that much work to port it to the head unit. I don't have a dimming setup where I could try though.
JoelIreland
Posts: 58
Joined: Sat Jan 26, 2013 1:27 am

Re: Weather Simulation for Dimming expansion module

Post by JoelIreland »

Hey all
I have just got a retro kit from Steve's LEDs for my Red Sea Max 650.
I have installed the kit and now want to add the dimmer expansion module to control sunrise sunset ( in Australia )
I already have the module and have been following this thread. The issue I am having is when i plug the module in to the PC to upload the code, it comes up with either faulty or unknown USB Device.
I run an IT company so this sort of thing is second nature but still having issues with it.

Am i meant to be plugging into the mini usb port or opening up the controller and plugging in there as there no instructions on this.

Thanks all
Joel
User avatar
Sacohen
Posts: 1833
Joined: Sun Apr 21, 2013 6:25 am
Location: Davie, FL

Re: Weather Simulation for Dimming expansion module

Post by Sacohen »

What are you trying to load the code to, the dimming module of the RA head unit?

Code only get uploaded to the RA head unit all other devices receive their commands from the head unit.

Instructions for all the devices can be found on the RA website.

Choose Downloads and then manuals.
(http://www.reefangel.com/download.aspx)
JoelIreland
Posts: 58
Joined: Sat Jan 26, 2013 1:27 am

Re: Weather Simulation for Dimming expansion module

Post by JoelIreland »

Sorry I was reading about how some load the sunrise sunset direct to dimmer module. Have had RA for few years so know the basic, just first time working with dimmer side. I have it working using the PWN function with parabola but for some weird reason say 100 will turn LEDs off but -100 will make bring and -150 brighter so seems to be in reverse. Wires are in correct place too.
saf1
Posts: 111
Joined: Thu Jun 28, 2012 1:46 pm

Re: Weather Simulation for Dimming expansion module

Post by saf1 »

morn623 wrote:I just wanted to confirm this simulation will not work on the newer version of the dimming expansion and has not yet been coded for the head unit? Thanks!
Oh, this code / library no longer works? Not sure what the newer version of the dimming expansion is though. I just installed one about a month back but not tried the weather module. Was looking at it this morning when I came across this note so figured I'd ask.
User avatar
lnevo
Posts: 5430
Joined: Fri Jul 20, 2012 9:42 am

Re: Weather Simulation for Dimming expansion module

Post by lnevo »

This has pretty much been replaced by the SunLocation class plus the Cloud and Lightning effects. I just realized if we add the seasonal temperature code, we'd be in a really cool position. Plus I just thought of something awesome... I have to look at the temp one to see if it makes sense. I think we can make that one much easier to implement and customize.
User avatar
Rodasphoto
Posts: 187
Joined: Wed Apr 10, 2013 2:48 pm
Location: Athens, Ga
Contact:

Re: Weather Simulation for Dimming expansion module

Post by Rodasphoto »

lnevo wrote:This has pretty much been replaced by the SunLocation class plus the Cloud and Lightning effects. I just realized if we add the seasonal temperature code, we'd be in a really cool position. Plus I just thought of something awesome... I have to look at the temp one to see if it makes sense. I think we can make that one much easier to implement and customize.
So how would one code for cloud, lightening, etc. ?
Image
User avatar
Sacohen
Posts: 1833
Joined: Sun Apr 21, 2013 6:25 am
Location: Davie, FL

Re: Weather Simulation for Dimming expansion module

Post by Sacohen »

The latest Cloud and Lightning code is here.

This is the original code for fast drivers and the dimming ports on the relay.
http://forum.reefangel.com/viewtopic.php?f=12&t=4783

Then it was modified to work on slower drivers and the dimming expansion module.

http://forum.reefangel.com/viewtopic.php?f=12&t=5460
saf1
Posts: 111
Joined: Thu Jun 28, 2012 1:46 pm

Re: Weather Simulation for Dimming expansion module

Post by saf1 »

Does the weather simulation pick a random day and time of the month to actually fire or is it every day or set in code based on us?

What I am wondering is if it is possible to switch the DC pump(s) to full during the storm then reset back to normal mode. I wouldn't want this happening every day but one or twice a month would be pretty cool to swoosh stuff around. May even be better than my turkey baster :)
User avatar
lnevo
Posts: 5430
Joined: Fri Jul 20, 2012 9:42 am

Re: Weather Simulation for Dimming expansion module

Post by lnevo »

It should be fairly easy to add some powerhead action. Was thinking about this yesterday actually. If I get to add it, I'll post my results.
saf1
Posts: 111
Joined: Thu Jun 28, 2012 1:46 pm

Re: Weather Simulation for Dimming expansion module

Post by saf1 »

Hate to ask this, but does the weather simulation library also simulate lighting?

I added the code this morning and have been toying with it when about an hour into post loading the code lights dimmed, assuming cloud, then all of a sudden flashed several quick successions with my blue channels being mostly called. Threw me for a loop but figured I'd ask.

I'm going to assume it does but wanted to be sure in case my multi chip can't handle it or I have to edit a value somewhere that maybe I missed.

The example I was using as a reference had it called as:

Global variable:
byte PWMChannel[6];


CheckCloud();

ReefAngel.PWM.SetChannel(0,PWMChannel[0]);
ReefAngel.PWM.SetChannel(1,PWMChannel[1]);
ReefAngel.PWM.SetChannel(2,PWMChannel[2]);
ReefAngel.PWM.SetChannel(3,PWMChannel[3]);
User avatar
lnevo
Posts: 5430
Joined: Fri Jul 20, 2012 9:42 am

Re: Weather Simulation for Dimming expansion module

Post by lnevo »

Yes. You can modify the lightning chance and frequency in the defines above the CheckCloud function you added
saf1
Posts: 111
Joined: Thu Jun 28, 2012 1:46 pm

Re: Weather Simulation for Dimming expansion module

Post by saf1 »

lnevo wrote:Yes. You can modify the lightning chance and frequency in the defines above the CheckCloud function you added

Thanks. That got me to the correct location and I was able to modify. Also found an error in the code that was causing the RW's to run at 100% rather than the 40 like I thought.

Thanks for the information.
troylong45
Posts: 214
Joined: Sat Oct 10, 2015 9:17 pm

Re: Weather Simulation for Dimming expansion module

Post by troylong45 »

saf1 wrote:Does the weather simulation pick a random day and time of the month to actually fire or is it every day or set in code based on us?

What I am wondering is if it is possible to switch the DC pump(s) to full during the storm then reset back to normal mode. I wouldn't want this happening every day but one or twice a month would be pretty cool to swoosh stuff around. May even be better than my turkey baster :)
has this been done yet the full power overide for storm chance for dc pump
Image
troylong45
Posts: 214
Joined: Sat Oct 10, 2015 9:17 pm

Re: Weather Simulation for Dimming expansion module

Post by troylong45 »

lnevo wrote:It should be fairly easy to add some powerhead action. Was thinking about this yesterday actually. If I get to add it, I'll post my results.

lee did you guys find out to add the powerheads into the storm deal?
Image
troylong45
Posts: 214
Joined: Sat Oct 10, 2015 9:17 pm

Re: Weather Simulation for Dimming expansion module

Post by troylong45 »

lnevo wrote:It should be fairly easy to add some powerhead action. Was thinking about this yesterday actually. If I get to add it, I'll post my results.

lee did you guys find out to add the powerheads into the storm deal?
Image
User avatar
lnevo
Posts: 5430
Joined: Fri Jul 20, 2012 9:42 am

Re: Weather Simulation for Dimming expansion module

Post by lnevo »

Colin was looking at it
Post Reply