Page 1 of 2

Re: RA reboots using cloud wifi

Posted: Thu Jan 19, 2017 4:23 pm
by GermanDude
Ok, cant copy and past so I will type it.
cloud wifi connected with USB-TLLcable on com 3 57600baud. As soon as i open the serial monitor I get this:

GET /r99 HTTP/1.1
Host: 73.148.165.18:2000


This repeats forever. Now I open the Uapp on the web and I get:


GET /r99 HTTP/1.1
Host: 73.148.165.18:2000

cloud:all:0 GET /r99 HTTP/1.1
Host: 73.148.165.18:2000


GET /r99 HTTP/1.1
Host: 73.148.165.18:2000


This repeats every time I open the Uapp.
Hope this helps.

Re: RA reboots using cloud wifi

Posted: Thu Jan 19, 2017 6:05 pm
by rimai
It looks good as far as the cloud command.
I do see the pings for the Client suite.
Can you turn it off and see if it makes any difference?
It should show only "cloud:all:0"
The other requests are coming from the Client suite.

Re: RA reboots using cloud wifi

Posted: Thu Jan 19, 2017 8:18 pm
by GermanDude
Do you mean the Reef Angel client suite , that runs the services in the background, by Dave Molton?

Re: RA reboots using cloud wifi

Posted: Thu Jan 19, 2017 9:21 pm
by rimai
correct.
Shut that service off and see if that makes any difference on the log and rebooting.

Re: RA reboots using cloud wifi

Posted: Fri Jan 20, 2017 5:19 pm
by GermanDude
Followed your directions and this is what I see in the serial monitor:

cloud:all:0

Still reboots RA when I connect with the Uapp.

Re: RA reboots using cloud wifi

Posted: Fri Jan 20, 2017 5:28 pm
by rimai
Ok, so let's try the other end now.
Plug the usb-ttl on RA instead of wifi attachment.
Open serial monitor at 57600 baud and make sure that you have Both CR & LF selected.
Then, send this string "cloud:all:0 ". Note that there is a space after 0.
Paste the log.
Does it reboot RA?

Re: RA reboots using cloud wifi

Posted: Fri Jan 20, 2017 6:30 pm
by GermanDude
Yes it rebooted. As a matter of fact it rebooted when I hooked up the usb to the pc, started the IDE and started the serial monitor. I received data after each reboot and after I send the cloud:all: command like this;

CLOUD:SAL:0
CLOUD:PHE:0
CLOUD:PAR:0
CLOUD:CEXP0:0
CLOUD:CEXP2:0
CLOUD:ATOLOW:1
CLOUD:BID:1
CLOUD:PWMD:100
CLOUD:PWMDO:255
CLOUD:R:251
CLOUD:ROFF:255
CLOUD:T1:766
CLOUD:PH:776

Re: RA reboots using cloud wifi

Posted: Fri Jan 20, 2017 7:17 pm
by rimai
I just can't replicate the problem :(

Re: RA reboots using cloud wifi

Posted: Fri Jan 20, 2017 7:27 pm
by rimai
The controller does reboot everytime the com port is opened. So it is normal for it to reboot when you plug cable or open serial monitor.
One thing odd in that log is the fact that it is showing SAL, PHE, PAR and other stuff that wasn't supposed to be there when you reboot RA.
This is what I get when I reboot RA with the same code:

Code: Select all

CLOUD:BID:1
CLOUD:PWMDO:255
CLOUD:PWMAO:255
CLOUD:R:235
CLOUD:ROFF:255
CLOUD:PH:438
And this is what I get when I send the cloud:all:0 command:

Code: Select all

