# Raspberry Pi

{% embed url="<https://youtu.be/DKgI4VWSGUM?si=eChZLV6MoFySbS5z>" %}

{% hint style="info" %}
Models with smaller memory (RAM) may counter performance issues. A **Raspberry Pi with at least 4GB of memory is recommended.**

If you do not have a Raspberry Pi, consider the [virtual machine](/getting-started/quickstart/virtual-machine/virtualbox.md) installation.

Alternatively, [purchase an iHost](https://sonoff.tech/products/sonoff-ihost-smart-home-hub/58) shipped with CUBE OS from the SONOFF website or Amazon if neither option is feasible.
{% endhint %}

## 1. Preparation

{% stepper %}
{% step %}
Visit this [repo](https://github.com/eWeLinkCUBE/CUBE-OS/releases/) to download the latest image.
{% endstep %}

{% step %}
Obtain a [Raspberry Pi](https://amzn.to/2S0Gcl1) and get it ready following the Raspberry Pi official [guides](https://www.raspberrypi.com/documentation/computers/getting-started.html) if you have a kit like the enclosure and cooling fan.
{% endstep %}

{% step %}
Other Required Accessories:

1. A micro SD card (TF Card) and a card reader. Storage cards with at least a C10 and A1 rating are recommended.
2. Ethernet cable.
3. If you need to add Zigbee devices, prepare a Zigbee Dongle. Tested Zigbee Dongles include:

> SONOFF ZBDongle-MAX\
> SONOFF ZBDongle-PMG24\
> SONOFF ZBDongle-LMG21\
> SONOFF ZBDongle-E\
> SONOFF ZBDongle-P\
> [Others listed](https://darkxst.github.io/silabs-firmware-builder/) by developer @darkxst&#x20;

{% hint style="info" %}
For more information on Zigbee configurations and compatibility, please refer to this [guide](/compatibility-check/zigbee.md).
{% endhint %}

4. Power Adapter (Alternatively, if you have a Power over Ethernet (PoE) Hat installed, ensure your network switch or router, as well as the Ethernet cable, can provide sufficient power)

{% hint style="info" %}
Ensure you have an [appropriate power supply](https://www.raspberrypi.com/documentation/computers/raspberry-pi.html#power-supply) for the Raspberry Pi. Smartphone chargers may not be suitable, as some only provide full power to certain manufacturers’ phones. USB ports on computers do not supply adequate power and should not be used.
{% endhint %}
{% endstep %}
{% endstepper %}

## 2. Burn CUBE OS to SD Card

{% stepper %}
{% step %}
Download and install the Raspberry Pi Imager from the [Raspberry Pi website](https://www.raspberrypi.com/software/).

<img src="/files/EHUURZFDK4FS6rUH2E4c" alt="" data-size="original">
{% endstep %}

{% step %}
Open Raspberry Pi Imager and select your Raspberry Pi device.

<img src="/files/0kwNtaQPCLZdeuq3l5Jj" alt="" data-size="original">
{% endstep %}

{% step %}
For the operating system, choose “Use Custom” and select the downloaded CUBE image.

<img src="/files/0vxdggs1fiVMPS263uNY" alt="" data-size="original">![](/files/kBYW9VXvgy4cYhifEkzD)
{% endstep %}

{% step %}
Insert the SD card into the computer and select it as the storage to use.

<img src="/files/0SNwOfWy9SR3s6PuVY3h" alt="" data-size="original">
{% endstep %}

{% step %}
If you are promoted with customization options, click `NO`.

<img src="/files/5Q4BmvZmAy4gFP2fXMsX" alt="" data-size="original">
{% endstep %}

{% step %}
Click “Next” to write the image to the SD card. Note that the card’s contents will be overwritten.

<img src="/files/erGnlRmSb6aZVq2sn2T6" alt="" data-size="original">
{% endstep %}

{% step %}
Wait until the write process reaches 100% and eject the SD card upon completion.

<img src="/files/23FegkYW9e3ojv5BPkGH" alt="" data-size="original">
{% endstep %}
{% endstepper %}

## 3. Boot Raspberry Pi and Accessing CUBE:

{% stepper %}
{% step %}
Insert the Micro SD card into the Raspberry Pi (on the short side of the board near the LED).

<img src="/files/ji4oGXjuAhtB7JxWjmfR" alt="" data-size="original">
{% endstep %}

{% step %}
Connect the Raspberry Pi to a power source and Ethernet cable, ensuring it is on the same network as your computer and connected to the internet.

<img src="/files/2p69dhObIf8GekanRJhf" alt="" data-size="original">
{% endstep %}

{% step %}
Optional: If you have a Zigbee Dongle, plug it into a USB port.

<img src="/files/ITEAdwdRZ86nrZFCx7OU" alt="" data-size="original">
{% endstep %}

{% step %}
After powering the Raspberry Pi, wait a few minutes for it to boot up. Then, access the Web management page using [cube.local](http://cube.local).

<img src="/files/EmSfdQmPVT2RG0PvjCmd" alt="" data-size="original">

Or you can find the CUBE’s IP from your router’s interface and use it to access the management page. Usually, you can see the IP next to the device named `cube`, which also has the longest expiring time (Leasetime remaining).

<img src="/files/OvaGNMKjkG1rkRAulSHs" alt="" data-size="original">
{% endstep %}

{% step %}
Upon successful access, view a short ID on the settings page. Access the CUBE Web management page subsequently using cube-{short id}.local, especially useful for distinguishing multiple CUBEs on the same local network.

<img src="/files/3xHezvHm3zy90J9LazfZ" alt="" data-size="original">
{% endstep %}
{% endstepper %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://cube.ewelink.cc/getting-started/quickstart/raspberry-pi.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
