Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion content/blog/2020/11/nuttx-getting-started/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@ authors:
- "eren-terzioglu"
- "filipe-cavalcanti"
summary: "This article provides a tutorial to get started with NuttX."
aliases:
- /blog/nuttx-getting-started
---

## Introduction to Apache NuttX RTOS
Expand Down Expand Up @@ -285,4 +287,4 @@ NuttX is one of the most preferred RTOS for developers familiar with Linux inter

---

The [original article](https://medium.com/the-esp-journal/getting-started-with-esp32-and-nuttx-fd3e1a3d182c) was published on Medium, on the [ESP Journal](https://medium.com/the-esp-journal). It has since been updated.
The [original article](https://medium.com/the-esp-journal/getting-started-with-esp32-and-nuttx-fd3e1a3d182c) was published on Medium, on the [ESP Journal](https://medium.com/the-esp-journal). It has since been updated.
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@ tags:
- Nuttx
- Esp32
summary: "This is a tutorial on how to blink an LED with NuttX after getting started."
aliases:
- /blog/blink-led-on-esp32-with-rtos-nuttx
---
\
{{< alert >}}
Expand Down

Large diffs are not rendered by default.

2 changes: 2 additions & 0 deletions content/blog/2024/06/zephyr-max-wifi-throughput/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@ authors:
- "marcio-ribeiro"
tags: ["ESP32-S3", "Zephyr", "Wi-Fi"]
summary: "How to improve the throuput of network applications with Zephyr on Espressif devices."
aliases:
- /blog/zephyr-max-wifi-throughput
---

Those who develop IoT applications based on Zephyr OS often need to optimize the communication performance. It can be done by tweaking the Wi-Fi network stack parameters. However, how do you evaluate the resulting changes and find the most suitable configuration? In this article, we will overview a method to optimize communication performance by using the `iperf` and `zperf` tools.
Expand Down
3 changes: 2 additions & 1 deletion content/blog/2024/08/esp32-memory-map-101/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,8 @@ showAuthor: false
authors:
- "marek-matej"
aliases:
- [esp32s-family-memory-map-101]
- /blog/esp32s-family-memory-map-101
- /blog/esp32-memory-map-101
summary: "This article addresses the complexity of Espressif SoCs by offering a visual, structured compilation of crucial technical data from their datasheets and TRMs. The main takeaway for the reader is a simplified, actionable understanding of the memory maps, caches, peripherals, and eFuse blocks, which is essential for low-level system and driver development."
---

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@ showAuthor: false
authors:
- "tiago-medicci"
summary: "This article shows how to port and build an application form other Posix-compliant systems to NuttX."
aliases:
- /blog/nuttx-adding-porting-an-app
---

## Developing a Project with Existing Applications
Expand Down
6 changes: 4 additions & 2 deletions content/blog/2024/10/esp32-bootstrapping/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@ authors:
- "marek-matej"
tags: ["ESP32", "ESP32-S2", "ESP32-S3", "ESP32-C3", "ESP32-C6", "ESP-IDF", "Zephyr"]
summary: "This article explains the booting process of Espressif devices up to ESP32-C6 (and probably newer devices)."
aliases:
- /blog/esp32-bootstrapping
---

Those acquainted with the ESP32 system-on-chip (SoC) family know the complexity involved in analyzing its booting process. From navigating the embedded ROM bootloader, facilitated by comprehensive tooling, to initiating the 2nd stage bootloader, which subsequently launches the user application. The procedure deviates significantly from the the straightforward "jump-to-reset-vector" way of starting the user program, as we can see on the ARM architecture.
Expand Down Expand Up @@ -363,7 +365,7 @@ uart:~$

### MCUboot Zephyr port (ZP)

First lets take a look at how to manually build the MCUboot and the subsequent application. Each `west flash` in the code is using its own flash partition and it is not overwritten by each other.
First lets take a look at how to manually build the MCUboot and the subsequent application. Each `west flash` in the code is using its own flash partition and it is not overwritten by each other.

Building and flashing the MCUboot separately at its location:
```shell
Expand Down Expand Up @@ -525,6 +527,6 @@ The ESP32 port in Zephyr RTOS has variety of booting options.
## Additional reading

- [Zephyr RTOS and ESP32](https://www.zephyrproject.org/zephyr-rtos-on-esp32/)
- [ESP32's memory map](https://developer.espressif.com/blog/esp32-memory-map-101/)
- [ESP32's memory map](https://developer.espressif.com/blog/2024/08/esp32-memory-map-101/)
- [ESP32 Programmers memory model](https://developer.espressif.com/blog/esp32-programmers-memory-model/)
- [ESP32-S3 Technical Reference Manual](https://www.espressif.com/sites/default/files/documentation/esp32-s3_datasheet_en.pdf)
26 changes: 14 additions & 12 deletions content/blog/2024/10/pytest-testing-with-nuttx/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@ showAuthor: false
authors:
- "filipe-cavalcanti"
summary: "How Pytest is used for testing the NuttX RTOS on Espressif devices."
aliases:
- /blog/pytest-testing-with-nuttx
---

## Introduction
Expand All @@ -29,7 +31,7 @@ Pytest allows us to set up a test environment and scale tests easily, using fixt

Pytest integrates with argparse, enabling us to pass arguments to tests via the command line or by specifying them in an .ini file. These arguments can be accessed by any test case when needed.

Another significant advantage of pytest is the large number of available plugins. Pytest provides a standard way to implement [plugins](https://docs.pytest.org/en/stable/reference/plugin_list.html) using its hooks, allowing contributors to share their plugins with the community.
Another significant advantage of pytest is the large number of available plugins. Pytest provides a standard way to implement [plugins](https://docs.pytest.org/en/stable/reference/plugin_list.html) using its hooks, allowing contributors to share their plugins with the community.

## Setting Up the Test Environment

Expand All @@ -47,7 +49,7 @@ To create the virtual environment, use Python's venv tool and create an environm
```
fdcavalcanti@espubuntu:~/embedded_test$ python3 -m venv venv
fdcavalcanti@espubuntu:~/embedded_test$ source venv/bin/activate
(venv) fdcavalcanti@espubuntu:~/embedded_test$
(venv) fdcavalcanti@espubuntu:~/embedded_test$
```

Next, upgrade pip (Python’s package manager) and install the following packages:
Expand All @@ -74,7 +76,7 @@ pytest 8.3.3
Now, the environment is ready, and we can begin setting up our tests.

## Establishing Communication

Before we can test an application, we need to establish working serial communication that we can use in our tests. First, we’ll create a Python class to handle this, and then we’ll explore how pytest can leverage it.

## Serial Communication Class
Expand All @@ -89,7 +91,7 @@ Our class will be called SerialCommunication and will contain the mandatory init
The following is what our initialization looks like. The timeout argument is important to avoid locking our serial port in case of a failure where the device is unresponsive. It can also be adjusted on the fly for long test cases.

```python
import serial
import serial

class SerialCommunication:
def __init__(self, port: str, baudrate: int=115200, timeout: int=10):
Expand Down Expand Up @@ -131,7 +133,7 @@ def close(self) -> None:
I have an [ESP32H2 Devkit](https://docs.espressif.com/projects/esp-dev-kits/en/latest/esp32h2/esp32-h2-devkitm-1/user_guide.html) connected to my serial port at `/dev/ttyUSB0` and
running the `nsh` firmware configuration.

If you are not familiar with building NuttX, checkout this article on [getting started with NuttX and ESP32](https://developer.espressif.com/blog/nuttx-getting-started/).
If you are not familiar with building NuttX, checkout this article on [getting started with NuttX and ESP32](https://developer.espressif.com/blog/2020/11/nuttx-getting-started/).

Below, we will add a simple main routine to our communication.py file to validate that our communication works by sending the help and uname commands and reading the responses.

Expand All @@ -146,10 +148,10 @@ if __name__ == "__main__":
Output from the routine above:

```console
(venv) fdcavalcanti@espubuntu:~/embedded_test$ python3 communication.py
(venv) fdcavalcanti@espubuntu:~/embedded_test$ python3 communication.py
uname -a
NuttX 10.4.0 4622e4f996-dirty Sep 27 2024 14:52:14 risc-v esp32h2-devkit
nsh>
nsh>
```

So it works. We have the communication basis that allows us to structure our Pytest environment. The same recipe can be followed for communication via telnet, sockets, MQTT, or whatever is needed for the application.
Expand Down Expand Up @@ -179,7 +181,7 @@ This first example's conftest.py file will be responsible for one task: creating

Create the conftest file:
```
(venv) fdcavalcanti@espubuntu:~/embedded_test$ touch conftest.py
(venv) fdcavalcanti@espubuntu:~/embedded_test$ touch conftest.py
```

Then, import the SerialCommunication class and create the fixture using session scope, naming it "target".
Expand Down Expand Up @@ -224,7 +226,7 @@ rootdir: /home/fdcavalcanti/embedded_test
plugins: metadata-3.1.1, html-4.1.1
collected 1 item

test_uname.py::test_uname_board PASSED [100%]
test_uname.py::test_uname_board PASSED [100%]
============================== 1 passed in 0.14s ==============================
```

Expand All @@ -250,7 +252,7 @@ def test_dir_create_delete(target):
target.write(f"mkdir {directory}")
ans = target.write("ls")
assert directory in ans

target.write(f"rmdir {directory}")
ans = target.write("ls")
assert directory not in ans
Expand All @@ -270,7 +272,7 @@ def test_dir_create_delete(target, directory):
target.write(f"mkdir {directory}")
ans = target.write("ls")
assert directory in ans

target.write(f"rmdir {directory}")
ans = target.write("ls")
assert directory not in ans
Expand Down Expand Up @@ -365,7 +367,7 @@ For more information, refer to the links below.

- [Pytest getting started](https://docs.pytest.org/en/stable/getting-started.html)
- [Example repository](https://github.com/fdcavalcanti/pytest-nuttx-testing-sample)
- [Getting Started with NuttX and ESP32](https://developer.espressif.com/blog/nuttx-getting-started/)
- [Getting Started with NuttX and ESP32](https://developer.espressif.com/blog/2020/11/nuttx-getting-started/)
- [GoogleTest](http://google.github.io/googletest/)
- [CppTest](https://cpptest.sourceforge.io/)
- [Robot Framework](https://robotframework.org/)
4 changes: 2 additions & 2 deletions content/blog/2024/11/using-wokwi-with-nuttx/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ In this article, we will examine how the NuttX real-time operating system (RTOS)
{{< alert icon="eye" >}}
**Note!**

Note: Reviewing this article together with <cite>[NuttX on an emulated ESP32 using QEMU](https://medium.com/@lucassvaz/nuttx-on-an-emulated-esp32-using-qemu-8d8d93d24c63)</cite> article will help the user to distinguish between the two solutions and to determine the most suitable solution for the needs. Additionally, it is recommended to have knowledge of project compilation through the NuttX official documentation and <cite>[Getting Started with NuttX and ESP32](https://developer.espressif.com/blog/nuttx-getting-started/)</cite> article. NuttX project build documentation is available [at this link](https://nuttx.apache.org/docs/latest/).
Note: Reviewing this article together with <cite>[NuttX on an emulated ESP32 using QEMU](https://medium.com/@lucassvaz/nuttx-on-an-emulated-esp32-using-qemu-8d8d93d24c63)</cite> article will help the user to distinguish between the two solutions and to determine the most suitable solution for the needs. Additionally, it is recommended to have knowledge of project compilation through the NuttX official documentation and <cite>[Getting Started with NuttX and ESP32](https://developer.espressif.com/blog/2020/11/nuttx-getting-started/)</cite> article. NuttX project build documentation is available [at this link](https://nuttx.apache.org/docs/latest/).
{{< /alert >}}

## What is Wokwi?
Expand Down Expand Up @@ -226,4 +226,4 @@ In this article, we have seen the features of Wokwi and how it can be used with
[4]: https://docs.wokwi.com/getting-started/supported-hardware
[5]: https://docs.wokwi.com/vscode/project-config
[6]: https://docs.wokwi.com/vscode/debugging
[7]: https://developer.espressif.com/blog/nuttx-getting-started/
[7]: https://developer.espressif.com/blog/2020/11/nuttx-getting-started/
20 changes: 10 additions & 10 deletions content/blog/2024/11/zephyr-tracing-and-profiling/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@ authors:
- "raffael-rostagno"
tags: ["ESP32", "Tracing", "Profiling","Zephyr"]
summary: "This is an introduction to the critical embedded system debugging techniques of tracing and profiling within the Zephyr RTOS. After reading this article, you can use Zephyr's native tracing tools to gain a visual, in-depth understanding of system dynamics, helping to evaluate performance, spot timing issues, and diagnose complex problems like memory leaks or thread interaction glitches."
aliases:
- /blog/zephyr-tracing-and-profiling
---

Embedded systems can be quite complex, depending on the architecture, application size and nature. Even for an experienced embedded developer, understanding the interplay of threads, interrupts, and multiple processes that run in a large application can be challenging. We humans are (mostly) visual by nature, and having the means to *visualize* what is happening in a given system can really open up possibilities. Without the right tools we are often in the dark, quite literally.
Expand Down Expand Up @@ -268,14 +270,12 @@ Even though these examples may be more applicable to analyzing complex systems,

## Resources

[1] [Zephyr's Getting Started](https://docs.zephyrproject.org/latest/develop/getting_started/index.html)
[2] [Zephyr's tracing subsystem](https://docs.zephyrproject.org/latest/services/tracing/index.html)
[3] [Tracing utility macros](https://docs.zephyrproject.org/apidoc/latest/group__subsys__tracing__macros.html)
[4] [Zephyr instrumentation subsystem (RFC)](https://github.com/zephyrproject-rtos/zephyr/issues/57373)
[5] [Percepio TraceRecorder and Stream Ports](https://docs.zephyrproject.org/latest/services/tracing/index.html#percepio-tracerecorder-and-stream-ports)
[The Microscope for Embedded Code: How Tracealyzer Revealed Our Bug](https://percepio.com/the-microscope-for-embedded-code-how-tracealyzer-revealed-our-bug/)
[Efficient Firmware Development with Visual Trace Diagnostics](https://percepio.com/percepio-tracealyzer-efficient-firmware-development-with-visual-trace-diagnostics/)
[Tracealyzer on Zephyr – Examples from AC6](https://percepio.com/tracealyzer-zephyr-examples-ac6/)
[1] [Zephyr's Getting Started](https://docs.zephyrproject.org/latest/develop/getting_started/index.html)
[2] [Zephyr's tracing subsystem](https://docs.zephyrproject.org/latest/services/tracing/index.html)
[3] [Tracing utility macros](https://docs.zephyrproject.org/apidoc/latest/group__subsys__tracing__macros.html)
[4] [Zephyr instrumentation subsystem (RFC)](https://github.com/zephyrproject-rtos/zephyr/issues/57373)
[5] [Percepio TraceRecorder and Stream Ports](https://docs.zephyrproject.org/latest/services/tracing/index.html#percepio-tracerecorder-and-stream-ports)
[The Microscope for Embedded Code: How Tracealyzer Revealed Our Bug](https://percepio.com/the-microscope-for-embedded-code-how-tracealyzer-revealed-our-bug/)
[Efficient Firmware Development with Visual Trace Diagnostics](https://percepio.com/percepio-tracealyzer-efficient-firmware-development-with-visual-trace-diagnostics/)
[Tracealyzer on Zephyr – Examples from AC6](https://percepio.com/tracealyzer-zephyr-examples-ac6/)
[Percepio Tracealyzer](https://percepio.com/tracealyzer/)


Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ Besides **ESP-IDF** (see [ESP-IDF Getting Started](https://docs.espressif.com/pr
git clone https://github.com/espressif/esp-self-reflasher.git
```

- **NuttX**: in order to build the application that will be migrated to, set the **NuttX** workspace. See [NuttX Getting Started](https://developer.espressif.com/blog/nuttx-getting-started/).
- **NuttX**: in order to build the application that will be migrated to, set the **NuttX** workspace. See [NuttX Getting Started](https://developer.espressif.com/blog/2020/11/nuttx-getting-started/).

- **MCUboot**: in the case of building the bootloader standalone, follow the instructions [here](https://docs.mcuboot.com/readme-espressif.html).

Expand Down
6 changes: 3 additions & 3 deletions content/blog/2025/05/nuttx-motor-control-and-sensing/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ In this first article, we'll focus on implementing basic motor control. You'll l

## Getting Started

If you are not familiar with NuttX, please refer to the NuttX official documentation and <cite>[Getting Started with NuttX and ESP32](https://developer.espressif.com/blog/nuttx-getting-started/)</cite> article. This article assumes basic familiarity with the NuttX environment and jumps straight into the application development.
If you are not familiar with NuttX, please refer to the NuttX official documentation and <cite>[Getting Started with NuttX and ESP32](https://developer.espressif.com/blog/2020/11/nuttx-getting-started/)</cite> article. This article assumes basic familiarity with the NuttX environment and jumps straight into the application development.

As the starting point for our project, we create an empty repository that will be used as an extension of `nuttx-apps`. This approach allows simple integration with the NuttX build system, just like a standard application.

Expand Down Expand Up @@ -521,5 +521,5 @@ You can access the second article [here](../../07/nuttx-motor-control-and-sensin
- [NuttX ESP32 Documentation](https://nuttx.apache.org/docs/latest/platforms/risc-v/esp32c6/index.html)
- [ESP32-C6 Technical Reference Manual](https://www.espressif.com/sites/default/files/documentation/esp32-c6_technical_reference_manual_en.pdf)
- [Example Repository](https://github.com/fdcavalcanti/nuttx-esp-motor-sensing)
- [Getting Started with NuttX and ESP32](https://developer.espressif.com/blog/nuttx-getting-started/)
- [Part 2: NuttX for Motor Control and Sensing: IMU Integration and Wireless Data Streaming](../../07/nuttx-motor-control-and-sensing-data-trans)
- [Getting Started with NuttX and ESP32](https://developer.espressif.com/blog/2020/11/nuttx-getting-started/)
- [Part 2: NuttX for Motor Control and Sensing: IMU Integration and Wireless Data Streaming](../../07/nuttx-motor-control-and-sensing-data-trans)
4 changes: 2 additions & 2 deletions content/blog/2025/06/simple-boot-explained/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ By adhering to these constraints, we can craft a simplified bootable image that

In the next section, we’ll walk through how to prepare such an image and modify the application accordingly.

Now its a good time to read [the ROM-loader chapter at related article](https://developer.espressif.com/blog/esp32-bootstrapping/#rom-loader).
Now its a good time to read [the ROM-loader chapter at related article](https://developer.espressif.com/blog/2024/10/esp32-bootstrapping/#rom-loader).

## Image build

Expand Down Expand Up @@ -156,4 +156,4 @@ While this simplified boot approach is not suitable for all applications, it can

## Additional readings

- [ESP32 bootstrapping article](https://developer.espressif.com/blog/esp32-bootstrapping/).
- [ESP32 bootstrapping article](https://developer.espressif.com/blog/2024/10/esp32-bootstrapping/).
Loading