CLOUD:ATOLOW:0
CLOUD:ATOHIGH:0
CLOUD:EM:0
CLOUD:EM1:0
CLOUD:REM:0
CLOUD:BID:1
CLOUD:AF:0
CLOUD:SF:0
CLOUD:PWMD:0
CLOUD:PWMA:0
CLOUD:PWMDO:255
CLOUD:PWMAO:255
CLOUD:R1:0
CLOUD:ROFF1:0
CLOUD:RON1:0
CLOUD:R2:0
CLOUD:ROFF2:0
CLOUD:RON2:0
CLOUD:R3:0
CLOUD:ROFF3:0
CLOUD:RON3:0
CLOUD:R4:0
CLOUD:ROFF4:0
CLOUD:RON4:0
CLOUD:R5:0
CLOUD:ROFF5:0
CLOUD:RON5:0
CLOUD:R6:0
CLOUD:ROFF6:0
CLOUD:RON6:0
CLOUD:R7:0
CLOUD:ROFF7:0
CLOUD:RON7:0
CLOUD:R8:0
CLOUD:ROFF8:0
CLOUD:RON8:0
CLOUD:ALARM:0
CLOUD:PWMD2:0
CLOUD:PWMA2:0
CLOUD:PWMD2O:0
CLOUD:PWMA2O:0
CLOUD:WL:0
CLOUD:WL1:0
CLOUD:WL2:0
CLOUD:WL3:0
CLOUD:WL4:0
CLOUD:HUM:0
CLOUD:DCM:0
CLOUD:DCS:0
CLOUD:DCD:0
CLOUD:DCT:0
CLOUD:PWME0:0
CLOUD:PWME1:0
CLOUD:PWME2:0
CLOUD:PWME3:0
CLOUD:PWME4:0
CLOUD:PWME5:0
CLOUD:PWME0O:0
CLOUD:PWME1O:0
CLOUD:PWME2O:0
CLOUD:PWME3O:0
CLOUD:PWME4O:0
CLOUD:PWME5O:0
CLOUD:AIW:0
CLOUD:AIB:0
CLOUD:AIRB:0
CLOUD:RFM:0
CLOUD:RFS:0
CLOUD:RFD:0
CLOUD:RFW:0
CLOUD:RFRB:0
CLOUD:RFR:0
CLOUD:RFG:0
CLOUD:RFB:0
CLOUD:RFI:0
CLOUD:RFWO:0
CLOUD:RFRBO:0
CLOUD:RFRO:0
CLOUD:RFGO:0
CLOUD:RFBO:0
CLOUD:RFIO:0
CLOUD:IO:0
CLOUD:LEAK:0
CLOUD:C0:0
CLOUD:C1:0
CLOUD:C2:0
CLOUD:C3:0
CLOUD:C4:0
CLOUD:C5:0
CLOUD:C6:0
CLOUD:C7:0
CLOUD:R:235
CLOUD:ROFF:255
CLOUD:RON:0
CLOUD:T1:0
CLOUD:T2:0
CLOUD:T3:0
CLOUD:PH:439
CLOUD:ORP:0
CLOUD:SAL:0
CLOUD:PHE:0
CLOUD:PAR:0
CLOUD:CEXP0:0
CLOUD:CEXP1:0
CLOUD:CEXP2:0
CLOUD:CEXP3:0
CLOUD:CEXP4:0
CLOUD:CEXP5:0
CLOUD:CEXP6:0
CLOUD:CEXP7:0

Re: RA reboots using cloud wifi

Posted: Fri Jan 20, 2017 8:15 pm
by GermanDude
Odd. I did load a new program on it tonight before I did your test. It is the same code, I just added a ATO float switch code to it.
Keep in mind that it does NOT reboot if I use the Reef Angel client or the portal. Only the web based Uapp. One more thing, I cannot connect with the standalone Uapp on my iPhone or iPad at all, only the web Uapp. Of course that reboots the controller.
Is nobody else having this problem?
I know this cloud wifi is new, so I am hoping it is a bug somewhere.

Re: RA reboots using cloud wifi

Posted: Fri Jan 20, 2017 8:21 pm
by rimai
The uapp for ios is an older release and it will not connect to the cloud server.
I'm trying to fix a few bugs before I release it a new version.
I know it doesn't reboot when you use the standard ip/port connection. It's something related to the cloud protocol, but I just can't replicate to see where it is.

Re: RA reboots using cloud wifi

Posted: Fri Jan 20, 2017 8:29 pm
by GermanDude
No problem.
Let me know if you want me to do more testing. I love this stuff ( IT guy during the day).

