FPGA DNA 获取

FPGA DNA

DNA 是 FPGA 芯片的唯一标识, FPGA 都有一个独特的 ID ,也就是 Device DNA ,这个 ID 相当于我们的身份证,在 FPGA 芯片生产的时候就已经固定在芯片的 eFuse 寄存器中,具有不可修改的属性。在 xilinx 7series 和 7series 以前,ID 都是 57bit
的,但是在 Xilinx 的 Ultraslace 架构下是 96bit 。

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 0 to 56 of the 64-bit FUSE_DNA value. External applications can access the Device DNA or FUSE_DNA values through the JTAG port, and FPGA designs can access the DNA only through a Device DNA Access Port (DNA_PORT).

意思是说JTAG可以拿到57bit的DNA_PORT和64 bit的FUZE_DNA,DNA_PORT值最多会有32个器件有相同的值,FUZE_DNA就是唯一的。而如果要通过FPGA资源区读取,只能用DNA_PORT,也就是说你写逻辑的话得用57bit的DNA_PORT。

如何读取

JTAG

可以使用 JTAG 查看当前 FPGA 的 DNA 码。

其中 FUSE_DNA 即为我们要获取的 DNA 编码信息,copy 即可。

代码获取

调用DNA_PORT实现。https://fpga.eetrend.com/files-eetrend-xilinx/download/201408/7594-13761-ug4707seriesconfig.pdf

         DNA_PORT #(
            .SIM_DNA_VALUE(57'h123456789abcdef)  // Specifies a sample 57-bit DNA value for simulation
         )
         DNA_PORT_inst (
            .DOUT(dna_dout),   // 1-bit output: DNA output data.
            .CLK(sys_clk),     // 1-bit input: Clock input.
            .DIN(1'b0),     // 1-bit input: User data input pin.
            .READ(dna_read),   // 1-bit input: Active high load DNA, active low read input.
            .SHIFT(dna_shift)  // 1-bit input: Active high shift enable input.
         );

使用DNA_PORT获取的DNA和JTAG读取的DNA对比

参考
AMD Customer Community JTAG 获取 DNA

  • 7
    点赞
  • 3
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值