Flasher - eMMC and SD-card programming
This article describes step-by-step, how to program eMMC and SD-cards with a pre-configured file system using Flasher in-system programmers.
Overview
Many products rely on eMMC or SD-cards and require an initial data set with a FAT or exFAT file system (such as emFile) to be written directly during production.
The Storage Image Creator streamlines this process by generating a ready-to-use image that can be programmed in‑system.
Together with the Flasher, the production workflow can be significantly simplified.
After completing the initial setup described in this article, a new SD-card or eMMC device can be programmed with a single press of a button.
The process is structured in in two simple steps: Image generation and production programming:
Required materials
The required setup for programming eMMC or SD-cards is as follows. All you need is:
- Any Flasher programmer. Get an overview of the available models here: Flasher models.
- A target device that has an eMMC or SD-card.
- The Storage Image Creator.
- A custom flashloader
- This can be requested from SEGGER,
- or developed using the J-Link DSK.
Preparation
Project setup
- Set up a File System Image
- To learn how to set up a file system image, refer to the following article: Creating an eMMC image using Storage Image Creator (it is recommended to export a Motorola S-record file).
- Save a copy of the created file in a convenient location for use in the upcoming steps.
- Add your custom flashloader to the DLL as described in the following documentation: J-Link Device Support.
- Connect your Flasher to your PC via USB or Ethernet.
- Preparing for usage with J-Flash.
- Select your target device and configure it.
- Open the section with the eMMC or SD-Card you want to program.
- Drag and drop your created data file to the J-Flash project.
- Go to Edit → Relocate and enter an offset equal to the Base address of your eMMC or SD-card.
- Go to File → Show files on Flasher and remove any files on your flasher.
- Go to File → Download config and data File to Flasher.
- Go to File → Show files on Flasher and verify both files are on the Flasher. If not, save any changes to the project and reopen it. Then retry the previous step.
- (Optional) Save your project.
- Your Flasher is now ready to be used in standalone mode.
Hardware setup
For the hardware setup, we are using a sample board that supports both SD-cards and eMMC devices. Please note that the target you are using may differ from this example; however, the general setup should be similar regardless of the target board or memory device.
Start by powering your target if necessary.
In this example, the target is powered via USB.
Next, prepare the memory device for programming. Here, the eMMC (right side) is connected.
If you intend to program an SD-card instead, simply insert the SD-card into the target board (bottom left in the image).
Finally, connect your prepared Flasher to the target board using a suitable adapter.
Production programming
Before starting production programming, the basic setup will always follow the steps in Preparation. If you encounter any problems, please double-check the previous steps.
Programming an SD-card
With the preparation complete, programming an SD-card only needs the following steps.
- Insert the SD-card into your target device.
- Trigger the programming job on the Flasher
- either by using the PROG button,
- or any of the methods described in Flasher Automation.
- Wait for the programming job to finish. (When the LED Ready / OK is permanently green).
- Either eject the now programmed SD-card or switch out the target device, depending on your use case.
- Repeat steps 1-4.
Programming an eMMC
With the preparation complete, programming an eMMC is very similar to programming an SD-card.
- Depending on whether your eMMC is removable, connect it to the target device or connect a new target with the already installed eMMC.
- Trigger the programming job on the Flasher
- either by using the PROG button,
- or any of the methods described in Flasher Automation.
- Wait for the programming job to finish. (When the LED Ready / OK is permanently green).
- Either disconnect the now programmed eMMC or remove the target device, depending on your use case.
- Repeat steps 1-4.
Process automation
For usage in production programming, the preparation steps can also be automated.
The mentioned tools (Storage Image Creator and J-Flash) both support operation via the command line.
This allows you to automatically update both your file system image and Flasher — for example, in a CI/CD pipeline.