cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
ngrubaugh
Observer
Observer
10,138 Views
Registered: ‎07-30-2015

Petalinux-package creating download.bit file?

I am currently trying to build the final boot.bin file to run petalinux on an FPGA and I have successfully run through petalinux-build. Now I just need to run the petalinux-package command to generate the boot.bin and uImage right? I ran:

 

petalinux-package --boot --format MCS --fpga path/to/bit --u-boot --kernel

WARNING: Auto detecting MMI file with HDF

INFO: Creating download.bit

....

INFO: Output download.bit: /home/folder/Petalinux_Proj2/images/linux/download.bit

ERROR: offset of bitstream "/home/folder/Petalinux_Proj2/images/linux/download.bit" is not specified.

 

2 questions:

 

1. Why is it creating a .bit file and not the specified .mcs file?

2. What is the offset of bitstream error message refering to?

0 Kudos
Reply
10 Replies
achutha
Xilinx Employee
Xilinx Employee
10,124 Views
Registered: ‎07-01-2010

@ngrubaugh

 

 

What version of petalinux are you using?

Are you trying to generate MCS file or boot.bin file?

 

Generate Boot Image for MicroBlaze
1. Execute the following command to generate MCS boot file for MicroBlaze.
$ petalinux-package --boot --fpga <FPGA bitstream> --u-boot --kernel
It will generate boot.mcs in your working directory and it will be copied to the <proj>/images/linux/
directory. With the above command, the MCS file contains fpga bit, fs-boot, u-boot and kernel image image.ub.
2. Command to generate .mcs file with fs-boot and fpga only:
$ petalinux-package --boot --fpga <FPGA bitstream>
3. Command to generate .mcs file with fpga, fs-boot and u-boot:
$ petalinux-package --boot --fpga <FPGA bitstream> --u-boot

 

If you would like to generate the boot.bin for Zynq  use the below command

$ petalinux-package --boot --fsbl <FSBL image> --fpga <FPGA bitstream> --u-boot

 

-Achutha

---------------------------------------------------------------------------------------------
Kindly note- Please mark the Answer as "Accept as solution" if information provided is helpful.

Give Kudos to a post which you think is helpful and reply oriented.
----------------------------------------------------------------------------------------
0 Kudos
Reply
ngrubaugh
Observer
Observer
10,115 Views
Registered: ‎07-30-2015

@achutha,

 

I am using Petalinux 2015.2 along with Vivado 2015.2 tools. I have followed the steps outlined in UG1144 exactly in regards to the petalinux-package command to create the MCS file for a Microblaze, as you outlined as well, but still receive the error in my original message.

0 Kudos
Reply
achutha
Xilinx Employee
Xilinx Employee
10,112 Views
Registered: ‎07-01-2010

@ngrubaugh

 

Please share the hdf file so that i can verify the details.

 

-Achutha

---------------------------------------------------------------------------------------------
Kindly note- Please mark the Answer as "Accept as solution" if information provided is helpful.

Give Kudos to a post which you think is helpful and reply oriented.
----------------------------------------------------------------------------------------
0 Kudos
Reply
ngrubaugh
Observer
Observer
10,107 Views
Registered: ‎07-30-2015

@achutha,

 

I included both .hdf files that were located in the SDK folder. I did try running through the petalinux tools with both but received the same error both times.

0 Kudos
Reply
andrei_hres
Visitor
Visitor
8,282 Views
Registered: ‎06-18-2015

Hi ngrubaugh!

I have same problem, have you resolved it?

0 Kudos
Reply
ngrubaugh
Observer
Observer
8,278 Views
Registered: ‎07-30-2015

@andrei_hres :

 

If I recall correctly the .MCS file wasn't being generated because of the bitstream error I was getting, so they were related to each other. The petalinux-package command requries you to specify the flash size if you are going to be writing to the flash because it can't correctly figure out the size itself. So you just need to add the "--flash-size" command with the correct MB specified.

0 Kudos
Reply
andrei_hres
Visitor
Visitor
8,256 Views
Registered: ‎06-18-2015

Hi.

I have found that need define correct offset for files and every thing works. Like this:

petalinux-package --boot \
--format MCS \
--force \
--fpga images/linux/htg_v7_g3.bit \
--offset 0x000000 \
--fsbl images/linux/fs-boot.elf \
--u-boot images/linux/u-boot.elf \
--offset 0x800000 \
--kernel images/linux/image.elf \
--offset 0xA00000 \
--flash-size 128 \
--flash-intf BPIx16 \
--output firmware_test_01.mcs

Without offset definition I get error like in the first post.

ngrubaugh
Observer
Observer
8,248 Views
Registered: ‎07-30-2015

@andrei_hres

 

Ah, yeah that would do it as well. I remember defining those within the petalinux tools themselves.

 

Glad you figured it out!

0 Kudos
Reply
adrian.n
Observer
Observer
3,407 Views
Registered: ‎12-12-2017

Hi andrei_hres,

Where did you find documentation for the correct offsets? I have the same problem as ngrubaugh when trying to build a bootable .bit file for a Genesys2 board. When I try explicitly defining the petalinux-package commands as in your post, I get the following error:

 

ERROR: [Writecfgmem 68-3] Bitstream at address 0x00800000 conflicts with bitstream at address 0x00000000.

 

I am guessing this is because the offsets are wrong, but I can't find information in either UG1144 or UG1157 on what these offsets should be.

 

0 Kudos
Reply
whatevert002
Newbie
Newbie
970 Views
Registered: ‎11-05-2019

Hey @adrian.n, It's been quite some time since you commented, but I was wondering if you came around solving this issue. I, too, cannot figure out the correct offset addresses and am facing the same error 

  • ERROR: [Writecfgmem 68-3] Bitstream at address 0x00800000 conflicts with bitstream at address 0x00000000.
0 Kudos
Reply