Search The Inn

Thursday, July 8, 2021

Reverting To Previous Digitrax Firmware Versions (Updated 2021-08-09)

The following is from a discussion on the groups.io Digitrax Users Forum concerning the updating of the UR93 firmware. The answers are provided by billybob experimenter who is a frequent guest poster on the Hostlers Inn. This is excellent information but is filled with "technobabble" so be prepared.

On 4/15/2021 8:44AM, Ross Kudlick wrote:

I suggest you check your UR93 and update if it doesn’t have the latest firmware.

Billybob replied:

All these firmware versions report the same version information in DigiIPLII's "Find Devices" tool. As such, there is no convenient way for a user to differentiate between firmware from February, March, or April of this year (or previous releases!).

What to do? If you have a UR93 with "unknown" firmware version, I recommend that you update the UR93 using the latest firmware from the Digitrax "Downloads" web page, and then mark the new firmware's filename on a sticker and attach that sticker to the UR93.

But how do you prevent older revisions from overwriting a newer revision you already have on your device?

The ability to "revert" firmware versions was available with DT402-series throttles and DigiIPL.exe, and was, in a couple of cases, very important when a rather "buggy" DT402-series throttle firmware release got "into the wild".

I investigated DigiIPL many years ago and discovered many things about the Digitrax firmware update process.  Unfortunately, much of this is "technobabble".  If you don't like technobabble, the remainder of this message is not for you!

The investigations I did many years ago, long before DigiIPLII.exe existed, revealed these things:

KEY FINDING

A firmware update would be "allowed" if the "major portion" of the version number of the firmware currently installed on the device was less than or equal to the "major portion" of the version number of the firmware-to-be-installed; you cannot "revert" to a firmware file with a "major portion" number that is less than the "major portion" number of the firmware already installed in the device.

Figuring out a device's installed firmware's Version number

A firmware update would be "allowed" if the "major portion" of the version number of the firmware currently installed on the device was less than or equal to the "major portion" of the version number of the firmware-to-be-installed; you cannot "revert" to a firmware file with a "major portion" number that is less than the "major portion" number of the firmware already installed in the device.

  • that the device makes the decision to accept or ignore the firmware update based on the "major portion" of the version number, without any extra help from DigiIPL
  • that the device does not provide any sort of feedback to DigiIPL, whether accepting or ignoring the firmware update process
  • that the device that accepts a firmware update does not provide any sort of feedback to DigiIPL about the success or failure of the update process

As described above, a key part of the process is the "major portion" of the version number.  What is the "major portion" of version number, you might ask?

There are two parts to this, what is the "major portion" of the version number of a given firmware file, and what is the "major portion" of the version number of the firmware installed on a device. I will handle them in this order, as the first part is easier to explain.

Figuring out the firmware's Version number

Unfortunately, you cannot rely upon Digitrax to give you the "version number" information.  For various reasons, the version numbers reported on the "Downloads" page of the Digitrax web site sometimes do not match the version numbering in the firmware file. Luckily, one can easily determine the actual version number, and from that, the "major portion" of that version number, using the DigiIPLII program. This is a fairly easy part!

Start DigiIPLII. In DigiIPLII, "Open" the firmware file for which you wish to find the "major" version.  Look about in the center of the DigiIPLII window and find the reported "SWVer" number.  Take that number and divide by 8.  The result gives the "major portion" to the left of the decimal point, and the "minor" portion to the right of the decimal. To get the major number, it is simply a case of ignoring all of the digits to the right of the decimal point of the result of the division! Note that the "major portion" of the firmware file's version number can be 0.

As an example: The most-recent DT402 firmware file (10-16-2016), DigiIPLII.exe reports "SWVer 17" when loaded into DigiIPLII.  Take the (decimal) number 17, divide by 8, and get a result of 2.125.  Ignore every digit to the right of the decimal point, to get a major portion of "2".

In extreme technobabble, Digitrax seems to define their version numbering as "major" number and "minor" number.  They encode this information into a (7-bit?) value which combines the two into a single number.  The "major" number is the upper (4?) bits of that (7-bit?) number, and the "minor" number is the least-significant 3 bits of that (7-bit?) number.

But you do not (necessarily) need to worry about that extreme technobabble.  Often, but not always, you can retrieve the version number, or even the "major portion" of the version number, directly from the device itself:

  • The DCS52, DT602-series, and UT6-series throttles all report Version number, Subversion number and date code as part of their power-up display sequence.  For our purposes, only the Version number is important, and the "Major" portion of the version is the portion that is to the left of the decimal point of the reported Version number.
  • DT402-series and DT500-series throttles report the version number directly, in the first second or two of the power-up display.  The version number shows up as a pair of digits on the right-hand end of the same line as the device type display, such as "DT402D21" or "DT500 01". For these devices, the "major" revision is the left of the pair of version digits, so for the examples, the DT402D had major revision 2, and the DT500 had major revision 0.

Recent (firmware-updatable) command stations and recent (firmware-updatable) boosters may report their version number information via a DT500-series throttle using the "Query Mode".  This is not a particularly reliable mechanism because of idiosyncrasies of the Query Mode process, and it can be difficult to get the desired device when there is more than one "query-mode-capable" device on LocoNet.  If you can use Query Mode to get to the "SWver" display, and it is for the desired device, and it is showing non-zero data for other aspects of the device, then the "major portion" is the number between "SWver" and the decimal point.  For example, "SWver0.1" has a major revision of 0.

If you cannot get a LocoNet device to display the version information, and you cannot get it via "Query Mode", you can try to get the info via DigiIPL/DigiIPLII's "Find Devices" feature.  If the "Find Devices" feature finds the device you are interested in, then the "major portion" is that portion of the "S/W" number that is to the left of the ".".

Some Digitrax devices do not have a display and do not respond to the "Find Devices" request, so there is no (known to me) way to retrieve the firmware version information.  I have not stumbled upon the trick for determining the firmware version information for the LNRP that I have in my collection.

Summary

If you have real version numbers (not the confusing junk found on the web site!) for the firmware in the device and for the firmware you wish to install, compare the "major portion" of the version numbers.  You can install a given firmware file if the firmware file you are attempting to apply has a major portion number which is equal to or greater than the major portion of the firmware version number that is already in the device.

One can easily try "reverting" a device's firmware if one has "collected" the various firmware files that have been released on the Digitrax web site.  It is my expectation that the basic rule described in the preceding paragraph will hold true.

Regards,

Billybob

<Update 2021-08-09>

The following information was provided by Lynn Grandle of the Digitrax-users.groups.io forum in response to this post:

"I can tell you from personal experience that you can load an old version of firmware in at least a UR92 if you have bricked them.  They are setting in the IPL state and have no clue as to their last firmware version.  I too was in the computer industry for more years that I want to count -- laboratory hardware and software development( both the software and hardware).

I also agree that if you want to load an older version of the firmware, that starting with the first firmware load and going forward is the best way to do it. 

But from what I have seen so far in loading firmware I do that think that the Digitrax loader is an incremental( patch) loader --- i.e. it appears to want a complete package not patches.  I also believe that there is a bug in their loading code that has a problem checking the firmware version that it is loading, if it actually does the check as stated in the web post (Author's Note - meaning this post).  I suspect that reloading the same version of firmware on a working Digitrax device will brick it.  I bricked at least 3 UR92 that way. Just some observations, from personal experience.  Actually, unbricked them by loading older versions of the software.  Then they upgraded correctly."

Thanks to Lynn for this additional information.


If you have an idea for a blog post here, let me know. If I can comment on it, I will or I'll see if someone else can and post it

No comments:

Post a Comment