Re: RA reboots using cloud wifi

Posted: Sat Jan 21, 2017 5:17 am
by GermanDude
current code on my RA+

Code: Select all

#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 <Salinity.h>
#include <RF.h>
#include <IO.h>
#include <ORP.h>
#include <AI.h>
#include <PH.h>
#include <WaterLevel.h>
#include <Humidity.h>
#include <DCPump.h>
#include <PAR.h>
#include <ReefAngel.h>

////// Place global variable code below here


////// Place global variable code above here


void setup()
{
    // This must be the first line
    ReefAngel.Init();  //Initialize controller
    ReefAngel.AddStandardMenu();  // Add Standard Menu
    ReefAngel.Use2014Screen();  // Let's use 2014 Screen
    // Ports toggled in Feeding Mode
    ReefAngel.FeedingModePorts = 0;
    // Ports toggled in Water Change Mode
    ReefAngel.WaterChangePorts = Port1Bit | Port2Bit | Port3Bit | Port4Bit | Port5Bit | Port6Bit;
    // Ports turned off when Overheat temperature exceeded
    ReefAngel.OverheatShutoffPorts = Port5Bit;
    // Ports toggled when Lights On / Off menu entry selected
    ReefAngel.LightsOnPorts = 0;
    // Use T1 probe as temperature and overheat functions
    ReefAngel.TempProbe = T1_PROBE;
    ReefAngel.OverheatProbe = T1_PROBE;
    // Set the Overheat temperature setting
    InternalMemory.OverheatTemp_write( 800 );

    // Ports that are always on
    ReefAngel.Relay.On( Port1 );
    ReefAngel.Relay.On( Port2 );
    ReefAngel.Relay.On( Port4 );
    ReefAngel.Relay.On( Port6 );
    ReefAngel.Relay.On( Port7 );
    ReefAngel.Relay.On( Port8 );

    ////// Place additional initialization code below here
    
    ////// Place additional initialization code above here
}

void loop()
{
    ReefAngel.Relay.DelayedOn( Port3,2 );
    ReefAngel.StandardHeater( T1_PROBE,Port5,770,780 );
    ReefAngel.PWM.SetDaylight( PWMSlope( 20,10,23,0,50,100,5,0 ) );

    ////// Place your custom code below here
    
    //if (ReefAngel.HighATO.IsActive() ) ReefAngel.Relay.Off( Port1 );
    ReefAngel.Relay.Set(Port1,ReefAngel.LowATO.IsActive() );
    ////// Place your custom code above here

    ReefAngel.CloudPortal();
    // This should always be the last line
    ReefAngel.ShowInterface();
}



// RA_STRING1=U2FsdGVkX1+k9UBojA2Zl/cGlo+KsPGdeqVYyPkLiZ4ANu8kYtgn0na/dT0wET6s
// RA_STRING2=U2FsdGVkX19G+/qidwTF5uA/QEK9x7ZM12MiXZWqtO8=
// RA_STRING3=Dakota
Why are they two copies of #include <InternalEEPROM.h> ?

Re: RA reboots using cloud wifi

Posted: Sat Jan 21, 2017 10:41 am
by rimai
Probably an oversight I made, but it doesn't hurt any.
I still cannot replicate the problem.
Just for the hell of it, the only thing different is that I don't use the relay box to power the head unit.
Can you try that code with the controller head unit alone powered with the USB power cable and see if it reboots too?

Re: RA reboots using cloud wifi

Posted: Sat Jan 21, 2017 11:25 am
by GermanDude
Yes I can.
Water change time for my tank is tomorrow which will give me the perfect opportunity to test just the head unit.
I will return with the results.

Re: RA reboots using cloud wifi

