Trouble with library update utility

Community contributed apps
Post Reply
psyrob
Posts: 247
Joined: Thu Sep 01, 2011 8:44 pm

Trouble with library update utility

Post by psyrob »

Roberto:

When I run the update utility, it says that I have the most recent library, 8.18, but the client software still says I am using development libraries from two versions ago, 8.16, or however those numbers go....where does the utility load the libraries to?

Thanks
Image
wolfador
Posts: 241
Joined: Sun Sep 04, 2011 9:59 am
Location: Pittsburgh, PA

Re: Trouble with library update utility

Post by wolfador »

The libraries are only uploaded to the RA when you reload your .pde file. Just open the arduino software and your saved .pde and reload it to the controller. This will update your controller to the latest version.
John
ReefAngel and ReefAngel-HD developer
If the RA iOS app has helped please consider a donation
Image
psyrob
Posts: 247
Joined: Thu Sep 01, 2011 8:44 pm

Re: Trouble with library update utility

Post by psyrob »

Thanks John...I have the reefangel controller connected to a different computer than the one I set it up on...I first tried moving the pde file from my old computer to the new one, but it wouldn't upload. I generated a new pde file in RAGen, but it won't upload either...

I can't cut and past the error message, but it says something like

"avrdude: stk500_disable(): protocol error, expect 0x14, resp=0x51"


This is the PDE file
// Autogenerated file by RAGen (v1.0.4.92), (10/11/2011 21:40)
// RA_101111_2140.pde
//
// This version designed for v0.8.5 Beta 12 or later

/* The following features are enabled for this PDE File: 
#define DisplayImages
#define WavemakerSetup
#define DateTimeSetup
#define VersionMenu
#define ATOSetup
#define MetalHalideSetup
#define DirectTempSensor
#define StandardLightSetup
*/


#include <ReefAngel_Features.h>
#include <ReefAngel_Globals.h>
#include <ReefAngel_Wifi.h>
#include <Wire.h>
#include <OneWire.h>
#include <Time.h>
#include <DS1307RTC.h>
#include <ReefAngel_EEPROM.h>
#include <ReefAngel_NokiaLCD.h>
#include <ReefAngel_ATO.h>
#include <ReefAngel_Joystick.h>
#include <ReefAngel_LED.h>
#include <ReefAngel_TempSensor.h>
#include <ReefAngel_Relay.h>
#include <ReefAngel_PWM.h>
#include <ReefAngel_Timer.h>
#include <ReefAngel_Memory.h>
#include <ReefAngel.h>


void setup()
{
    ReefAngel.Init();  //Initialize controller

    ReefAngel.FeedingModePorts = B00011000;
    ReefAngel.LightsOnPorts = B00000111;
}

void loop()
{
    ReefAngel.ShowInterface();

    // Specific functions
    ReefAngel.StandardATO(Port1);
    ReefAngel.StandardLights(Port2);
    ReefAngel.MHLights(Port3);
    ReefAngel.Wavemaker1(Port4);
    ReefAngel.Wavemaker2(Port5);
    ReefAngel.StandardFan(Port6);
    ReefAngel.StandardHeater(Port7);
    ReefAngel.StandardLights(Port8);
}

Image
rimai
Posts: 12881
Joined: Fri Mar 18, 2011 6:47 pm

Re: Trouble with library update utility

Post by rimai »

I think the computer that gives you error message has the wrong board selected.
Can you check under "Tools->Boards" if you have "Reef Angel Controller w/optiboot" selected?
Roberto.
psyrob
Posts: 247
Joined: Thu Sep 01, 2011 8:44 pm

Re: Trouble with library update utility

Post by psyrob »

Yes, optiboot is selected. When I scroll up above the error message, I do see a line that says "using com 3" or whatever, and I know thru the client that I use COM 4...that is the com that the USB is connected to to controller. I tried changing that on the client dash service to com 3, but the pde file still wouldn't upload and the client software couldn't connect either...I also knew to stop the listener service before trying to upload, but that didn't allow the upload either...I then went to "Tools: Serial Port" and changed it to com 4, but again I got the same error message as above with different numbers....still can't upload
Image
rimai
Posts: 12881
Joined: Fri Mar 18, 2011 6:47 pm

Re: Trouble with library update utility

Post by rimai »

Does it happen only on one computer and not on the other?
Roberto.
psyrob
Posts: 247
Joined: Thu Sep 01, 2011 8:44 pm

Re: Trouble with library update utility

Post by psyrob »

havent tried with the other computer, the screen died on that laptop...
Image
rimai
Posts: 12881
Joined: Fri Mar 18, 2011 6:47 pm

Re: Trouble with library update utility

Post by rimai »

But before it died, if I understood correctly, you were able to upload code in that computer with no problems, right?
Roberto.
psyrob
Posts: 247
Joined: Thu Sep 01, 2011 8:44 pm

Re: Trouble with library update utility

Post by psyrob »

that's right
Image
rimai
Posts: 12881
Joined: Fri Mar 18, 2011 6:47 pm

Re: Trouble with library update utility

Post by rimai »

Can you post a screen shot of your device manager window?
Plug the USB-TTL cable and go to "Control Panel->System->Device Manager" and then expand the "COM & LPT Ports".
Roberto.
psyrob
Posts: 247
Joined: Thu Sep 01, 2011 8:44 pm

