Issues I've seen in the current Dev Library.

Related to the development libraries, released by Curt Binder
User avatar
lnevo
Posts: 5430
Joined: Fri Jul 20, 2012 9:42 am

Re: Issues I've seen in the current Dev Library.

Post by lnevo »

Same issue in the current libraries so I think better to keep in the previous thread.

min% may be the way to go, BUT changing the behavior may break backwards compatibility with some INO.

Overall you need a one liner to get the behavior you want..

Code: Select all

  for(int i=0;i<4;i++) { ReefAngel.PWM.SetChannel(i,0); }
phrusher
Posts: 65
Joined: Fri May 25, 2012 12:22 am

Re: Issues I've seen in the current Dev Library.

Post by phrusher »

I switched to dev for a while to try out RANet but I encountered a few issues that made me switch back. Perhaps it's a coincidence and something happened to my hardware when installing RANet or maybe it's something I should have done when switching release but I though I should report here anyway.

1. Water level (single) went cray cray on a few spontaneous occasions. Watching the reported level on my RA and it kind of jumped on what looked like a random walk.
It didn't last for very long when I noticed it but the problem was that my ATO started filling up because I'm using WaterLevelATO. On one of the occasions it emptied my ATO reserve when I was at work while jumping around.

2. I could not clear ATO or overheat either on the RA or with the Android app. Whenever I try to clear the red light turns off for fraction of a second and then back on again, stuck on "Press to clear" screen.

3. Relay overrides set are removed when exiting feeding mode. Kind of annoying having an unreliable ATO and not be able to set the relay to off permanently.
(Although after switching back I realized that the same behavior is in the stable release but now my ATO works so I don't need it so bad. After playing around a bit more I suspect that it's the ports in FeedingModePorts that are unable to keep overrides?)
rimai
Posts: 12881
Joined: Fri Mar 18, 2011 6:47 pm

Re: Issues I've seen in the current Dev Library.

Post by rimai »

Thanks for reporting your findings.
1. This is the first occasion someone is reporting this.
2. Are you sure it was an ATO or overheat and not some other flag? If it was overheat and the temperature is still above the limit, it would cause it to do just like you mentioned. Same thing for a bus lock or leak detection.
3. I'm pretty sure this has been fixed for a while and the current release has this too.
Roberto.
rimai
Posts: 12881
Joined: Fri Mar 18, 2011 6:47 pm

Re: Issues I've seen in the current Dev Library.

Post by rimai »

Regarding #3, I think you have ATO port set in the FeedingModePorts, don't you?
If so, yes, it will clear, because it applies the FeedingModePorts mask and we never store previous state of the off mask. It will keep the override for any other port that is not in the FeedingModePorts though.
Roberto.
phrusher
Posts: 65
Joined: Fri May 25, 2012 12:22 am

Re: Issues I've seen in the current Dev Library.

Post by phrusher »

rimai wrote:2. Are you sure it was an ATO or overheat and not some other flag? If it was overheat and the temperature is still above the limit, it would cause it to do just like you mentioned. Same thing for a bus lock or leak detection.
I'm not sure what flag it was. I suspected ATO because of the random levels so that's when I first noticed that I could not clear it. I had to restart my RA to exit the menu and clear the flag. The next time I encountered the issue I tried to clear overheat just to see what would happen and the same thing happened. I was stuck on "Clear overheat" and could not exit even though my temp was well below threshold.
rimai wrote:Regarding #3, I think you have ATO port set in the FeedingModePorts, don't you?
If so, yes, it will clear, because it applies the FeedingModePorts mask and we never store previous state of the off mask. It will keep the override for any other port that is not in the FeedingModePorts though.
Yes the ATO is one of the FeedingModePorts and I finally figured out that it didn't store the state on those ports. Not really the behavior I expected but now I know :)
User avatar
lnevo
Posts: 5430
Joined: Fri Jul 20, 2012 9:42 am

Re: Issues I've seen in the current Dev Library.

Post by lnevo »

Roberto,

The fix I tried to add for backward compatibility to maintain the PH calibration and Date/Time setup menu is NOT working. So this definitely needs to be revisited. Just want to throw this out there as a reminder.
rimai
Posts: 12881
Joined: Fri Mar 18, 2011 6:47 pm