Posted: Sat Jan 21, 2017 12:01 pm
by GermanDude
Never mind. I went ahead and tested.
RA+, Cloud Wifi , PH probe, Temp probe and 1 float switch connected. Disconnected relay box and power head unit with USB.
Opened web page to the Uapp and....head unit rebooted.
:-(

Re: RA reboots using cloud wifi

Posted: Wed Jan 25, 2017 6:32 pm
by GermanDude
I have noticed when I use the webwizard and compile code it gives me this message at the end of a succesfull compile:


Dimming Signal
Cloud Wifi Attachment
Wifi Attachment
2014 Main Screen
Extra Font - Medium Size (8x8 pixels)
Standard Menu
Standard Menu
Standard Menu
Standard Menu
===info ||| Sketch uses {0} bytes ({2}%%) of program storage space. Maximum is {1} bytes. ||| [66646 253952 26]
===info ||| Global variables use {0} bytes ({2}%%) of dynamic memory, leaving {3} bytes for local variables. Maximum is {1} bytes. ||| [3282 8192 40 4910]

Progress: 100.00%
Your code was compiled sucessfully.

Is it normal to have both the Cloud Wifi Attachment and the Wifi Attchment in the code? I only pick the Cloud Wifi Attachment from the wizard since that is what I have.

Re: RA reboots using cloud wifi

Posted: Thu Jan 26, 2017 2:50 am
by rimai
Yeah. It is normal.

Re: RA reboots using cloud wifi

Posted: Thu Jan 26, 2017 9:51 am
by GermanDude
Ok, thanks.
Were you able to find anything that would cause the rebooting of the RA yet?

Re: RA reboots using cloud wifi

Posted: Thu Jan 26, 2017 10:26 am
by rimai
Sorry, I didn't have time.
I'm in Germany in fact since last Saturday.
I'll check some more next week when I get back to USA.

Re: RA reboots using cloud wifi

Posted: Thu Jan 26, 2017 10:45 am
by GermanDude
How about that. I am from Ludwigshafen am Rhein. That is near Heidelberg.
Drink plenty of German wine. So much cheaper there.
Have fun,

Re: RA reboots using cloud wifi

Posted: Sun Jan 29, 2017 5:38 pm
by rimai
Ok, I'm back in the USA.
I think I found the problem.
Upload your code again with the web wizard and see if it works now.

Re: RA reboots using cloud wifi

Posted: Mon Jan 30, 2017 3:04 pm
by Brien H
Roberto,

I too was having this issue (corresponded with you via email). As of your post yesterday, I ran through the wizard again, and am happy to report that I am no longer having a controller reboot when accessing the uapp web app.

Thanks

Re: RA reboots using cloud wifi

Posted: Mon Jan 30, 2017 4:25 pm
by rimai
Awesome!!
Thanks for reporting back.

Re: RA reboots using cloud wifi

Posted: Mon Jan 30, 2017 5:14 pm
by GermanDude
Yup, issue fixed here too. No more rebooting.Fantastic Roberto.
The relay page however still has issues for me. The relay status stays on AUTO in the color red.

Hate to be a pain.:-)

Re: RA reboots using cloud wifi

Posted: Tue Jan 31, 2017 8:59 am
by GermanDude
Ok, here is what I noticed with the Uapp.
When I tab between the different taps and go to the relay page, the clock on top of the page stops. It seems to lock the Uapp. I exit and come back in and clock counts again. This is reproducible. All relays say AUTO and are in red. I can however change the relay to turn OFF or ON and both states show the correct color. The clock however has stopped at this point.

Hope this helps.

Re: RA reboots using cloud wifi

Posted: Tue Jan 31, 2017 9:41 am
by rimai
Thanks for the troubleshooting.
Let me see what I can find out.

Re: RA reboots using cloud wifi

Posted: Wed Feb 01, 2017 6:04 am
by GermanDude
Brien H

Hello fellow reefer.I noticed you are also in Jacksonville.
How is your Cloud Wifi working? Are you having issues with the relay page on the web uapp?

Re: RA reboots using cloud wifi

Posted: Thu Feb 02, 2017 5:39 pm
by rimai
Go to web based uapp and reload the page. Make sure to reload it with shift pressed or even better clear cache to make sure to get the latest uapp.js file.
Let me know it it shows correctly now.

Re: RA reboots using cloud wifi

Posted: Fri Feb 03, 2017 4:29 am
by GermanDude
That`s it. It is working now.
Thank you, Roberto.