Libraries TODO List

Related to the development libraries, released by Curt Binder
binder
Posts: 2865
Joined: Fri Mar 18, 2011 6:20 pm
Location: Illinois
Contact:

Libraries TODO List

Post by binder »

This is where I'm going to attempt to keep a list of the items / features that I'm working on or plan to work on for my libraries.

EDIT:
This list is currently blank on here. There have been lots of additional features added and the TODO list has been changing too rapidly to keep up with on here. Features may be added here in the future but at the current time there's not much to add that I'm aware of.


If you have any ideas or suggestions, feel free to PM me or post an idea in this topic.

curt
alexwbush
Posts: 327
Joined: Tue Mar 22, 2011 12:45 am
Location: San Diego, CA

Re: Libraries TODO List

Post by alexwbush »

sounds good!

What about functions for an Android app? Or am I barking up the wrong tree?
binder
Posts: 2865
Joined: Fri Mar 18, 2011 6:20 pm
Location: Illinois
Contact:

Re: Libraries TODO List

Post by binder »

alexwbush wrote: What about functions for an Android app? Or am I barking up the wrong tree?
Most likely barking up the wrong tree. My main goal is to get a stable library base that has a good underlying API for additional clients to communicate....like the iPhone app or other clients and such. I'm not up on the mobile apps, so that may need to be in Dave's realm or somebody else's.

curt
alexwbush
Posts: 327
Joined: Tue Mar 22, 2011 12:45 am
Location: San Diego, CA

Re: Libraries TODO List

Post by alexwbush »

I knew you weren't working on the actual app, but I heard the foundation needs to be laid and it needs to be worked into the code for the android app to work just as the iphone app does.
User avatar
Xender
Posts: 105
Joined: Sun Mar 20, 2011 12:38 am
Location: France

Re: Libraries TODO List

Post by Xender »

Possibility to have timer with day of week (mond, tues, wes,....)
thx
Fresh Water Aquarium 180*60*80
Salt Water Aquarium 60*60*60
Click Here to see the Video of my Fresh Water Aquarium
Image
rygh
Posts: 21
Joined: Wed Jun 08, 2011 5:07 pm

Re: Libraries TODO List

Post by rygh »

Found a minor bug in the setup:
When you change the Chiller Temperature down, the number jumps to 999.
Going up works fine.
Version 8.5.14
binder
Posts: 2865
Joined: Fri Mar 18, 2011 6:20 pm
Location: Illinois
Contact:

Re: Libraries TODO List

Post by binder »

rygh wrote:Found a minor bug in the setup:
When you change the Chiller Temperature down, the number jumps to 999.
Going up works fine.
Version 8.5.14
Just tested it, doesn't happen on my copy of 0.8.5.14.

What is the value for your temperature?
Is it the On or the Off temperature option?
Does it happen when you first change the number or does it happen when you go below 700?
Does it happen on other screens too?

I ask these questions because the same code is used in all of the setup screens, so if there is an error with one then there is an error with all of them. Also, if your internal memory values are set outside of the range, unexpected responses can occur.

curt
rygh
Posts: 21
Joined: Wed Jun 08, 2011 5:07 pm

Re: Libraries TODO List

Post by rygh »

binder wrote:
rygh wrote:Found a minor bug in the setup:
When you change the Chiller Temperature down, the number jumps to 999.
Going up works fine.
Version 8.5.14
Just tested it, doesn't happen on my copy of 0.8.5.14.

What is the value for your temperature?
Is it the On or the Off temperature option?
Does it happen when you first change the number or does it happen when you go below 700?
Does it happen on other screens too?

I ask these questions because the same code is used in all of the setup screens, so if there is an error with one then there is an error with all of them. Also, if your internal memory values are set outside of the range, unexpected responses can occur.

curt
It was a new main board, un-initialized.
Also, I was confused because I did not realize at first it was /10. So I set it to 78, not 780.

It looks like when you are not initialized, you can go up outside your bounds, but not down.
Once it is in the 700-900 range, it stays there and up/down works as expected.
It was the same for all temp settings.
My guess: You only have the low-range check on the down button, and high-range on the up button.
Perhaps put range checks on both.
Minor.
If anything, I would add a clear decimal point on the GUI. It was pretty confusing.
rygh
Posts: 21
Joined: Wed Jun 08, 2011 5:07 pm

Re: Libraries TODO List

Post by rygh »

(I hope this is a good thread for minor notes)

Another very minor one:
For StandardHeater, you have a nice check for Temp1 = 0, and return.
But you are missing that check on StandardFan.
rimai
Posts: 12857
Joined: Fri Mar 18, 2011 6:47 pm

Re: Libraries TODO List

Post by rimai »

Keep them coming. That's what we need :)
Roberto.
rygh
Posts: 21
Joined: Wed Jun 08, 2011 5:07 pm

Re: Libraries TODO List

Post by rygh »