Re: Issues I've seen in the current Dev Library.

Post by rimai »

Can you post the code you tested with?
Roberto.
User avatar
lnevo
Posts: 5430
Joined: Fri Jul 20, 2012 9:42 am

Re: Issues I've seen in the current Dev Library.

Post by lnevo »

void MenuEntry7() {
ReefAngel.SetupCalibratePH();
ReefAngel.DisplayedMenu = ALT_SCREEN_MODE;
}

void MenuEntry9() {
ReefAngel.SetupDateTime();
ReefAngel.DisplayedMenu = ALT_SCREEN_MODE;
}

Pretty straight forward. It compiles but when I choose those menu options I don't get the calibration screen.... now on the other hand, when I initiate the ph calibration from the Universal App, it works just fine. I'll have to play with my test unit and see if I can fix it.
rimai
Posts: 12881
Joined: Fri Mar 18, 2011 6:47 pm

Re: Issues I've seen in the current Dev Library.

Post by rimai »

I think you are missing the init of the menus.
Try this code:

Code: Select all

#include <Salinity.h>
#include <ReefAngel_Features.h>
#include <Globals.h>
#include <RA_Wifi.h>
#include <Wire.h>
#include <OneWire.h>
#include <Time.h>
#include <DS1307RTC.h>
#include <InternalEEPROM.h>
#include <RA_NokiaLCD.h>
#include <RA_ATO.h>
#include <RA_Joystick.h>
#include <LED.h>
#include <RA_TempSensor.h>
#include <Relay.h>
#include <RA_PWM.h>
#include <Timer.h>
#include <Memory.h>
#include <InternalEEPROM.h>
#include <RA_Colors.h>
#include <RA_CustomColors.h>
#include <RF.h>
#include <IO.h>
#include <ORP.h>
#include <AI.h>
#include <PH.h>
#include <WaterLevel.h>
#include <ReefAngel.h>

prog_char menu1_label[] PROGMEM = "Calibrate pH";
prog_char menu2_label[] PROGMEM = "Date/Time";
PROGMEM const char *menu_items[] = {
  menu1_label, menu2_label};

void MenuEntry1()
{
  ReefAngel.SetupCalibratePH();
}
void MenuEntry2()
{
  ReefAngel.SetupDateTime();
}

void setup()
{
  ReefAngel.Init();  
  ReefAngel.InitMenu(pgm_read_word(&(menu_items[0])),SIZE(menu_items));
}

void loop()
{
  ReefAngel.ShowInterface();
}
Roberto.
User avatar
lnevo
Posts: 5430
Joined: Fri Jul 20, 2012 9:42 am

Re: Issues I've seen in the current Dev Library.

Post by lnevo »

No, I have that in my setup already. My custom menu is work fine other than the ph and date/time which don't. I'll do some testing later this week to see what's going on.
User avatar
lnevo
Posts: 5430
Joined: Fri Jul 20, 2012 9:42 am

Re: Issues I've seen in the current Dev Library.

Post by lnevo »

The issue was this:

ReefAngel.DisplayedMenu = ALT_SCREEN_MODE;

I guess that's no longer needed... not sure how many people are using this, but was trying to avoid backward compatiblity issues. But glad my patch is OK :)
rimai
Posts: 12881
Joined: Fri Mar 18, 2011 6:47 pm

Re: Issues I've seen in the current Dev Library.

Post by rimai »

Awesome!!!
I'm going to prep for release then :)
Roberto.
User avatar
lnevo
Posts: 5430
Joined: Fri Jul 20, 2012 9:42 am

Re: Issues I've seen in the current Dev Library.

Post by lnevo »

Ok, make sure you take the pull request with functions for the phExpansion and the changelog. I'm also going to add the auto-update for SunLocation if the ActinicOffset is changed.
User avatar
lnevo
Posts: 5430
Joined: Fri Jul 20, 2012 9:42 am

Re: Issues I've seen in the current Dev Library.

Post by lnevo »

Ok all the pull requests are submitted. :)
Post Reply