Determining the version of system firmware on a Photon/P1

Hi @mdma

I want to determine the version of the system firmware. I'm trying to follow this instruction from above on a Mac. I have my Photon blinking yellow, however the device /dev/tty.usbmodem641 does not exist. That device normally comes and goes when the Photon reboots. It is created when the Photon enters blinky green, Firmware Reset. It isn't created when it enters blinky yellow.

Any help? Anyone else have this problem?

You need to be in setup mode - please see the 2nd line of the instructions - there's also a link showing you how to do it. Cheers!

1 Like

Got it. I misread the instructions. My bad. Thanks.

1 Like

Your instructions are absolutely correct, however in my defense I'd like to point out that the page that link takes me to does not mention setup mode, it mentions "Listening Mode". I take it these two terms are synonyms? That's what threw me.

My output is different than the above. I used the serial communication in the ParticleDev environment. I got this:

[
  {
    "d": [], 
    "f": "b", 
    "l": "m", 
    "n": "0", 
    "s": 16384, 
    "v": 2, 
    "vc": 30, 
    "vv": 28
  }, 
  {
    "d": [], 
    "l": "m", 
    "s": 262144, 
    "vc": 30, 
    "vv": 0
  }, 
  {
    "d": [
      {
        "_": "", 
        "f": "s", 
        "n": "1", 
        "v": 3
      }
    ], 
    "f": "s", 
    "l": "m", 
    "n": "2", 
    "s": 262144, 
    "v": 3, 
    "vc": 30, 
    "vv": 30
  }, 
  {
    "d": [
      {
        "_": "", 
        "f": "s", 
        "n": "2", 
        "v": 1
      }
    ], 
    "f": "u", 
    "l": "m", 
    "n": "1", 
    "s": 131072, 
    "u": "0102030405060708090A0B0C0D0E0F101112131415161718191A1B1C1D1E1F20", 
    "v": 2, 
    "vc": 30, 
    "vv": 30
  }, 
  {
    "d": [
      {
        "_": "", 
        "f": "s", 
        "n": "2", 
        "v": 1
      }
    ], 
    "f": "u", 
    "l": "f", 
    "n": "1", 
    "s": 131072, 
    "u": "00F0CBFF5549554800F0C7FF5549554800F0C3FF5549554800F0BFFF55495548", 
    "v": 2, 
    "vc": 30, 
    "vv": 30
  }
]

Is the s value the part that indicates what the entry corresponds to? I’m not sure how to read this from my Photon. Do I have old system firmware or newer?

According to BDub:

if you get a “f”:“s” followed immediately a couple characters away by “v”:“3”, that would indicated 0.4.3-rc2.

FYI, as of 0.4.4 (AKA version ‘5’), the new ‘v’ command in setup/listen mode will show the human readable version number (e.g., “system firmware version: 0.4.4”).

Is there a way to access the firmware version number in user software? We’re loading firmware v0.4.4 onto 500 photons, and from experience, we see a couple percent of the photons fail to load both firmware files.
Currently, I have a shell script that loads both parts of the firmware and the user binary in sequence, like this:

load firmware part 1 and stay in dfu-mode
wait 1 second
load firmware part 2 and stay in dfu-mode
wait 1 second
load user-space binary file and exit dfu

in my user-space program, I’d like to do a check to see if the system firmware version is in fact 0.4.4, and turn the photon’s LED on if everything loaded OK. This will help us QA that last couple percent of failures.

Any idea how to do this?

I'm not quite sure I understand this part. In setup mode, connected to my computer (mac), what do I need to do? If I type particle setup into terminal then I get the whole setup script, there doesn't seem to be a place where I can type 'v' or 's'.

Why not include this feature to particle in CLI?

Like particle version

I was thinking the same thing, but rather than particle version, add the info to particle list

1 Like

In that case, please remove the e[2Ke[1G garbage out of the output or include a clean option

particle list > list.txt gives

e[2Ke[1G. Retrieving devices...e[2Ke[1Go Retrieving devices...e[2Ke[1GO Retrieving devices...e[2Ke[1G@ Retrieving devices...e[2Ke[1G* Retrieving devices...e[2Ke[1G. Retrieving devices...e[2Ke[1Go Retrieving devices...e[2Ke[1Ge[2Ke[1G. Retrieving device functions and variables...e[2Ke[1Go Retrieving device functions and variables...e[2Ke[1GO Retrieving device functions and variables...e[2Ke[1G@ Retrieving device functions and variables...e[2Ke[1G* Retrieving device functions and variables...e[2Ke[1G. Retrieving device functions and variables...e[2Ke[1Go Retrieving device functions and variables...e[2Ke[1G
myPhoton [12345678123456781234567812345678] (Photon) is online

1 Like

Hi,
My vote is for this to be visible from user code (as well as CLI ??) - then we can simply read it remotely and publish or do whatever we need to :-))

Thanks
Graham

1 Like

Any updates on this? Has anyone done this sort of thing.
Running up against the same issues A @enjrolas, batch flashing units and not being sure about whether part1 goes through before flashing part2 has resulted in bricked units.
From my experience many units in the field operate in locations with bad WiFi and updates often fail, and can never make it back, even with the safe mode healer.

System.version() or System.versionNumber().

1 Like

Just thought I’d mention that the more recent firmware gives more readable output:

[Hit 'v']

system firmware version: 0.4.9

Cheers,

When I connect my P1 which was purchased a while ago, the putty output is when I enter s:
modular: no

And nothing happens when v is entered.

When I use CLI with particle identify I get:

Unable to determine system firmware version```

Any ideas what the modular: no is?

You could try particle serial inspect to get more info out.

But you might want to perform particle update first, since when this is a factory default P1, I think it doesn’t have the modular but the monolitic firmware installed.

I tired the particle serial inspect but got the below error

C:\Users\Steve>particle serial inspect

! serial: SyntaxError: Unexpected token m```

I currently do not have easy access to get the P1 into DFU mode for the particle update

Your P1 is running manufacturing firmware pre-0.4.0 - let it connect to the cloud and it should update to a more recent firmware revision (0.4.5.) All P1’s and Photons should be running 0.4.9 or later before using the device updater.