Lee's Feature Complete PDE

Share you PDE file with our community
ufgators2k
Posts: 58
Joined: Sun May 12, 2013 2:21 pm

Re: Lee's Feature Complete PDE

Post by ufgators2k »

Can you post the latest screen grabs of your custom main screens? I think it would help me understand the code more.
Image
User avatar
lnevo
Posts: 5430
Joined: Fri Jul 20, 2012 9:42 am

Re: Lee's Feature Complete PDE

Post by lnevo »

Sure, here you go!

Took these a while ago and never got around to it!
ImageUploadedByTapatalk1370458281.912860.jpg
ImageUploadedByTapatalk1370458281.912860.jpg (43.73 KiB) Viewed 6042 times
ImageUploadedByTapatalk1370458294.689773.jpg
ImageUploadedByTapatalk1370458294.689773.jpg (34.28 KiB) Viewed 6042 times
ImageUploadedByTapatalk1370458310.905797.jpg
ImageUploadedByTapatalk1370458310.905797.jpg (31.03 KiB) Viewed 6042 times
ufgators2k
Posts: 58
Joined: Sun May 12, 2013 2:21 pm

Re: Lee's Feature Complete PDE

Post by ufgators2k »

Lee,

Thanks for the pics. That actually helps a lot. I had one quick question on your code. It appears that you have three relays in your draw relay function. Am I misinterpreting the code?

Code: Select all

  // Draw Relays
  byte TempRelay = ReefAngel.Relay.RelayData;
  TempRelay &= ReefAngel.Relay.RelayMaskOff;
  TempRelay |= ReefAngel.Relay.RelayMaskOn;
  ReefAngel.LCD.DrawOutletBox(x, y, TempRelay);

  y+=12;
  TempRelay = ReefAngel.Relay.RelayDataE[0];
  TempRelay &= ReefAngel.Relay.RelayMaskOffE[0];
  TempRelay |= ReefAngel.Relay.RelayMaskOnE[0];
  ReefAngel.LCD.DrawOutletBox(x, y, TempRelay);
  
  y+=123;
  TempRelay = ReefAngel.Relay.RelayDataE[1];
  TempRelay &= ReefAngel.Relay.RelayMaskOffE[1];
  TempRelay |= ReefAngel.Relay.RelayMaskOnE[1];
  ReefAngel.LCD.DrawOutletBox(x, y, TempRelay);  
}
Image
User avatar
lnevo
Posts: 5430
Joined: Fri Jul 20, 2012 9:42 am

Re: Lee's Feature Complete PDE

Post by lnevo »

Yes, I took those shots a few months ago before I added the additional relays..I moved the date line to the banner section and added a 3rd relay bar to the drawing. Good eyes!

If you looked close enough, the date on the controller is 4/29.
ufgators2k
Posts: 58
Joined: Sun May 12, 2013 2:21 pm

Re: Lee's Feature Complete PDE

Post by ufgators2k »

Wow, you have a lot of power going to your tank!
Image
User avatar
lnevo
Posts: 5430
Joined: Fri Jul 20, 2012 9:42 am

Re: Lee's Feature Complete PDE

Post by lnevo »

The third really doesn't exist. You reference any outlet you want, whether it is there or not. I use those outlets to interact with my RA and trigger certain functions. :)
User avatar
lnevo
Posts: 5430
Joined: Fri Jul 20, 2012 9:42 am

Re: Lee's Feature Complete PDE

Post by lnevo »

Ok, I completely nailed the evaporation calculation routine. The original code worked, but was not very great. This one is it. I need to stop playing with my RA now and work on some other tank maintenance.... like that dreaded re-aquascaping...and more testing so I can get my dosers going finally.
User avatar
lnevo
Posts: 5430
Joined: Fri Jul 20, 2012 9:42 am

Re: Lee's Feature Complete PDE

Post by lnevo »

So in part of my last few updates I added a sub-mode to my tide simulation to allow it to switch daily the wave pattern that is applied. I think the overall affect is pretty cool. I like the daily switch a lot, it's like getting a different weather pattern each day :)
Attachments
Reef Angel Web Chart RFS.jpg
Reef Angel Web Chart RFS.jpg (32.79 KiB) Viewed 5995 times
jjdezek
Posts: 329
Joined: Fri May 17, 2013 1:35 pm

Re: Lee's Feature Complete PDE

Post by jjdezek »

got a few questions on this custom code. i read through your tutorial link and at the end it says
Also remember, if you are inside your own function, the controller will not be processing any of the functions
inside loop(). So the heaters/fans will not turn on/off with changes in temperatures. The lights will not turn
on/off on their schedule. The ATO will not turn on/off. The controller will not respond to WIFI requests. (To
respond to the WIFI requests, you will just need to call pingSerial() inside your code).
not sure im understanding this, is it saying if you do this code your heaters not going to turn on when your temp hits the low setting and turn off when hits high setting?
the other question can you make a menu option to toggle between wave patterns manully in the pwm actinic and daylight ports?
Image
User avatar
lnevo
Posts: 5430
Joined: Fri Jul 20, 2012 9:42 am

