Skip to content

Commit 4ee431f

Browse files
Optimized alt text for accessibility & SEO
1 parent b22b74c commit 4ee431f

4 files changed

Lines changed: 19 additions & 14 deletions

File tree

content/learning-paths/embedded-and-microcontrollers/raspberry-pi-smart-home/1-overview.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ The Raspberry Pi 5's Arm Cortex-A76 processor can manage high-performance comput
2424

2525
These characteristics make the Raspberry Pi 5 well suited for workloads like smart home assistants, where responsiveness, efficiency, and local processing are important. Running LLMs locally on Arm-based devices brings several practical benefits. Privacy is preserved, since conversations and routines never leave the device. With optimized inference, the system can offer responsiveness under 100 ms, even on resource-constrained hardware. It remains fully functional in offline scenarios, continuing to operate when internet access is unavailable. Developers also gain flexibility to customize models and automations. Additionally, software updates and an active ecosystem continue to improve performance over time.
2626

27-
## Leverage the Arm ecosystem for Raspberry Pi edge AI
27+
## Leverage the Arm ecosystem for Raspberry Pi Edge AI
2828

2929
For the stack in this setup, Raspberry Pi 5 benefits from the extensive developer ecosystem:
3030

@@ -46,7 +46,7 @@ The table below shows inference performance for several quantized models running
4646
| gemma2:2b | 4.1 | 23,758 |
4747
| deepseek-r1:7b | 1.6 | 64,797 |
4848

49-
### LLM benchmark insights on Raspberry Pi 5
49+
## LLM benchmark insights on Raspberry Pi 5
5050

5151
- Qwen 0.5B and TinyLlama 1.1B deliver fast token generation and low average latency, making them suitable for real-time interactions such as voice-controlled smart home commands
5252
- DeepSeek-Coder 1.3B and Gemma 2B trade some speed for improved language understanding, which can be useful for complex tasks or context-aware prompts
@@ -56,7 +56,7 @@ The table below shows inference performance for several quantized models running
5656

5757
This Learning Path focuses on the Raspberry Pi 5, but you can adapt the concepts and code to other Arm-powered devices.
5858

59-
### Recommended platforms
59+
## Recommended platforms
6060

6161
| Platform | CPU | RAM | GPIO support | Model size suitability |
6262
| ------------------- | -------------------------------- | -------------- | ------------------------------ | --------------------------- |

content/learning-paths/embedded-and-microcontrollers/raspberry-pi-smart-home/2-software-dependencies.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ layout: learningpathall
1111
In this section, you’ll prepare your Raspberry Pi 5 by installing Python, required libraries, and Ollama, so you can run large language models (LLMs) locally.
1212