Re: Trouble with library update utility

Post by psyrob »

screen shot.JPG
screen shot.JPG (38.53 KiB) Viewed 5808 times
here
Image
psyrob
Posts: 247
Joined: Thu Sep 01, 2011 8:44 pm

Re: Trouble with library update utility

Post by psyrob »

Oh, and now the red status light is staying on steady on the controller...
Image
rimai
Posts: 12881
Joined: Fri Mar 18, 2011 6:47 pm

Re: Trouble with library update utility

Post by rimai »

Yes, you should definitely use COM4.
Just to make sure that the port is setup properly, double-click "USB Serial Port (COM4)", select the tab "Port Settings" and click the button "Advanced".
Is "Set RTS On Close" checked?
The red led status is an indication of ATO timeout or overheat.
Roberto.
psyrob
Posts: 247
Joined: Thu Sep 01, 2011 8:44 pm

Re: Trouble with library update utility

Post by psyrob »

Yes the port is correctly set up, the box is checked under advanced settings and I am using port 4...still can't upload...

I can't copy and paste the error, but in the middle is says something like "not in synch"
then later is the line about expecting one number but getting another...
Image
rimai
Posts: 12881
Joined: Fri Mar 18, 2011 6:47 pm

Re: Trouble with library update utility

Post by rimai »

Does the controller reboot after a few seconds from when you click the upload button?
You can copy the error by selecting everything and pressing CTRL+C on the keyboard.
Roberto.
psyrob
Posts: 247
Joined: Thu Sep 01, 2011 8:44 pm

Re: Trouble with library update utility

Post by psyrob »

I'm at work now and can't cut and paste, but I got the pde file to upload and on the controller, I see the development libraries are now current.

However, now I can't get the Client software to communicate with the controller...the listener service says connected but no data is coming in ...I tried re-booting several times (this has fixed this type of problem before) but no dice...I went into my Library and the Reef Angel.Features.h file to see if wifi was commented out, but there is no line in that file that has Wifi commented out....

I thought I should try and create a new pde, but now RAGen won't start!!!! Whenever I try and start RAGen, I get an error message from Windows (this machine runs XP). I tried uninstalling RAGen and reinstalling the latest version, but again, every time I start RAGen, I get the Windows error message...So, I can't run RAGen and can't get the client software to communicate with the controller...Help!!
Image
rimai
Posts: 12881
Joined: Fri Mar 18, 2011 6:47 pm

Re: Trouble with library update utility

Post by rimai »

Can you copy and paste the ReefAngel_Features.h file?
I can look at it and make sure you got the correct stuff.
Can you also try the static version of RAGen and check if it works?
https://github.com/downloads/curtbinder ... static.zip
Roberto.
psyrob
Posts: 247
Joined: Thu Sep 01, 2011 8:44 pm

Re: Trouble with library update utility

Post by psyrob »

Here is the features file from the libraries:


// AutoGenerated file by RAGen (v1.0.4.92), (10/11/2011 21:40)

/*
* Copyright 2010 / Curt Binder
*
* Licensed under the Apache License, Version 2.0 (the "License")
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/


#ifndef __REEFANGEL_FEATURES_H__
#define __REEFANGEL_FEATURES_H__


#define DisplayImages
#define WavemakerSetup
#define DateTimeSetup
#define VersionMenu
#define ATOSetup
#define MetalHalideSetup
#define DirectTempSensor
#define StandardLightSetup


#endif // __REEFANGEL_FEATURES_H__
Image
psyrob
Posts: 247
Joined: Thu Sep 01, 2011 8:44 pm

Re: Trouble with library update utility

Post by psyrob »

Also, I could run the static RAGen, but it wouldn't generate code, it said there was an unknown error...
Image
rimai
Posts: 12881
Joined: Fri Mar 18, 2011 6:47 pm

Re: Trouble with library update utility

Post by rimai »

Try using this, just copy and paste over the entire file contents

Code: Select all


#ifndef __REEFANGEL_FEATURES_H__
#define __REEFANGEL_FEATURES_H__

#define SIMPLE_MENU
#define wifi
#define VersionMenu

#endif  // __REEFANGEL_FEATURES_H__
Roberto.
psyrob
Posts: 247
Joined: Thu Sep 01, 2011 8:44 pm

Re: Trouble with library update utility

Post by psyrob »

and then what? i have pasted this in the library in the Reef angelfeature.h file...I can't generate code with RAGen, what is next/
Image
rimai
Posts: 12881
Joined: Fri Mar 18, 2011 6:47 pm

Re: Trouble with library update utility

Post by rimai »

Oh, just upload the code you paste in the beginning of the thread.
Isn't that the code you were trying to upload?
Roberto.
psyrob
Posts: 247
Joined: Thu Sep 01, 2011 8:44 pm

Re: Trouble with library update utility

Post by psyrob »

I was able to finally get the libraries updated to the controller, that was what I was trying to upload...but since I uploaded the most recent version of the libraries (which is on the controller as v 8.5.18) I cant run RAGen and the client software wont communicate with the controller...
I saw this thread
http://forum.reefangel.com/viewtopic.php?f=8&t=339
should I delete everything and reinstall?
Image
psyrob
Posts: 247
Joined: Thu Sep 01, 2011 8:44 pm

Re: Trouble with library update utility

Post by psyrob »

Thanks Roberto...
Image
Post Reply