Skip to content

Commit fd6154f

Browse files
committed
Portenta X8 related fixes
1 parent b10a03f commit fd6154f

File tree

4 files changed

+18
-16
lines changed

4 files changed

+18
-16
lines changed

content/hardware/04.pro/boards/portenta-x8/essentials.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@
2626
Download the latest firmware for Portenta X8 (Recommended).
2727
</EssentialElement>
2828

29-
<EssentialElement title="Firmware Release Notes" type="article" link="/tutorials/portenta-x8/x8-firmware-release-notes">
29+
<EssentialElement link="/tutorials/portenta-x8/x8-firmware-release-notes" title="Firmware Release Notes" type="library">
3030
All available Portenta X8 firmware release notes.
3131
</EssentialElement>
3232

content/hardware/04.pro/boards/portenta-x8/tutorials/04.python-arduino-data-exchange/content.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
---
22
title: '04. Data Exchange Between Python® on Linux & Arduino Sketch'
33
description: 'This tutorial will show you how to run a Python® application that exchanges data with an Arduino Sketch.'
4+
difficulty: intermediate
45
tags:
56
- RPC
67
- Python®
@@ -112,7 +113,7 @@ python-sensor-rpc_1 | Altitude: 311.0769348144531
112113

113114
Whenever you change anything in the Python® script on your computer, you will have to sync it back to the X8 and re-build the container. Following command sequence will help you to do this process:
114115

115-
```
116+
```bash
116117
# On your computer
117118
adb push python-sensor-rpc /home/fio
118119

content/hardware/04.pro/boards/portenta-x8/tutorials/08.image-building/content.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -232,7 +232,7 @@ In this tutorial, you have learned how to build a "builder" Docker image, get it
232232

233233
## Next Steps
234234

235-
Please follow the [Flashing tutorial](image-flashing) to flash your device with your custom image. You can use the files provided from this build to flash the Portenta X8 following the tutorial's steps.
235+
Please follow the [Flashing tutorial](https://docs.arduino.cc/tutorials/portenta-x8/image-flashing/) to flash your device with your custom image. You can use the files provided from this build to flash the Portenta X8 following the tutorial's steps.
236236

237237
## Troubleshooting
238238

content/hardware/04.pro/boards/portenta-x8/tutorials/12.multi-protocol-gateway/content.md

Lines changed: 14 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
---
22
title: '12. Multi-Protocol Gateway With Portenta X8 & Max Carrier'
33
description: 'This tutorial shows how to setup a multi-protocol gateway environment on Portenta X8 using Max Carrier'
4+
difficulty: intermediate
45
tags:
56
- Containers
67
- Docker
@@ -111,15 +112,15 @@ Before you begin diving deep into creating a Multi-protocol gateway, and having
111112

112113
The `m4-proxy` is a service that manages data exchange between these layers. You can use the following command in the terminal to observe if the service is running correctly.
113114

114-
```
115+
```bash
115116
sudo journalctl -fu m4-proxy
116117
```
117118

118119
Now you will implement RPC (Remote Procedure Call) to establish communication between the Arduino and Linux layers, which is a communication mechanism developed to exchange data between these two layers.
119120

120121
**You will not be able to check messages via `Serial.println()` statements** to check if the Arduino sketch is running in the desired manner. You will have to use instead **`py-serialrpc`**, which is a service that will assist you in listening to those messages, and printing them on a console on the Linux layer. To have the service active, please download [this compressed file](assets/py-serialrpc.zip) to build and run the container on the Linux side of Portenta X8. Please execute the following commands to have the service running.
121122

122-
```
123+
```bash
123124
// Copy the decompressed files in ../adb/32.0.0
124125
adb push py-serialrpc /home/fio
125126
adb shell
@@ -134,15 +135,15 @@ cd /home/fio/py-serialrpc
134135

135136
To access the logs of `py-serialrpc` service, while maintaining the same directory, execute the following command.
136137

137-
```
138+
```bash
138139
sudo docker-compose logs -f --tail 20
139140
```
140141

141142
***For more details about how data exchange between Arduino and Linux layer works and to understand how to debug, please read [Data Exchange Between Python® on Linux and an Arduino Sketch](https://docs.arduino.cc/tutorials/portenta-x8/python-arduino-data-exchange)***
142143

143144
If you have not configured internal Wi-Fi® connectivity within the system, please use the following command line:
144145

145-
```
146+
```bash
146147
nmcli device wifi connect "SSID" password "PASSWORD"
147148
```
148149

@@ -495,22 +496,22 @@ It is now time to make the multi-protocol gateway run and for this, you will nee
495496

496497
You will need to have the files ready in a folder inside the `adb` directory within Arduino root.
497498

498-
```
499+
```bash
499500
C:\Users\#USERNAME#\AppData\Local\Arduino15\packages\arduino\tools\adb\32.0.0
500501
```
501502

502503
Having the files ready in that directory, you can use the following commands to push the files to the `fio` directory inside the Portenta X8. The second command will let you navigate inside the Portenta X8.
503504

504-
```
505+
```bash
505506
adb push multi-protocol-gateway /home/fio
506507
adb shell
507508
```
508509

509510
You will now build the container using the following commands. The following command will tag the container with `Multi_Protocol_Gateway_X8` as its name.
510511

511-
```
512+
```bash
512513
cd ../home/fio/Multi_Protocol_Gateway_X8
513-
#Multi_Protocol_Gateway_X8 sudo docker build . -t multi_gateway
514+
Multi_Protocol_Gateway_X8 sudo docker build . -t multi_gateway
514515
```
515516

516517
You will be able to see the following results when the image is built successfully.
@@ -521,19 +522,19 @@ You will be able to see the following results when the image is built successful
521522

522523
After a successful container build, you will run the image. To do that, you can use the following command. This command will immediately give an output in your terminal, telling you how the Python® script is running. If you wish to have it running in the background, please add the `-d` flag at the end of the command.
523524

524-
```
525-
#Multi_Protocol_Gateway_X8 sudo docker-compose up
525+
```bash
526+
Multi_Protocol_Gateway_X8 sudo docker-compose up
526527
```
527528

528529
Finally, you will have the multi-protocol gateway running, which uses Wi-Fi® and LoRa® connectivity. Also, RPC for exchanging data between its layers. However, there are cases where you would wish to make changes by adding more functionalities, such as including Cat. M1 or NB-IoT to expand its communication spectrum. For this, you will need to stop the image. To stop the image from running, you can use the following command.
529530

530-
```
531-
#Multi_Protocol_Gateway_X8 sudo docker-compose down
531+
```bash
532+
Multi_Protocol_Gateway_X8 sudo docker-compose down
532533
```
533534

534535
Getting to know the status of the image is also crucial as it is the indicator of the state of operation. The following command brings up **active** containers and shows the status if the container restarted or stopped due to certain reasons. The second command lists built images and it will show you the components that go with the main image that you're building.
535536

536-
```
537+
```bash
537538
docker ps -a
538539
docker images
539540
```

0 commit comments

Comments
 (0)