Allow download of specific revisions?

A fork of eePe. It's aim is to provide one tool that works with ALL firmwares!
Post Reply
User avatar
Kilrah
Posts: 11109
Joined: Sat Feb 18, 2012 6:56 pm
Country: Switzerland

Allow download of specific revisions?

Post by Kilrah »

Not directly a problem of mine, but once again I talked too soon, and now have no answer to a guy's problem... :D

We know Mac builds of c9x lag a bit behind the PC builds. The problem is that in c9x, the only revision of a firmware you can download is the latest.
So the guy is on Mac, downloaded the latest Mac c9x (0.76), downloaded open9x (r828) from there, and flashed. But the eeprom structure has changed between those versions, and so the documents he creates in c9x result in a "bad eeprom data" error when written to the TX.

There should be a way to download older revs, and if possible also some kind of version check (a file on the svn that c9x retrieves with the version equivalences?) so that c9x by default only offers to download the last firmware revision that corresponds to the eeprom version it can handle...

User avatar
flashbang
Posts: 59
Joined: Sat Apr 07, 2012 4:18 pm
Country: -
Location: USA NY

Re: Allow download of specific revisions?

Post by flashbang »

I agree, it would be very handy.
User avatar
GrootWitbaas
Posts: 358
Joined: Tue Dec 27, 2011 8:57 pm
Country: -
Location: Germany

Re: Allow download of specific revisions?

Post by GrootWitbaas »

my solution to this is simple, when ever I get a new rev of firmware I save it with the rev number in the end. It will be nice thou to be able to download a older rev, but for me I have all the ones I have used before.

And mac build is not far behind, I just don't always have time to build it and upload, it take a good hour or so to do it correctly and test to see it works. I have however posted easy instructions how to do it on mac.
General trouble maker and wannabee Dev
User avatar
Kilrah
Posts: 11109
Joined: Sat Feb 18, 2012 6:56 pm
Country: Switzerland

Re: Allow download of specific revisions?

Post by Kilrah »

