Update 12th Feb

User avatar
YT5HOK
Posts: 123
Joined: Sat Nov 16, 2019 11:36 am
Location: Belgrade, KN04FR

Re: Update 12th Feb

Post by YT5HOK » Fri Feb 14, 2020 9:21 am

VK3KYY wrote:
Fri Feb 14, 2020 3:58 am
kd2lh wrote:
Fri Feb 14, 2020 3:14 am
Hi Roger,

The last version that works is:

[ a0f4440 ]

The version that fails is:

[ 5e2bc47 ]
OK.

Thanks.

I'll see what has changed
One thing related to this... When we go up in versions, sometimes settings get reset cause of changes. IIRC you made some settings version, which triggers reset when number goes up. But what if number goes down? Shouldn't there be a reset of settings too? Asking cause I think we had at least one settings reset between mentioned versions.
Marko

VK3KYY
Posts: 1656
Joined: Sat Nov 16, 2019 3:25 am
Location: Melbourne, Australia
Contact:

Re: Update 12th Feb

Post by VK3KYY » Fri Feb 14, 2020 11:33 am

The github numbers do not increase they are GUID is actually a much larger alphanumeric text

5e2bc47 is the short form of

5e2bc4730a658317b40c5ea0fef911e1a8a52353

Settings only get reset when there is a change to the settings, normally to add a new setting, or occasionally to reorganise the settings memory.

When a new setting is added, the settings memory in the EEPROM has to be initialised with the default value for the new setting, otherwise the new setting would have whatever random junk was in the memory when it was read from the EEPROM.

The easiest way to do this is for us to run the factory reset code which resets all settings, as its not practical to know what new settings have been added when a user updates from any older version , which could have far less settings in it.

kt4lh
Posts: 67
Joined: Sun Jan 12, 2020 4:27 am

Re: Update 12th Feb

Post by kt4lh » Fri Feb 14, 2020 1:25 pm

VK3KYY wrote:
Fri Feb 14, 2020 11:33 am
Settings only get reset when there is a change to the settings, normally to add a new setting, or occasionally to reorganise the settings memory.
How does it know when it needs to reset, a magic number I believe, but how does it know the old one vs new one? I think he was asking that if you upgrade to a new version it sometimes wipes settings, but does a downgraade do the same. I'd think it would, but I've never had to downgrade myself.

User avatar
kd2lh
Posts: 183
Joined: Mon Dec 02, 2019 2:44 pm

Re: Update 12th Feb

Post by kd2lh » Fri Feb 14, 2020 1:41 pm

I've seen firmware upgrades lose settings (like the OPTION / MMDVM setting) and had to manually set it again after upgrading firmware in the GD-77.

I don't know how the code it actually structured, but there usually is a section where the variables associated with settings are stored. Sometimes firmware rewrites restructure that area, so the mapping of the old variables doesn't match their new locations.

I just assume that I need to go through and verify any important settings after I do an updgrade.

Marc KD2LH

User avatar
F1RMB
Posts: 412
Joined: Sat Nov 16, 2019 5:42 am
Location: Grenoble, France
Contact:

Re: Update 12th Feb

Post by F1RMB » Fri Feb 14, 2020 1:58 pm

Hi,

The magic number is located at the beginning of the settings, and it's just compared to the current firmware settings version.
If it doesn't match, default settings are applied. A settings versioning management would take too much code and memory space, and would be unmanageable with current speed development.

It's, IMHO, a small price to pay, and at a given time, that won't happen that often.


Cheers.
---
Daniel
73 de Daniel.

User avatar
YT5HOK
Posts: 123
Joined: Sat Nov 16, 2019 11:36 am
Location: Belgrade, KN04FR

Re: Update 12th Feb

Post by YT5HOK » Fri Feb 14, 2020 4:44 pm

kt4lh wrote:
Fri Feb 14, 2020 1:25 pm
How does it know when it needs to reset, a magic number I believe, but how does it know the old one vs new one? I think he was asking that if you upgrade to a new version it sometimes wipes settings, but does a downgraade do the same. I'd think it would, but I've never had to downgrade myself.
Yes, that was what I was asking, but was busy with work, so I didn't respond sooner. Thank you!

F1RMB wrote:
Fri Feb 14, 2020 1:58 pm
Hi,

The magic number is located at the beginning of the settings, and it's just compared to the current firmware settings version.
If it doesn't match, default settings are applied. A settings versioning management would take too much code and memory space, and would be unmanageable with current speed development.

It's, IMHO, a small price to pay, and at a given time, that won't happen that often.


Cheers.
---
Daniel
Of course. Thank you!
Marko

Post Reply