You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: content/hardware/03.nano/boards/nano-33-ble/tutorials/ble-python-api/ble-python-api.md
+1-1Lines changed: 1 addition & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -11,7 +11,7 @@ featuredImage: 'board'
11
11
12
12

13
13
14
-
The [Nano 33 BLE board](https://store.arduino.cc/arduino-nano-33-ble-sense) board can be programmed using the popular **Python** programming language. More specifically, it supports [OpenMV's fork of MicroPython](https://github.com/openmv/micropython), where MicroPython is an implementation of the Python language, designed to run on microcontrollers. In this article, you will find a lot of sample scripts that will work directly with your Nano 33 BLE, such as general GPIO control, reading data from the IMU module and testing Bluetooth® Low Energy connection.
14
+
The [Nano 33 BLE](https://store.arduino.cc/arduino-nano-33-ble-sense) board can be programmed using the popular **Python** programming language. More specifically, it supports [OpenMV's fork of MicroPython](https://github.com/openmv/micropython), where MicroPython is an implementation of the Python language, designed to run on microcontrollers. In this article, you will find a lot of sample scripts that will work directly with your Nano 33 BLE, such as general GPIO control, reading data from the IMU module and testing Bluetooth® Low Energy connection.
15
15
16
16
- If you want to read more about Arduino & Python, you can visit the [Python with Arduino](/learn/programming/arduino-and-python) article. Here you will find a lot of useful examples, such as how to use delays, interrupts, reading pins and more general functions.
- USB-C type cable (either USB-A to USB-C or USB-C to USB-C)
39
39
- Arduino IoT Cloud and Arduino_Portenta_OTA libraries
@@ -94,7 +94,7 @@ void loop()
94
94
}
95
95
```
96
96
97
-
This script will light up the RGB LED with 3 different colors in sequence. This code will need to be uploaded to the Arduino Portenta H7 firsthand. This is to verify the sketch compiles and is working correctly. After verifying this, in Arduino IDE, you will search for Sketch -> Export Compiled Binary.
97
+
This script will light up the RGB LED with 3 different colors in sequence. This code will need to be uploaded to the Arduino Portenta H7 firsthand. This is to verify the sketch compiles and is working correctly. After verifying this, in Arduino IDE, you will search for **Sketch > Export Compiled Binary**.
98
98
99
99

100
100
@@ -105,6 +105,7 @@ With the binary file created, we can now create the ota file needed to complete
105
105
You will have to have to extract the library at a preferred location to be able to use the tools. Then you will need to run on the terminal following commands in sequence to be able to create the ota file.
106
106
107
107
Copy the binary file into the library tool's folder
We are using `OTA_Usage_Portenta.ino.PORTENTA_H7_M7` as a sketch name and for facilitated identification of the file. After this you will have the `.ota` file of the sketch that we would like to use with the OTA process.
144
148
145
-
***Now you have two options to choose, use QSPI, or use an SD Card to storage your OTA file. You can use the left side index to jump to the option that you may need***
149
+
***Now you have two options to choose, use QSPI, or use an SD Card to storage your OTA file. You can use the left side index to jump to the option that you may need.***
146
150
147
151
### QSPI Storage Mode
148
152
@@ -152,9 +156,9 @@ To use internal **QSPI** storage for downloading the binary file via OTA (Over-T
To proceed with a OTA using the QSPI flash, you can open the sketch from **Examples ->Arduino_Portenta_OTA -> OTA_Qspi_Flash**.
159
+
To proceed with a OTA using the QSPI flash, you can open the sketch from **Examples >Arduino_Portenta_OTA > OTA_Qspi_Flash**.
156
160
157
-
***Do not forget to fill your Wi-Fi AP SSID, and password on the `arduino_secrets.h` tab***
161
+
***Do not forget to fill your Wi-Fi AP SSID, and password on the `arduino_secrets.h` tab.***
158
162
159
163
This sketch will connect to your Wi-Fi, check if the OTA feature is available by checking the installed firmware on your Portenta.
160
164
@@ -170,10 +174,9 @@ To use the **SD card** as the preferred OTA (Over-The-Air) storage device, we wi
170
174
With this, you will need the Arduino Portenta H7 board connected to the computer with the Arduino IDE. You will need to have selected the **Arduino Portenta H7 (M7 Core)** with the Flash split of **1MB M7 + 1MB M4** for the purpose of this tutorial and the corresponding port.
171
175
172
176
#### Writing the Script
177
+
As same as QSPI storage mode, to proceed with a OTA using the SD Card, you can open the sketch from **Examples > Arduino_Portenta_OTA > OTA_SD_Portenta**.
173
178
174
-
As same as QSPI storage mode, to proceed with a OTA using the SD Card, you can open the sketch from **Examples ->Arduino_Portenta_OTA -> OTA_SD_Portenta**.
175
-
176
-
***Do not forget to fill your Wi-Fi AP SSID, and password on the `arduino_secrets.h` tab***
179
+
***Do not forget to fill your Wi-Fi AP SSID, and password on the `arduino_secrets.h` tab.***
177
180
178
181
This sketch will connect to your Wi-Fi, check if the OTA feature is available by checking the installed firmware on your Portenta.
179
182
@@ -394,7 +397,8 @@ void loop()
394
397
}
395
398
```
396
399
397
-
## Troubleshooting
400
+
## Troubleshooting
398
401
For troubleshooting the issues that might have arose following the tutorial, you can use following tips to solve the issue.
402
+
399
403
- If it logs there has been an issue with Wi-Fi module, means the device may have suffered from losing the Wi-Fi firmware partition. To solve this, you will have to use **PortentaWiFiFirmwareupdater** sketch found on Arduino IDE examples to fix the issue.
400
404
- QSPI storage may throw error -3 while running Portenta H7 OTA QSPI example. To fix this you can use this guide of [Reading and Writing Flash Memory](https://docs.arduino.cc/tutorials/portenta-h7/por-ard-flash/) in the section **Programming the QSPI Flash**. After this, run the example and it should have been solved by eliminating error -3 (OTA Storage initialization error).
Copy file name to clipboardExpand all lines: content/hardware/04.pro/boards/portenta-h7/tutorials/por-ard-ap/content.md
+11-9Lines changed: 11 additions & 9 deletions
Original file line number
Diff line number
Diff line change
@@ -24,20 +24,22 @@ software:
24
24
Portenta H7 comes with an on-board Wi-Fi and a Bluetooth® Module that allows to develop IoT applications that require wireless connectivity and Internet access. Turning the board into an access point allows it to create a Wi-Fi network on its own and allows other devices to connect to it. In this tutorial you will learn to set up your board as an access point web server and remotely control the red, green and blue LEDs on the built-in RGB LED by accessing an HTML page on your mobile device’s browser.
25
25
26
26
## Goals
27
+
27
28
- About the built-in Wi-Fi + Bluetooth® module.
28
29
- How a client-server model works
29
30
- How to create an HTTP communication channel between the board and an external device.
30
31
31
32
### Required Hardware and Software
32
-
- Portenta H7 (ABX00042) or Portenta H7 Lite Connected (ABX00046) board (<https://store.arduino.cc/portenta-h7>)
33
-
- One USB C cable (either USB A to USB C or USB C to USB C)
34
-
- Arduino IDE 1.8.10+ or Arduino Pro IDE 0.0.4 +
35
-
- A smart phone
33
+
34
+
-[Portenta H7 (ABX00042)](https://store.arduino.cc/portenta-h7) or [Portenta H7 Lite Connected (ABX00046)](https://store.arduino.cc/products/portenta-h7-lite-connected)
35
+
- One USB C cable (either USB A to USB C or USB C to USB C)
36
+
- Arduino IDE 1.8.10+ or Arduino Pro IDE 0.0.4 +
37
+
- A smart phone
36
38
37
39
## Access Point Configuration
38
-
The Portenta H7 features a [Murata 1DX](https://wireless.murata.com/type-1dx.html), which is a high performance chipset which supports Wi-Fi 802.11b/g/n + Bluetooth® 5.1 BR/EDR/LE up to 65Mbps PHY data rate on Wi-Fi and 3Mbps PHY data rate on Bluetooth®. This module helps to configure the Portenta into three different modes of operation - an Access Point, a Station, or both. In this tutorial we will only focus on the access point configuration.
40
+
The Portenta H7 features a [Murata 1DX](https://wireless.murata.com/type-1dx.html), which is a high performance chipset which supports Wi-Fi 802.11b/g/n + Bluetooth® 5.1 BR/EDR/LE up to 65Mbps PHY data rate on Wi-Fi and 3Mbps PHY data rate on Bluetooth®. This module helps to configure the Portenta into three different modes of operation - an Access Point, a Station, or both. In this tutorial we will only focus on the access point configuration.
39
41
40
-
When the board is configured to operate as an access point, it can create its own wireless LAN (WLAN) network. In this mode, the board transmits and receives signals at 2.4 GHz allowing other electronic devices with Wi-Fi capabilities using the same bandwidth to connect to the board.
42
+
When the board is configured to operate as an access point, it can create its own wireless LAN (WLAN) network. In this mode, the board transmits and receives signals at 2.4 GHz allowing other electronic devices with Wi-Fi capabilities using the same bandwidth to connect to the board.
41
43
42
44
With the access point set up you create a client server architecture where the board provides a web server communicating with the client devices over HTTP. The connected devices can then make HTTP GET requests to the server to retrieve web pages served by the web server on the board. This makes the Portenta H7 an ideal board for developing IoT solutions where external client devices can send and receive information while more complex processing tasks take place on the server.
43
45
@@ -46,7 +48,7 @@ With the access point set up you create a client server architecture where the b
46
48
## Instructions
47
49
48
50
### Setting Up the Web Server
49
-
In this tutorial you are going to convert the board into an access point and use it to set up a web server which provides a HTML webpage. This page contains buttons to toggle the red, green and blue colour of the built-in LED. You will then connect your mobile device to this access point and access this web page through the browser on your mobile phone. Once retrieved, you will be able to control the state of the red, green and blue LED on the built-in RGB LED from your mobile device.
51
+
In this tutorial you are going to convert the board into an access point and use it to set up a web server which provides a HTML webpage. This page contains buttons to toggle the red, green and blue color of the built-in LED. You will then connect your mobile device to this access point and access this web page through the browser on your mobile phone. Once retrieved, you will be able to control the state of the red, green and blue LED on the built-in RGB LED from your mobile device.
50
52
51
53

52
54
@@ -58,7 +60,7 @@ Begin by plugging in your Portenta board to your computer using a USB-C cable an
58
60
### 2. Create the Web Server Sketch
59
61
Next we need to create a web server sketch that will handle the HTTP GET requests and provide the client devices with the HTML web page. The [Wi-Fi](https://www.arduino.cc/en/Reference/WiFi) library provides all necessary methods that allows Arduino boards to use their Wi-Fi features provided by the on-board Wi-Fi module. To set up the web server copy the following code, paste it into a new sketch file and name it **SimpleWebServer.ino**.
60
62
61
-
**Note:** You can access the final sketch inside the library: **Examples -> Arduino_Pro_Tutorials -> Portenta H7 as a Wi-Fi Access Point -> SimpleWebServer**
63
+
**Note:** You can access the final sketch inside the library: **Examples > Arduino_Pro_Tutorials > Portenta H7 as a Wi-Fi Access Point > SimpleWebServer**
62
64
63
65
```cpp
64
66
#include<WiFi.h>
@@ -255,7 +257,7 @@ Once you’ve created the new tab, you will see an empty page in the IDE. Define
255
257
# define SECRET_PASS "123Qwerty"
256
258
```
257
259
258
-
***The SSID (PortentaAccessPoint) and password (123Qwerty) are placeholder strings made for this tutorial. For security reasons you should rename them to something memorisable but not easy to guess. Keep in mind that the password must be at least 8 characters long.***
260
+
***The SSID (PortentaAccessPoint) and password (123Qwerty) are placeholder strings made for this tutorial. For security reasons you should rename them to something memorable but not easy to guess. Keep in mind that the password must be at least 8 characters long.***
259
261
260
262
In order to access the `SECRET_SSID` and `SECRET_PASS` constants in the **simpleWebServer.ino** sketch file, the header file that you’ve just created needs to be included. In your sketch file this has already been taken care of by the following line at the beginning of the sketch:
0 commit comments