Community
cancel
Showing results for 
Search instead for 
Did you mean: 

Internal Host Partial Reconfiguration Using Flash

Internal Host Partial Reconfiguration Using Flash



This is a PR example design developed on Stratix V FPGA Dev Kit using ACDS 13.1.

  • Internal host with bitstreams in Flash
  • Static region:
  • Nios II program PR bitstream into external flash
  • One PR region containing 2 personas:
  • Persona 1: Green LED scrolling
  • Persona 2: Red LED scrolling

Media:internal_pr.zip 

Out of Box Experience

  • The attached design is ready with compiled sof file and rbf file for each persona, if you want to hands on directly, skip to program the sof and flash. If you recompile the design, you might want to regenerate the updated rbf for the persona:

To generate the .rbf file, you can use the Nios command shell or in Quartus (File -> Convert Programming Files)


  • Generate .pmsf file from .sof and .msf files

quartus_cpf -p output_files/s5gxea7_fpga_bup.x3y5.msf output_files/s5gxea7_fpga_bup.sof output_files/base.pmsf

quartus_cpf -p output_files/pr_0.x3y5.msf output_files/pr_0.sof output_files/reconfig.pmsf


  • Generate .rbf files from .pmsf files

quartus_cpf -c output_files/base.pmsf output_files/base.rbf

quartus_cpf -c output_files/reconfig.pmsf output_files/reconfig.rbf


  • Convert .rbf files to .flash files

bin2flash --input=output_files/base.rbf --output=output_files/base.flash --location=0x021C0000

bin2flash --input=output_files/reconfig.rbf --output=output_files/reconfig.flash --location=0x023C0000


  • Program the sof into the board

nios2-configure-sof output_files/s5gxea7_fpga_bup.sof


  • Program the flash before you run the partial reconfiguration. Use Nios Command Shell:

nios2-flash-programmer --base=0x0 --program output_files/base.flash

nios2-flash-programmer --base=0x0 --program output_files/reconfig.flash


  • Select the persona using dip_switch[0], then press button (PB2) to start the PR

0x0: Persona 1: Green LEDs scrolling

0x1: Persona 2: Red LEDs scrolling


  • Other LEDs:

LED7: blinking to show static region is running during PR process

Attachments
Version history
Revision #:
1 of 1
Last update:
‎06-21-2019 07:24 PM
Updated by:
 
Contributors