Ok, another un-initialize temp bug. A bit hard to explain though.
The default memory values on heater/chiller are -1. (An unfortunate coincidence)
There are two values (temp-on, tmp-off) passed into the setup gui for heat/chill.
But when the "y" value is -1, "bSingle" gets set, and it does not show on the GUI.
As such, you can only change TempOn for both heater/chiller, and never change TempOff away from -1.
Which makes heater/chiller not work properly.

I guess I should probably just use that tool to set memory to correct legal values.

Alternately, you might not want to use -1 for a flag, since it matches un-initialized memory.

Alternately, you might want to consider just having one value for heat/chill anyway.
And internally, add a small amount, say 0.5 deg or so, for hysteresis.
Less confusing for the user.
binder
Posts: 2865
Joined: Fri Mar 18, 2011 6:20 pm
Location: Illinois
Contact:

Re: Libraries TODO List

Post by binder »

My controller had the uninitialized values set to 255 when I've used it. So it's hard to say what the values will be when they are uninitialized. You can honestly only do so much (programmatically) when it's uninitialized. This is also the reason why when upgrading to the dev libraries, you are supposed to run the SetInternalMemory PDE first so the values are set properly. Otherwise if you don't, the controller will not function properly. My wavemakers toggle off and on rapidly when the value is not set.

Also, RAGen is recommended to be used to generate the PDE files with the proper settings/values to help with confusion.

Good suggestion for having 1 value for heater/chiller. The 2 values are there for helping maintain a range so the heater or chiller isn't always kicking on/off or even both on at the same time.

curt
binder
Posts: 2865
Joined: Fri Mar 18, 2011 6:20 pm
Location: Illinois
Contact:

Re: Libraries TODO List

Post by binder »

rygh wrote: Another very minor one:
For StandardHeater, you have a nice check for Temp1 = 0, and return.
But you are missing that check on StandardFan.
Fixed. Will be in next release.

curt
rimai
Posts: 12857
Joined: Fri Mar 18, 2011 6:47 pm

Re: Libraries TODO List

Post by rimai »

Bug fix:
Line 993 of ReefAngel.cpp:

Code: Select all

	Serial.println("\n\n");
Change to:

Code: Select all

    Serial.println(" HTTP/1.1\n\n");
Some web servers require that to consider requests as valid ones.
Roberto.
paulo.hanashiro
Posts: 18
Joined: Sat Mar 19, 2011 4:23 pm
Location: Sydne/Australia

Re: Libraries TODO List

Post by paulo.hanashiro »

Thanks Curt and Roberto for your updates.
rimai
Posts: 12857
Joined: Fri Mar 18, 2011 6:47 pm

Re: Libraries TODO List

Post by rimai »

My bad Curt.
After further testing, I noticed that reefangel.com server doesn't like HTTP/1.1
So, nevermind on the above bug fix. Please disregard.
But I'd like to leave it mentioned that some Unix based servers require the HTTP/1.1 to be there. So, if anyone is developing a custom script on your own web server, you may encounter problems and will need to change that.
Roberto.
binder
Posts: 2865
Joined: Fri Mar 18, 2011 6:20 pm
Location: Illinois
Contact:

Re: Libraries TODO List

Post by binder »