Re: Lee's Feature Complete PDE

Post by lnevo »

First off, you can have your own functions. If you loop inside your own function though you will not be processing other things. As long as your own function does its thing and comes back loop will still be processing.

Im not sure which tutorial your referring, i haven't written any. I don't have Jaebo pumps but i toggle my Vortech modes through a menu item with the joystick so you can use that as an example.

pingSerial is no longer needed in your code with the current libraries.
ReeferBee
Posts: 55
Joined: Wed May 08, 2013 6:23 pm
Location: North GA

Re: Lee's Feature Complete PDE

Post by ReeferBee »

jjdezek wrote:the other question can you make a menu option to toggle between wave patterns manully in the pwm actinic and daylight ports?
Please!
Barry

Current tank info: 150g mixed reef

"Some of the worst mistakes of my life were hair cuts" -Jim Morrison
User avatar
lnevo
Posts: 5430
Joined: Fri Jul 20, 2012 9:42 am

Re: Lee's Feature Complete PDE

Post by lnevo »

Its not so straightforward. It all depends on the rest of the code you are using. I suggest you start a new thread and post your full code and we can help you to put something together.
User avatar
lnevo
Posts: 5430
Joined: Fri Jul 20, 2012 9:42 am

Re: Lee's Feature Complete PDE

Post by lnevo »

Added BioHazard mode and ElseMode to my Custom random rotation pool. Also tweaked some of the alert messages to add some data. Need to update my screens to show what my custom parameters are doing.
Drs1210

Re: Lee's Feature Complete PDE

Post by Drs1210 »

Lee, what size UPS are you using, and have you tested it to see how long you can run your return on it?
User avatar
lnevo
Posts: 5430
Joined: Fri Jul 20, 2012 9:42 am

Re: Lee's Feature Complete PDE

Post by lnevo »

It's an 850VA UPS. Unfortunately it's not a true sine wave. The LCD says it will run things in my power outage mode which is my RA and my return pump for 70 minutes or so, but my return pump only gets about 10-15 minutes before it gives up. It doesn't like the signal unfortunately. So at some point I will replace the UPS or who knows, maybe the return pump will come out first :)
Drs1210

Re: Lee's Feature Complete PDE

Post by Drs1210 »

Thanks for finding that out for me. So do you think if you changed to one of those dc pumps, you might get the claimed 70 minutes?
User avatar
lnevo
Posts: 5430
Joined: Fri Jul 20, 2012 9:42 am

Re: Lee's Feature Complete PDE

Post by lnevo »

Not sure. Possibly. Maybe someone more electronically incline could chime in on that.

On another note, I've added a routine to keep track of maintenance tasks. Some it knows when I've done. Water change, refilled ato, emptied skimmate container, fed fish. Some i will have to manually reset. Gac, gfo, cal, alk. Working on the web interface to reset the manual ones. I'll add alerts later..
rimai
Posts: 12881
Joined: Fri Mar 18, 2011 6:47 pm

Re: Lee's Feature Complete PDE

Post by rimai »

The UPS reading is just an estimate.
Does your pump give up before the UPS is drained? Is it what you are saying?
If you go DC pump, you won't need to worry about true sine or not.
The AC voltage needs to be turned back into DC again anyway.
A little less efficient, because you are technically wasting energy to convert into AC from battery and then back into DC, but would work :)
Roberto.
User avatar
lnevo
Posts: 5430
Joined: Fri Jul 20, 2012 9:42 am

Re: Lee's Feature Complete PDE

Post by lnevo »

No the ups still has juice...the pump gives up after a but. It'll turn back on if i reset the relay. Good to know about the DC pump though. That might be a cheaper route than replacing the UPS :)
User avatar
lnevo
Posts: 5430
Joined: Fri Jul 20, 2012 9:42 am

Re: Lee's Feature Complete PDE

Post by lnevo »

So, today was the day I finally re-aquascaped my tank. II had about 35 gallons of water ready to go, abou twice my usual. I started by setting up my water change setup, and drained the water directly into a rubbermaid, about 18 gallons... Added heater and powerhead and transferred everything into it. Everything transferred back after giving the tank a good cleansing. Ran an extra powerhead with a filter sock on the output for a while as well. I scraped off all the extra epoxy off all the rocks. And finally after getting everything situated and the water cleared up, I changed my carbon and did another water change.

I did have a couple of hitchhikers in the buckets, my firefish and blue hippo tang who was buried in one of the rocks and I realized about 5-10 minutes later. Both made it back and are doing wonderful. Think the fish are really enjoying the new scape. I have to say, it's so much brighter now, I feel like I just upgraded my LEDs. And now with enough surface area, I have all frags mounted and I feel like I finally have a reef tank. Now hopefully everything keeps growing well. I've set my lights on an acclimation schedule so everyone has time to adjust to their new locations.

