This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

TM4C123BH6ZRB: Unique Serial number?

Part Number: TM4C123BH6ZRB


Hi!

Is there an unique serial number on each microcontroller?

User Manual points me to deviceID registers "SYSCTLDID 0/1 ("Each microcontroller is uniquiely identified by the combined values of the CLASS field in DID0 Register and the PARTNO field in the DID1 register").

But they all show identical content on different TIVAs:-(

Regards,

Tobi

  • user4295749 said:
    Is there an unique serial number on each microcontroller?

    No, there is not.

    There are a few possible solutions for that - several sensors and communication devices come with an UID, and could be used for identifying your board. If none of those in your project do, or if you want to implement something "universal" for all your projects, you may want to select an IC just for that purpose.

    We use a low cost I2C eeprom from Atmel, with a unique 128-bit serial number, AT24 something.

    Regards

    Bruno

  • Ok.
    Thanks Bruno!
  • Bruno Saraiva said:
    We use a low cost I2C eeprom from Atmel, with a unique 128-bit serial number, AT24 something.

    For some projects, even this might be "too expensive", if the EEPROM is not used for something else.

    A common alternative is to embed an ID in the Flash (Code section) on a known address, and initialise it to zero.

    Then, the firmware file (HEX, SREC, BIN) is patched at that address for each part with a number right before programming.

  • f. m. said:
    For some projects, even this might be "too expensive"

    Sure. There is never a perfect solution in product design...

    These IC's cost ~$0.20 a piece - and require basically no additional components around it except for the pull-ups. I believe that any product "important enough to deserve a unique serial number" should be able to afford such extra cost.

    Your solution is good if the mission is to obtain some sort of "internal serial number". There is no guarantee that a board is seen uniquely if this patch is missed, reset, improperly done, etc. Still, if such is acceptable, then I'd suggest a bit more of a complicated solution - assuming that the product has some sort of communication to the outer world - a fresh product would trigger a central server ID request, a once-in-a-lifetime process that allocates the ID. And maybe "the firmware doesn't allow the full product to function if such number ain't valid", preventing that "copies" of the board are somehow sent to the market.

    In fact, one of our boards uses a combination of both: it has a unique hardware ID, and there is a "automatic registration" process that stores such address to our server when the board is first run - which later, allows a complex product tracking. Big brother?

  • Bruno Saraiva said:
    These IC's cost ~$0.20 a piece - and require basically no additional components around it except for the pull-ups. I believe that any product "important enough to deserve a unique serial number" should be able to afford such extra cost.

    The last remark is certainly true. I have seen hour-long meetings about 1 or 2 cents, but concerning devices with quantities of > 100k p.a. A Cortex M4 like the TM4C is usually not used in such devices.

    But there is another problem. During production, there is no firmware yet, and JTAG or ROM bootloaders do not have routines to write arbitrary values over serial busses, with arbitrary addresses (in case of I2C).

    That leaves you again with patching the HEX file, and write the ID during first MCU startup.

    Actually, I have seen this method in use at several occasions, once  for ROM-based MAC addresses. And, retrieval of the unique ID/number is usually associated with a database transaction (fetch, and mark as used).