rimai wrote:My bad Curt.
After further testing, I noticed that reefangel.com server doesn't like HTTP/1.1
So, nevermind on the above bug fix. Please disregard.
But I'd like to leave it mentioned that some Unix based servers require the HTTP/1.1 to be there. So, if anyone is developing a custom script on your own web server, you may encounter problems and will need to change that.
haha. yeah no problem, I'll change it with 0.8.5.16. I did some reading about it and it is supposed to be there but we are omitting the host line which is part of the 1.1 specs. if you use the 1.0 specs you don't need the host line. you can try putting HTTP/1.0 instead and that should work or we have to add the full host we are requesting thus increasing size (which I really don't want to do). try that and let me know.

curt
rimai
Posts: 12857
Joined: Fri Mar 18, 2011 6:47 pm

Re: Libraries TODO List

Post by rimai »

I know 1.0 or nothing works on windows hosting of reefangel.com, but I didn't test on the linux one.
Since there is going to be very rare cases where someone will be using their own web server, let's just remove it.
Roberto.
rimai
Posts: 12857
Joined: Fri Mar 18, 2011 6:47 pm

Re: Libraries TODO List

Post by rimai »

I just realized there is one define with wrong name. It may have been my fault.
#define PWMExpansionRelay
I think the Relay word shouldn't be there.
Roberto.
binder
Posts: 2865
Joined: Fri Mar 18, 2011 6:20 pm
Location: Illinois
Contact:

Re: Libraries TODO List

Post by binder »

rimai wrote:I just realized there is one define with wrong name. It may have been my fault.
#define PWMExpansionRelay
I think the Relay word shouldn't be there.
Ok. That can be updated/changed fairly easily. I'll shift things around in the next release. :)

curt
rimai
Posts: 12857
Joined: Fri Mar 18, 2011 6:47 pm

Re: Libraries TODO List

Post by rimai »

I think DelayedOn() function should be a function of Relay class, instead of general function.
What do you think?
Roberto.
binder
Posts: 2865
Joined: Fri Mar 18, 2011 6:20 pm
Location: Illinois
Contact:

Re: Libraries TODO List

Post by binder »

rimai wrote:I think DelayedOn() function should be a function of Relay class, instead of general function.
What do you think?
I think you are right. For some reason I'm thinking there was a reason why I didn't put it in the Relay class to begin with but I can't recall the reason(s) right now.

I'll investigate moving it to the Relay class.

curt
binder
Posts: 2865
Joined: Fri Mar 18, 2011 6:20 pm
Location: Illinois
Contact:

Re: Libraries TODO List

Post by binder »

Figured things out and moved it over. In the next release, instead of saying this:

Code: Select all

ReefAngel.DelayedOn(Port1, 5);
you will say this:

Code: Select all

ReefAngel.Relay.DelayedOn(Port1, 5);
It makes more sense having it like that because we are operating on the Relay's. It was coded the "wrong" way initially due to some errors with variable sharing but those were resolved and everything is working as expected now.

curt
rimai
Posts: 12857
Joined: Fri Mar 18, 2011 6:47 pm

Re: Libraries TODO List

Post by rimai »

Hi Curt/Dave,

Would you be able to confirm this bug?
Seems to only happen with r121 though.

Send:

Code: Select all

GET /r121
Result:

Code: Select all


HTTP/1.1 200 OK
Server: ReefAngel
Cache-Control: no-store, no-cache, must-revalidate
Pragma: no-cache
Connection: close
Content-Type: text/xml
Content-Length: 495
<RA><T1>737</T1><T2>0</T2><T3>0</T3><PH>676</PH><R>248</R><RON>0</RON><ROFF>255</ROFF><R0>0</R0><RON0>2</RON0><ROFF0>255</ROFF0><R1>0</R1><RON1>0</RON1><ROFF1>255</ROFF1><R2>0</R2><RON2>0</RON2><ROFF2>255</ROFF2><R3>0</R3><RON3>0</RON3><ROFF3>255</ROFF3><R4>0</R4><RON4>0</RON4><ROFF4>255</ROFF4><R5>0</R5><RON5>0</RON5><ROFF5>255</ROFF5><R6>0</R6><RON6>0</RON6><ROFF6>255</ROFF6><R7>0</R7><RON7>0</RON7><ROFF7>255</ROFF7><ATOLOW>0</ATOLOW><ATOHIGH>0</ATOHIGH></RA>
Followed by:

Code: Select all

GET /r99
Result:

Code: Select all

HTTP/1.1 401 Access Denied
WWW-Authenticate: Basic realm=Reef Angel Controller
Content-Length: 0
Roberto.
binder
Posts: 2865
Joined: Fri Mar 18, 2011 6:20 pm
Location: Illinois
Contact:

Re: Libraries TODO List

Post by binder »

what version of the libraries are you using or did you notice this with?

curt
rimai
Posts: 12857
Joined: Fri Mar 18, 2011 6:47 pm

Re: Libraries TODO List

Post by rimai »

v0.8.5.16
Roberto.
dmolton
Posts: 182
Joined: Tue Mar 22, 2011 11:08 am

Re: Libraries TODO List

Post by dmolton »

I'm still on .15

If I follow your steps and include the trailing space after GET /r121 and GET /r99 everything works fine.. If I don't include the trailing space in the above statements I see:

Code: Select all


HTTP/1.1 200 OK
Server: ReefAng
el
Cache-Control: no-store, no-cache, must-revalidate
Pragma: no-cache
Connection: close
Content-Type: text/html
Content-Length: 24

<h1>Unknown Request</h1>
Never was able to get exactly your output, though
dmolton
Posts: 182
Joined: Tue Mar 22, 2011 11:08 am

Re: Libraries TODO List

Post by dmolton »

Just confirmed I see the same results I mentioned above on .16 as I did .15
rimai
Posts: 12857
Joined: Fri Mar 18, 2011 6:47 pm

Re: Libraries TODO List

Post by rimai »

I guess I'll just download the libs again. I may have changed something that screwed it up.
Yeah, I had to do the trailing space to get the correct stuff, but that was not the problem. It was expected to be that way.
Roberto.
rimai
Posts: 12857
Joined: Fri Mar 18, 2011 6:47 pm

Re: Libraries TODO List

Post by rimai »

I'm testing the masks of the expansion module relays of the Dev libs and the profile of relays of your Client to trigger events on the RA :)
Basically using the expansion relays as virtual on/off switches :idea: that can be turned on/off through the Client :o
Roberto.
Post Reply