Boot.py to download different bitstream

For customize purpose, we would like to download the specified bitstream which put into the sd card already, and execute some python or linux code to initial the design/IP automatically without end use connect the board via Jupyter Notebook or micro USB port.
Could we modify the boot.py to download other bitstream during the board boot and execute relative operations?

Yes, you can do this. This script runs at the end of the boot process.

Just remember this is a Python script. If some code at the start of the script gives an error, the script will stop executing.

Cathal

Provide previous experience again.

Got it. Thanks for your suggestion.

Thanks again for your great reply.
i’m fortunate to use 2.7 version. One more question about your post:
// ==================
we allow users to disable FPGA manager by setting FPGA_MANAGER_${BOARD} to 0. This may have many use cases. For example, users may want the bitstream to be downloaded at boot to enable some board components as early as possible. Another use case is that users want to enable interrupt for XRT. The side effect of this, is that users may not be able to reload a bitstream after boot.
// ==================
In my understanding, the FPGA manger = 0 should cause end user can’t download any bitstream after the board boot up. (The board can only use the default bitstream which includes in the BSP)

It seems the boot.py can out of control for the FPGA manager from your experiment:

The overlay can still be reload even setting the flag to 0.

1 Like