1313
{{% notice Note %}}
14-
This guide assumes you have set up your Raspberry Pi with Raspberry Pi OS and network connectivity. For Raspberry Pi 5 setup help, see: [Raspberry Pi Getting Started](https://www.raspberrypi.com/documentation/)
14+
This Learning Path assumes you have set up your Raspberry Pi with Raspberry Pi OS and network connectivity. For Raspberry Pi 5 setup support, see [Raspberry Pi Getting Started](https://www.raspberrypi.com/documentation/).
1515
{{% /notice %}}
1616

1717
## Connect to your Raspberry Pi 5
@@ -46,7 +46,7 @@ sudo apt update && sudo apt upgrade -y
4646
sudo apt install -y python3 python3-pip python3-venv git curl build-essential gcc python3-lgpio
4747
```
4848

49-
### Configure a virtual environment
49+
## Configure a virtual environment
5050

5151
Create and activate a Python virtual environment to isolate project dependencies:
5252

content/learning-paths/embedded-and-microcontrollers/raspberry-pi-smart-home/3-test-gpio.md

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,13 +6,17 @@ weight: 4
66
layout: learningpathall
77
---
88

9+
## Overview
10+
911
The next step is to test the GPIO functionality. In this section, you configure an LED light to simulate a smart home device.
1012

1113
## Verify GPIO setup on Raspberry Pi 5
1214

13-
Gather your electronic components. Connect the anode (long leg) of an LED in series with a 220Ω resistor to GPIO 17 (physical pin 11). Connect the cathode (short leg) to a ground (GND) pin. See the image below for the full setup:
15+
Gather your electronic components. Connect the anode (long leg) of an LED in series with a 220Ω resistor to GPIO 17 (physical pin 11). Connect the cathode (short leg) to a ground (GND) pin.
16+
17+
See the image below for the full setup:
1418

15-
![Raspberry Pi connected to a breadboard with a green LED and jumper wires](pin_layout.jpg "Raspberry Pi connected to a breadboard with a green LED and jumper wires")
19+
![Raspberry Pi connected to a breadboard with a green LED and jumper wires alt-text#center](pin_layout.jpg "Raspberry Pi connected to a breadboard with a green LED and jumper wires")
1620

1721
Create a Python script named `testgpio.py`:
1822

content/learning-paths/embedded-and-microcontrollers/raspberry-pi-smart-home/4-smart-home-assistant.md

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -35,8 +35,9 @@ In the previous section, you configured a LED on GPIO pin 17. The smart home ass
3535
The code uses gpiozero with lgpio backend for Raspberry Pi 5 compatibility. You can use compatible output devices such as LEDs, relays, or small loads connected to these GPIO pins to represent actual smart home devices. All pin assignments are optimized for the Raspberry Pi 5's GPIO layout.
3636
{{% /notice %}}
3737

38-
![Raspberry Pi connected to breadboard with LEDs, buttons, and a sensor module](hardware.jpeg "Setup that includes a blue LED (mapped to Living Room Light on GPIO 17), a red LED, push button, and a sensor module. This setup illustrates a simulated smart home with controllable devices.")
38+
![[Raspberry Pi 5 connected to a breadboard with LEDs, push button, and sensor module alt-text#center](hardware.jpeg "Setup that includes a blue LED (mapped to Living Room Light on GPIO 17), a red LED, push button, and a sensor module.")
3939

40+
This setup illustrates a simulated smart home with controllable devices.
4041

4142
## Run the Smart Home Assistant
4243

@@ -57,7 +58,7 @@ python3 smart_home_assistant.py --no-api
5758
{{< /tab >}}
5859
{{< /tabpane >}}
5960

60-
### Command options
61+
## Command options
6162

6263
| Option | Description | Example |
6364
|------------------|---------------------------------------------------------------------------------------------------|--------------------------------------------|
@@ -67,20 +68,20 @@ python3 smart_home_assistant.py --no-api
6768

6869
If everything is set up correctly, you should see the following output on running the default command:
6970

70-
![Running in Default Mode](cmd.png "Running the code in default mode")
71+
![Terminal running smart_home_assistant.py showing default web API and CLI output alt-text#center](cmd.png "Running the code in default mode")
7172

7273
## Interact with your assistant
7374

7475
Try asking the assistant to `turn on living room light`. If you've connected additional devices, come up with prompts to test the setup.
7576

76-
### Web interface
77+
## Web interface
7778

7879
Open your browser and navigate to `http://0.0.0.0:8000`, or as printed in the terminal output.
7980

80-
![Web Interface Interaction](UI3.png "Interacting with the LLM through the web interface")
81+
![Web interface of the smart home assistant showing device control through LLM commands alt-text#center](UI3.png "Interacting with the LLM through the web interface")
8182

8283

83-
### Command line interface
84+
## Command line interface
8485

8586
Type commands directly in the terminal.
8687

@@ -92,7 +93,7 @@ I want to watch my favorite show
9293
its getting late, secure the house
9394
```
9495

95-
![DeepSeek-Coder Interaction](gemma2.png "Interacting with deepseek-coder:1.3b")
96+
![Terminal interaction with the smart home assistant showing LLM responses to user commands alt-text#center](gemma2.png "Interacting with deepseek-coder:1.3b")
9697

9798
{{% notice Troubleshooting %}}
9899
If you're running into issues with the assistant, here are some things to check:

0 commit comments

Comments
 (0)