Device ID from DCD on Boron

boron
argon
Tags: #<Tag:0x00007fe22bd389d8> #<Tag:0x00007fe22bd38898>

#1

Hi,
Does anyone know what the DCD address is for the device id of a boron/argon. On the electron I could fetch the device id from address 3618:12 using the dfu-util app ie.

dfu-util -d 0x2B04:0xD00A -a 1 -i 0 -s 3618:12 -U deviceId.bin 

Thanks


#2

It should be at the same offset, however instead of 0xD00A for Electron (platform 10), it’s 0xD00D (13) for the USB vendor ID.


#3

Unfortunately not.

dfu-util -d 0x2B04:0xD00D -a 1 -i 0 -s 3618:12 -U deviceId.bin

Returns all 0xff’s. Maybe it’s on a different page?


#4

My guess is that it’s not filled in. The DCT copy is just a mirror of it, anyway. That’s not actually where it comes from.

I’d grab the Device ID from the USB descriptor serial number instead of using dfu-util.

https://docs.particle.io/support/particle-devices-faq/finding-device-id/#usb-serial-number-0-6-0-and-later

Or, after upgrading to a current Device OS you can use the USB API to get the device ID.


#5

Cool thanks. Will use the library instead to get the dev id.

So for those wanting this run the following from your command line, you only need to do this once

npm install particle-cli

Then

create a file called devs.js and paste the following

var usb = require('particle-usb');

async function f1() {
    const devices = await usb.getDevices();
    for (let device of devices) {
        await device.open();
        console.log(device.id);
        await device.close();
    }
}

f1();

then you can run it by executing the following

node devs

It might be worth adding it the the particle cli maybe?