The ReefAngel managed everything like a champ. Without it, there was no way I could have pulled this off. It did take all day, but all the automation really paid off. Pics to follow...
User avatar
lnevo
Posts: 5430
Joined: Fri Jul 20, 2012 9:42 am

Re: Lee's Feature Complete PDE

Post by lnevo »

Before:
ImageUploadedByTapatalk1373254871.302274.jpg
ImageUploadedByTapatalk1373254871.302274.jpg (43.64 KiB) Viewed 5684 times
After:
ImageUploadedByTapatalk1373254891.769287.jpg
ImageUploadedByTapatalk1373254891.769287.jpg (76.12 KiB) Viewed 5684 times
ImageUploadedByTapatalk1373254904.519239.jpg
ImageUploadedByTapatalk1373254904.519239.jpg (64.01 KiB) Viewed 5684 times
User avatar
lnevo
Posts: 5430
Joined: Fri Jul 20, 2012 9:42 am

Re: Lee's Feature Complete PDE

Post by lnevo »

Close up:
ImageUploadedByTapatalk1373254946.219061.jpg
ImageUploadedByTapatalk1373254946.219061.jpg (83.48 KiB) Viewed 5683 times
rimai
Posts: 12881
Joined: Fri Mar 18, 2011 6:47 pm

Re: Lee's Feature Complete PDE

Post by rimai »

Very cool :)
Roberto.
User avatar
Sacohen
Posts: 1833
Joined: Sun Apr 21, 2013 6:25 am
Location: Davie, FL

Re: Lee's Feature Complete PDE

Post by Sacohen »

Very Nice Lee.
rossbryant1956
Posts: 471
Joined: Sat Jan 14, 2012 2:08 pm
Location: Montgomery Village, MD

Re: Lee's Feature Complete PDE - wifi alerts

Post by rossbryant1956 »

Is there a post here or elsewhere that describes how you conceptualized, designed, and built the wifi alerts? I'd like to add this to my code and just noticed this last night when I was studying your checkpower concepts. Thx
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.
User avatar
lnevo
Posts: 5430
Joined: Fri Jul 20, 2012 9:42 am

Re: Lee's Feature Complete PDE

Post by lnevo »

Is started with this thread...

http://forum.reefangel.com/viewtopic.php?p=25602#p25602

There is a standalone version you cam use in that thread, but i have one ready for inclusion in the libraries on my git if you would prefer.
rossbryant1956
Posts: 471
Joined: Sat Jan 14, 2012 2:08 pm
Location: Montgomery Village, MD

Re: Lee's Feature Complete PDE

Post by rossbryant1956 »

I am a copy\paste coder, unlike you guys doing the really cool stuff on our board. I'd prefer to use the one that will be soon in the libraries. How do I get to that?
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.
User avatar
lnevo
Posts: 5430
Joined: Fri Jul 20, 2012 9:42 am

Re: Lee's Feature Complete PDE

Post by lnevo »

Well the easiest copy paste coding is to copy the block of code in that thread, for reference heres the specific post. http://forum.reefangel.com/viewtopic.php?t=3197

It wouldn't change the code if this gets included in the libraries, most likely it would be left as a stand alone class. I think the only thing I added was the ability to force an alert regardless of timeout...which you need to use cautiously...

So, if you browse to this URL https://github.com/lnevo/Libraries/tree/wifialert and follow the Download Zip link, you can uncompressed that and copy the WiFiAlert folder to your libraries folder.

You'll then have to #include <WiFiAlert.h>
rossbryant1956
Posts: 471
Joined: Sat Jan 14, 2012 2:08 pm
Location: Montgomery Village, MD

Re: Lee's Feature Complete PDE

Post by rossbryant1956 »

Working to get WIFiAlert working and struggling. Grabbed the WiFiAlert from Git, got it installed and after making sure I dotted all my i's and crossed my t's still having problems.

Is your latest code still at the front of this post? One version of your code I have has this:

Code: Select all

 powerAlert.Send("Power+restored.",true);
and one version has

Code: Select all

ReefAngel.CustomVar[Var_Power]=0;
Which version is the most current? Appreciate all the previous help, love some more.

Finally these are my latest errors:

Code: Select all

C:\Users\owner\Documents\Arduino\libraries\WiFiAlert\WiFiAlert.cpp: In member function 'void WiFiAlert::WiFiSendAlert(char*)':
C:\Users\owner\Documents\Arduino\libraries\WiFiAlert\WiFiAlert.cpp:32: error: 'class ReefAngelClass' has no member named 'portalkey'
Again, thx
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.
User avatar
lnevo
Posts: 5430
Joined: Fri Jul 20, 2012 9:42 am

Re: Lee's Feature Complete PDE

Post by lnevo »

Oh ok yes that error you are getting was because there were other changed i forgot about it in that brach. Grab the ReefAngel directory as well.

The most recent code is on the 2nd post.
Post Reply