Flash FAT file system to eMMC for Booting

Microchip in-system programming solution: SAM-BA

Moderators: nferre, fab

PeterT
Posts: 14
Joined: Tue Jun 21, 2016 12:03 am

Flash FAT file system to eMMC for Booting

Tue Jun 21, 2016 6:44 pm

I understand the requirements to boot from SDMMC (FAT FS on first user partition with BOOT.BIN), but how can I set up that FAT file system on an eMMC device? Is there perhaps a tool to create a binary from a FAT FS (I know of a tool to do this with an EXT2 FS) then use SAM-BA to flash the binary to the eMMC?
blue_z
Location: USA
Posts: 1549
Joined: Thu Apr 19, 2007 10:15 pm

Re: Flash FAT file system to eMMC for Booting

Wed Jun 22, 2016 9:25 pm

PeterT wrote:I understand the requirements to boot from SDMMC (FAT FS on first user partition with BOOT.BIN), but how can I set up that FAT file system on an eMMC device?
Since AT91Bootstrap seems to treat the eMMC as a SDcard, there is no "user partition".
You would need to treat the device as a MS-DOS mass-storage device with a MBR/partition-table in the first sector, and a VFAT filesystem in the first primary partition.

If you build and then boot from a SDcard a Linux system with an initramfs, then you could use any Linux tool you want.

Regards
Last edited by blue_z on Wed Jun 22, 2016 9:30 pm, edited 1 time in total.
PeterT
Posts: 14
Joined: Tue Jun 21, 2016 12:03 am

Re: Flash FAT file system to eMMC for Booting

Wed Jun 22, 2016 9:30 pm

So is it not possible to make the eMMC bootable without using an SD card for the first bringup?
blue_z
Location: USA
Posts: 1549
Joined: Thu Apr 19, 2007 10:15 pm

Re: Flash FAT file system to eMMC for Booting

Wed Jun 22, 2016 9:36 pm

PeterT wrote:So is it not possible to make the eMMC bootable without using an SD card for the first bringup?
I didn't write anything close to that.
PeterT
Posts: 14
Joined: Tue Jun 21, 2016 12:03 am

Re: Flash FAT file system to eMMC for Booting

Wed Jun 22, 2016 9:43 pm

I obviously failed to properly specify that in my question. I'm thinking about when my design reaches production and wondering if I can accomplish the first bring-up by flashing the FAT FS containing BOOT.BIN directly to the eMMC with SAM-BA through USB instead of relying on an SD card.
blue_z
Location: USA
Posts: 1549
Joined: Thu Apr 19, 2007 10:15 pm

Re: Flash FAT file system to eMMC for Booting

Thu Jun 23, 2016 8:34 pm

PeterT wrote:I'm thinking about when my design reaches production and wondering if I can accomplish the first bring-up by flashing the FAT FS containing BOOT.BIN directly to the eMMC with SAM-BA through USB instead of relying on an SD card.
Writing the filesystem makes no sense without writing a MBR partition table.
You need an image file that begins with the first sector of the device rather than the first sector of the partition/filesystem.
Build that image using Linux tools by booting from SDcard.

IMO SAM-BA is (typically) useless with non-Atmel eval boards. "Production" boards rarely have CS jumpers/switches that allow reliable execution of the SAM-BA Monitor, although some of the latest SoCs now have a boot configuration register.

Regards

Return to “SAM-BA”

Who is online

Users browsing this forum: No registered users and 2 guests