Company News

Choosing GigaDevice’s GD25Q64E flash for router firmware

The flash chip in a small router has to hold enough software to get the box online again after an update. If the new firmware fails, the device may also need room to keep a working copy. GigaDevice’s GD25Q64E is a 64 Mbit serial NOR flash chip that can store boot code, firmware and settings. That capacity translates to 8 MiB. How much of it is available to the firmware depends on what the board needs to keep for recovery.

A network equipment team choosing this part has three decisions to make before laying out the board. The flash has to match the processor’s voltage, the processor has to read it from a cold boot, and the firmware has to fit the update plan. A chip can pass a programmer’s read test and still fail one of those checks once it is soldered to the board.

Start with the voltage and the exact part number

The GD25Q64E runs from 2.7 to 3.6 V. GigaDevice also lists the GD25LQ64E at the same density and advertised fast-read clock, with a 1.65 to 2.0 V supply range. The difference matters on a board whose processor has a 1.8 V flash interface. There may be a 3.3 V rail elsewhere on that board, but the engineer still has to check the electrical limits of the processor pins and the flash it will talk to.

Start with the processor’s hardware documentation, find the voltage used by its boot interface and follow that connection through the schematic. Then use the GD25Q64E datasheet’s ordering information to check the full code against the footprint and temperature grade. The family name can lead to several packages. A package substitution can require a board change even if the replacement holds the same amount of data.

SpecificationGD25Q64EWhat to check on the board
Supply voltage2.7–3.6 VCheck the voltage of the host’s flash interface and the board’s start-up conditions.
Capacity64 Mbit (8 MiB)Budget space for firmware, recovery and settings before committing to the part.
Serial interfaceSingle, dual and quad SPIMatch the flash read commands and I/O wiring to the host.
Fast-read clockUp to 133 MHzUse the timing conditions for the chosen command and operating range.
Erase sector / program page4 KiB / 256 bytesUse erase boundaries for partition planning and page boundaries when programming.

The values above come from GigaDevice’s GD25Q64E Rev 1.6 datasheet. GigaDevice also lists the part among the choices in its Wi-Fi router design guidance. That is a manufacturer application example. A finished router’s actual flash part and software layout depend on its board revision and manufacturer.

Check which read mode the processor uses at boot

SPI is the serial link between the processor and flash. The GD25Q64E supports single, dual and quad transfers. Quad SPI can carry four data bits per clock during the data phase of a supported transfer. The total transfer still includes the command, address and any required wait cycles. A 133 MHz fast-read rating gives the chip’s clock ceiling under the relevant conditions. The time from power-on to a working network also includes everything the processor and firmware do with those bytes.

Find out which command the processor’s boot ROM issues before any board software runs. Then check the GD25Q64E timing tables and whether the intended read operation depends on its Quad Enable setting. GigaDevice’s router guidance identifies its B series for designs that require Quad Enable set by default, a distinction that can matter to a processor whose first flash access assumes particular settings. A bootloader you control may be able to configure the flash later if the processor can reach it in its initial mode.

A useful prototype check starts with a complete power cycle. A development tool may leave the flash or processor in a configuration that survives a warm restart, so a successful restart can miss a problem with the cold-boot path. Verify the board can start on its own, using the programmed part and the same boot settings intended for manufacture. Measure any boot-time improvement on that hardware before using the maximum clock figure to justify a design choice.

For a board sent to a contract manufacturer, record the approved ordering code and footprint on the assembly bill of materials. Record the boot configuration and flash-programmer settings in the production instructions. A second-source part should go through the same start-up and update tests on the board even if the advertised density and supply voltage match. That gives the team a repeatable qualification procedure if the original part becomes hard to obtain during a later build.

Reserve room to recover from an interrupted update

The storage budget starts with the biggest image the update system should accept. Consider an illustrative layout with two 3 MiB firmware slots. Those slots would account for 6 MiB of the chip’s capacity, leaving 2 MiB for everything else. The real layout may also reserve space for boot code, settings, manufacturing data, update metadata and later firmware growth. Each slot can have overhead of its own. Add those requirements before putting the flash size on the bill of materials.

The ability to restore a previous image comes from the boot and update software. As one example, the open-source MCUboot design documentation describes upgrade modes that can retain an earlier image and revert after an unconfirmed test boot. It also describes modes with different storage requirements. That example shows why the update design drives the flash budget. The GD25Q64E stores the bytes, while the software decides which image can start and what happens if it fails.

The GD25Q64E erases in sectors as small as 4 KiB and programs in pages of up to 256 bytes. The erase size matters when placing two kinds of data next to each other. If the only copy of the device settings shares an erase sector with data that an update needs to replace, a power cut between erase and rewrite could cost both. Document the boundary of each region, which code is allowed to write to it, and what the bootloader should do if it finds an incomplete update.

Prove the update on the board you intend to ship

For South African prototyping teams, distributors such as Mouser South Africa list orderable suffixes. Confirm the suffix, footprint, lead time and delivered cost before choosing a production part. The history of GigaDevice’s flash business provides context for where serial NOR sits in the supplier’s wider portfolio.

The most useful acceptance test is recovering from a failed update with no programmer attached. On a test bench, interrupt power at defined stages, restore it and record which image starts, whether the settings survive and whether the unit will accept another update. Include an image close to the largest size the software permits. That result tells the team whether the 8 MiB layout leaves enough room for both a working router today and a recoverable one after the next firmware release.

Featured image: AI-generated editorial illustration by Technology Blog.