0
\$\begingroup\$

Is there a reasonable way to identify different boards with the same parts through JTAG? I have a family of boards that all have the same Zynq CPU but various hardware configurations. I'd like to be able to identify each board in some way such that I can prevent flashing of mismatched builds to the boards, even if the software on the boards is inoperative (can't just query the board over a different interface).

I'm aware that most parts have an IDCODE instruction but it appears to just be a manufacturer ID + part ID + part rev so all of my boards would have the same ID in this case. Would it make sense to write info to an untouched flash address and read it back before programming or something similar?

\$\endgroup\$
1
  • \$\begingroup\$ Load a special bit of firmware that is compatible with all boards. That firmware should interrogate the hardware configurations (various) and that interrogated information should be used to decide the final firmware upload. \$\endgroup\$
    – Andy aka
    Dec 11, 2021 at 6:41

2 Answers 2

1
\$\begingroup\$

There is no provision in JTAG standard for uniquely identifying chip instances. Even for identifying chip types, IDCODE is optional.

Now you are talking about Zynq. Zynq has two TAPs, with two different (but constant across chip instances) IDCODES. One of them is for PL. PL TAP has various registers, among which there is DNA.

From UG470:

The 7 series FPGA contains an embedded, 64-bit device identifier which is used to provide a 57-bit Device DNA value. The identifier is nonvolatile, permanently programmed by Xilinx into the FPGA, and is unchangeable making it tamper resistant. Each device is programmed with a 57-bit DNA value that is most often unique. However, up to 32 devices within the family can contain the same DNA value. The JTAG FUSE_DNA command can be used to read the entire 64-bit value that is always unique. Device DNA is composed of bits 63 to 7 of the 64-bit FUSE_DNA value.

Use FUSE_DNA (IR=0x32) or XSC_DNA (IR=0x17).

Note: I assumed you are talking about Zynq-70xx, IIRC, it is the same for ZU+.

\$\endgroup\$
0
\$\begingroup\$

The FUSE_DNA: Unique Device DNA section of the Vivado Design Suite User Guide: Programming and Debugging (UG908) describes obtaining the REGISTER.EFUSE.FUSE_DNA TCL property to read the FUSE_DNA over JTAG when using Vivado.

Also found Xilinx Get EFUSE DNA Device ID: vivado -mode batch -source get_dna.tcl which is a gist containing get_dna.tcl which can be run using Vivado -batch mode from the command line. With Vivado 2023.1 tested get_dna.tcl on a sample of xc7k160t and xc7a200t devices and the DNA value was reported. This could be possibly used from a script to protect against flashing an incompatible design, assuming you keep a list of different DNA values for each type of design.

E.g. have two different development boards using a xc7k160t and was wondering while a design didn't enumerate on the PCIe bus only to release I was loading the bitstream into the wrong board and the Vivado Hardware Manager didn't realise since both boards use the same device and therefore IDCODE.

On a related note, 67513 - 7 Series, UltraScale and UltraScale+ and newer products - How can I get device info based on 2D Barcode or Device DNA? describes how to lookup the device information using the device DNA. This should be useful to verify the device speed grade if using a board with a heatsink installed over the device. When trying to lookup the device information for some xc7k160t and xc7a200t devices got the error:

No data found, please contact your FAE for assistance.

There is the note on the article which probably explains the failure to lookup the device information:

Please note that DNA information is only available for UltraScale+ (16nm) and newer families starting from the date code 1837.

\$\endgroup\$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.