KU FPGA FLASH boot失败debug
原因
新板子回来后,测试flash 烧录正常,但是无法BOOT,此时SPI设置为X4模式,使用内部时钟,速度90M。烧录过程不报错,校验也正常。
FLASH理论支持最大速度108M,90M应该还好。另外板卡预留了EMCCLK外部时钟模式,速率100M 也不可行。
此时约束如下:
set_property CONFIG_VOLTAGE 3.3 [current_design]
set_property CFGBVS VCCO [current_design]
set_property BITSTREAM.CONFIG.SPI_BUSWIDTH 4 [current_design]
set_property CONFIG_MODE SPIx4 [current_design]
set_property BITSTREAM.CONFIG.CONFIGRATE 90 [current_design]
#set_property BITSTREAM.CONFIG.EXTMASTERCCLK_EN div-1 [current_design]
set_property BITSTREAM.GENERAL.COMPRESS TRUE [current_design]
set_property BITSTREAM.CONFIG.UNUSEDPIN Pullup [current_design]
分析
90M偏高,尝试降低速率尝试。实际多次测试发现82M以下均正常。不同的器件支持的速度是有差异的,具体参考UG908 https://www.xilinx.com/support/documents/sw_manuals/xilinx2022_1/ug908-vivado-programming-debugging.pdf
SPIX8 模式
实际为了加快boot速度,硬件上支持SPIX8模式,这样实际速度可以提高到原有速度的2倍,从而加快启动过程。这在一些pice 应用上是必要的。
set_property CONFIG_VOLTAGE 3.3 [current_design]
set_property CFGBVS VCCO [current_design]
set_property BITSTREAM.CONFIG.SPI_BUSWIDTH 8 [current_design]
set_property CONFIG_MODE SPIx8 [current_design]
set_property BITSTREAM.CONFIG.CONFIGRATE 82 [current_design]
#set_property BITSTREAM.CONFIG.EXTMASTERCCLK_EN div-1 [current_design]
set_property BITSTREAM.GENERAL.COMPRESS TRUE [current_design]
set_property BITSTREAM.CONFIG.UNUSEDPIN Pullup [current_design]
实际生成下载固件的时候会有2个 bin文件,对应按照提示下载即可。
如果不做multiboot,生成bin文件时候的使用方式和SPIX4没有什么差异。
cd [get_property DIRECTORY [current_project]]/[current_project].runs/impl_1
write_cfgmem -format bin -size 32 -interface SPIx8 -loadbit "up 0x00000000 [get_property top [current_fileset]].bit" -file [get_property DIRECTORY [current_project]]/test.bin -force
【推荐】编程新体验,更懂你的AI,立即体验豆包MarsCode编程助手
【推荐】凌霞软件回馈社区,博客园 & 1Panel & Halo 联合会员上线
【推荐】抖音旗下AI助手豆包,你的智能百科全书,全免费不限次数
【推荐】博客园社区专享云产品让利特惠,阿里云新客6.5折上折
【推荐】轻量又高性能的 SSH 工具 IShell:AI 加持,快人一步
· DeepSeek “源神”启动!「GitHub 热点速览」
· 微软正式发布.NET 10 Preview 1:开启下一代开发框架新篇章
· C# 集成 DeepSeek 模型实现 AI 私有化(本地部署与 API 调用教程)
· DeepSeek R1 简明指南:架构、训练、本地部署及硬件要求
· 2 本地部署DeepSeek模型构建本地知识库+联网搜索详细步骤