# Update the bootloader


> Fix a Raspberry Pi 4 stuck on a white screen or a Pi 5 on a blinking cursor by updating the EEPROM bootloader, using the Raspberry Pi Imager or the terminal.
A Raspberry Pi 4 stuck on a white screen, or a Raspberry Pi 5 showing a black screen with a blinking cursor, usually has an out-of-date bootloader rather than a bad image.

The bootloader lives in the EEPROM on the board itself, not on the SD card, so rewriting the ScreenlyOS image does not change it. It has to be updated separately, once per device.

This applies only to the Raspberry Pi 4 and Raspberry Pi 5.

## With Raspberry Pi Imager

Use this if you have a spare SD card and another computer. It writes a small update tool to the card, which the Pi runs once at boot.

1. Download [Raspberry Pi Imager](https://www.raspberrypi.org/software/) and open it.
2. Click **Choose Device** and select your model, Raspberry Pi 4 or Raspberry Pi 5.

    {{< picture src="assets/images/docs/screenlyos/eeprom-imager-choose-device.webp" alt="Raspberry Pi Imager with the device selection open, showing the Raspberry Pi 4 and Raspberry Pi 5 options" >}}

3. Under **Choose OS**, select **Misc utility images**.

    {{< picture src="assets/images/docs/screenlyos/eeprom-imager-misc-utility-images.webp" alt="The operating system list in Raspberry Pi Imager with Misc utility images highlighted" >}}

4. Select **Bootloader**, for the Pi 4 or Pi 5 family to match your device.

    {{< picture src="assets/images/docs/screenlyos/eeprom-imager-bootloader.webp" alt="The Misc utility images list in Raspberry Pi Imager with the Bootloader option selected" >}}

5. Choose **SD Card Boot**.

    {{< picture src="assets/images/docs/screenlyos/eeprom-imager-sd-card-boot.webp" alt="Raspberry Pi Imager showing the boot mode options with SD Card Boot selected" >}}

6. Under **Choose Storage**, select your SD card, then click **Write**.
7. Put the card into the powered-off Raspberry Pi and turn it on.
8. Wait at least ten seconds. A steadily blinking green activity LED and a green screen on the display mean the update worked.
9. Power the Pi off and take the card out.

Now write ScreenlyOS to the card as usual. See [Write the image](/docs/screenlyos/hardware/raspberry-pi/guides/write-the-image/).

## From the terminal

Use this if you have no second SD card, or you would rather work on the device itself.

1. Write the latest 64-bit Raspberry Pi OS to a card with Raspberry Pi Imager.
2. Put the card in the Pi, boot it, and complete the first-run setup.
3. Open a terminal and check for an update:

    ```bash
    sudo rpi-eeprom-update
    ```

    If one is available, the output names the current and latest versions:

    ```text
    *** UPDATE AVAILABLE ***
    BOOTLOADER: update available
    CURRENT: Tue Apr 26 10:24:28 UTC 2022
    LATEST: Wed Jan 11 17:40:52 UTC 2023
    ```

4. Install it:

    ```bash
    sudo rpi-eeprom-update -a
    ```

Once it finishes, write ScreenlyOS to a card and continue with [Write the image](/docs/screenlyos/hardware/raspberry-pi/guides/write-the-image/).

> [!NOTE]
> The bootloader update is stored on the board, so you only do this once per device. A Pi that has been updated keeps the new bootloader through every later ScreenlyOS reinstall.