I do the same, but in this case it's a new user. First time he comes to open9x, so obviously has no previously downloaded firmwares, and the first experience he has is a bad eeprom alert due to an incompatibility that currently has no solution but to wait for a new mac build. Due to the option system I couldn't even give him a .hex I have, as mine all have the frsky option, and even without that it would take me some time to find out which revision to give him (eeprom structure change isn't clearly mentioned in svn log, I presume it was r791 from May 15th, while the latest 0.76 c9x mac build dates from May 14th).
Romolo
9x Developer
Posts: 1109
Joined: Sat Dec 31, 2011 12:11 am
Country: -
Location: Massa (MS), Tuscany, Italy

Re: Allow download of specific revisions?

Post by Romolo »

Yes it can be done, but i need to work a little also to the reverse case, when you want to use an old version of the firmware with a newer version of companion9x.
About downloading an older release I need to find a way to do it without saving on the server but that's a minor issue..
The problem is how to make automagically make understand to companion9x which release of the firmware is on the radio..
Maybe with a flag in the write dialog window I can force companion to read the flash before writing the eeprom.

User avatar
Kilrah
Posts: 11109
Joined: Sat Feb 18, 2012 6:56 pm
Country: Switzerland

Re: Allow download of specific revisions?

Post by Kilrah »

OK, 5th case of the same problem that I see: viewtopic.php?f=44&t=920#p12387

Please at least do a mac build when EEPROM structure is changed if nothing else... For 10 days now no new open9x mac user can use C9X correctly :(
The problem is how to make automagically make understand to companion9x which release of the firmware is on the radio..
Why does this matter?
C9X reads EEPROM, sees the EEPROM version there
C9X flashes firmware, knows what version is being flashed (which is what matters)
C9X converts EEPROM to the version that is needed for the firmware it just flashed, and flashes it too
User avatar
Kilrah
Posts: 11109
Joined: Sat Feb 18, 2012 6:56 pm
Country: Switzerland

Re: Allow download of specific revisions?

Post by Kilrah »

GrootWitbaas wrote:I have however posted easy instructions how to do it on mac.
Hmm, I have a mac too (running Lion), so I just had a try at compiling c9x but without success.

I followed this, trying to complete it with this and this.
I didn't get to success, then reverted everything to try the apparently latest instructions here, but are probably outdated again:
GrootWitbaas wrote: You will need the following to build on OSX Lion
1. Xcode 4.1 (4.2.1 gives problems, but we are working on this)
2. Qt 4.8 I used the 1st dmg on here
3 xerces from here
4 xsd downloaded the binaries from here

You need to place the binaries from 3&4 in /opt/local/

next you need to check out the svn from here and run cmake, just use this code in a terminal window

Code: Select all

svn checkout http://companion9x.googlecode.com/svn/ companion9x-read-only

cd companion9x-read-only/trunk/
mkdir xcode
cd xcode
cmake -G Xcode ../src/

This fails for me (even after installing cmake which was omitted in these instructions). With just the binaries from xercesc and xsd in /opt/local/bin cmake stops with "XercesC not found! Please Set XercesC path ...". This is solved by installing xerces "properly" through macport with sudo port install xercesc. However I then get stopped by the same problem with xsd, which is exactly the same point I was blocked with the Wiki instructions...

EDIT: OK, was a little outdated again, finally found that the current findXsd.cmake is looking for the entire download of xsd-3.3.0-i686-macosx in /opt/local:

Code: Select all

FIND_PATH( XSD_INCLUDE_DIR xsd/cxx/parser/elements.hxx
  "/opt/local/xsd-3.3.0-i686-macosx/libxsd"
[...]
 
Got a local build working now (without xcode with a simple make) :D
Now to get Xcode to work and make me a dmg, for some reason it doesn't manage to invoke cmake...
User avatar
Kilrah
Posts: 11109
Joined: Sat Feb 18, 2012 6:56 pm
Country: Switzerland

Re: Allow download of specific revisions?

Post by Kilrah »

Argh. That was painful, but I am now able to build C9X for mac. One last thing, I have the dmg with C9X executable, but no idea how to make the pkg with avrdude and all. So until someone tells me how to, I can only provide an "Upgrade" dmg, a first time user would have to install an older pkg once to get avrdude, and then replace the C9X app with the new one.

I have a dmg for V0.81 (r1086) I could supply.
jha03
Posts: 1
Joined: Tue May 22, 2012 8:40 am
Country: -

Re: Allow download of specific revisions?

Post by jha03 »

Super :)

Merci
Romolo
9x Developer
Posts: 1109
Joined: Sat Dec 31, 2011 12:11 am
Country: -
Location: Massa (MS), Tuscany, Italy

Re: Allow download of specific revisions?

Post by Romolo »

Anyway newer version of c9x will be enabled to write also to older version of firmware by reading first the firmware present on the radio.
So you will be able to write even to an old one, in case you do not want to update the fw (please explain me why)
Download of older firmware still not enabled, it will force us to maintain a lot of fw version, so I do not know if we will do.
User avatar
ShowMaster
Posts: 4327
Joined: Thu Dec 29, 2011 3:44 am
Country: -
Location: Los Angeles, CA USA

Re: Allow download of specific revisions?

Post by ShowMaster »

Maybe last 5 FW's let's say. That way of there are errors in a new version not seen before latest update going back would be an option. Maybe last 3 even? I save all older versions but have only gone back a few just to verify that tne newer one has an issue. I myself, have never gone back many times but when I did it was only a few versions older.
SM
Romolo
9x Developer
Posts: 1109
Joined: Sat Dec 31, 2011 12:11 am
Country: -
Location: Massa (MS), Tuscany, Italy

Re: Allow download of specific revisions?

Post by Romolo »

ShowMaster wrote:Maybe last 5 FW's let's say. That way of there are errors in a new version not seen before latest update going back would be an option. Maybe last 3 even? I save all older versions but have only gone back a few just to verify that tne newer one has an issue. I myself, have never gone back many times but when I did it was only a few versions older.
SM
I will see what I can do....
There are at least several issues in implementing this feature:
In companion we need to remember options by release:
On server we need to do the same...
I still do not say no... but let me think about it.

And what about automatically backing up the firmware before writing ?
User avatar
Kilrah
Posts: 11109
Joined: Sat Feb 18, 2012 6:56 pm
Country: Switzerland

Re: Allow download of specific revisions?

Post by Kilrah »

Romolo wrote:And what about automatically backing up the firmware before writing ?
Won't help new users who flash for the first time...
Romolo
9x Developer
Posts: 1109
Joined: Sat Dec 31, 2011 12:11 am
Country: -
Location: Massa (MS), Tuscany, Italy

Re: Allow download of specific revisions?

Post by Romolo »

Kilrah wrote:
Romolo wrote:And what about automatically backing up the firmware before writing ?
Won't help new users who flash for the first time...
I think we need to divide the problem in several parts:

1) Companion version alignment with open9x on all platform (i know someone is working on it ;) )
2) Rollback to previous releases
2bis) Download of previous versions
3) Companion compatibility and writing to radio flashed with older releases.

By solving 1) we will solve also issue with users downloading first time.
to solve 2) a local backup well help, to solve 2bis) a lot needs to be done in companion9x/compilation server and need to be maintained...
Issue 3) should be solved now.

Maybe I can setup something on server to allow to generate a older release by use of a web page.

Did i forgot something ?
User avatar
Kilrah
Posts: 11109
Joined: Sat Feb 18, 2012 6:56 pm
Country: Switzerland

Re: Allow download of specific revisions?

Post by Kilrah »

Romolo wrote:By solving 1) we will solve also issue with users downloading first time.
Working on it indeed, but even if we are 2 you can be sure Murphy's law will make sure we're both unavailable for a week just when there's a new eeprom structure ;)
Romolo wrote:Issue 3) should be solved now.
Awesome :D
Romolo wrote:Maybe I can setup something on server to allow to generate a older release by use of a web page.
Great idea! No explicit support in C9X = you can get them, but you're on your own :)
User avatar
ShowMaster
Posts: 4327
Joined: Thu Dec 29, 2011 3:44 am
Country: -
Location: Los Angeles, CA USA

Re: Allow download of specific revisions?

Post by ShowMaster »

Ok for me.
SM
User avatar
GrootWitbaas
Posts: 358
Joined: Tue Dec 27, 2011 8:57 pm
Country: -
Location: Germany

Re: Allow download of specific revisions?

Post by GrootWitbaas »

so I have been away for some time ....sry life happens .... now about the dmg and pkg creation ...I have to take down the steps I use and I will post them hopefully in the next day or two ...about the instructions ....I could have missed something, but last time I followed it on a clean install all worked ...but again I am no dev and sometimes use what works for me (and not always the correct way)
If I did not update this post by Monday ....spam me with pm's and email to remind me please :D

Groot (yes still alive and kicking)
General trouble maker and wannabee Dev
User avatar
Kilrah
Posts: 11109
Joined: Sat Feb 18, 2012 6:56 pm
Country: Switzerland

Re: Allow download of specific revisions?

Post by Kilrah »

OK, great!
I've been building and supplying the app in a .dmg for "manual updates" in the meantime. Works fine, but the pkg would be cleaner ;)
User avatar
GrootWitbaas
Posts: 358
Joined: Tue Dec 27, 2011 8:57 pm
Country: -
Location: Germany

Re: Allow download of specific revisions?

Post by GrootWitbaas »

A so now I know who was building some updates .... nice ...:D
For the PKG I just used some free program, will check later tonight (If work load permits I will actually do a full build just to have all steps used in order)
General trouble maker and wannabee Dev

Post Reply

Return to “companion9x”