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/05.nicla/boards/nicla-sense-me/tutorials/connecting-to-iot-cloud/content.md
+23-23Lines changed: 23 additions & 23 deletions
Original file line number
Diff line number
Diff line change
@@ -20,29 +20,29 @@ software:
20
20
21
21
## Overview
22
22
23
-
In this tutorial you will learn how to upload data from the Nicla module to the IoT Cloud. You will use the **Portenta H7** to interface with the **Nicla Sense ME** using the eslov connector and upload the data using the Portenta Wireless capabilities.
23
+
In this tutorial you will learn how to upload data from the Nicla module to the IoT Cloud. You will use the **Portenta H7** to interface with the **Nicla Sense ME** using the ESLOV connector and upload the data using the Portenta Wireless capabilities.
24
24
25
25
## Goals
26
26
27
-
- How to configure the Portenta H7 to read temperature values from the Nicla Sense using the ESLOV connector.
28
-
- How to Connect the Portenta H7 to the IoT cloud
29
-
- Publish the temperature values that we obtained from the Nicla board to the Arduino IoT Cloud.
27
+
- How to configure the Portenta H7 to read temperature values from the Nicla Sense ME using the ESLOV connector.
28
+
- How to Connect the Portenta H7 to the Arduino IoT Cloud
29
+
- Publish the temperature values that you obtained from the Nicla board to the Arduino IoT Cloud.
For the hardware setup just connect the Nicla board to the Portenta H7 using the Eslov cable like in the illustration below. Then connect the Portenta H7 to your computer using an USB-C cable.
45
+
For the hardware setup, just connect the Nicla board to the Portenta H7 using the ESLOV cable like in the illustration below. Then connect the Portenta H7 to your computer using an USB-C cable.
46
46
47
47

48
48
@@ -58,11 +58,11 @@ For further tips on how to operate the Nicla module check the [cheat sheet](http
58
58
59
59
### Client Board (Nicla Sense ME)
60
60
61
-
The **Nicla Sense ME** will be listening to the Host board to send back the required data, this is all automated by the libraries **Arduino_BHY2** and **Arduino_BHY2Host**
61
+
The **Nicla Sense ME** will be listening to the Host board to send back the required data, this is all automated via the libraries **Arduino_BHY2** and **Arduino_BHY2Host**
62
62
63
-
The code its available inside the examples provided with the **Arduino_BHY2** Library. Open it by going to **Examples > Arduino_BHY2 > App.ino**
63
+
The code is available inside the examples provided with the **Arduino_BHY2** Library. Open it by going to **Examples > Arduino_BHY2 > App.ino**
64
64
65
-
This is the code, which initialize the sensors, and maintain the communication
65
+
This is the code, which initialize the sensors, and maintain the communication:
66
66
67
67
```cpp
68
68
/*
@@ -85,22 +85,22 @@ void loop(){
85
85
}
86
86
```
87
87
88
-
### Set up the IoT Cloud
88
+
### Set up the Arduino IoT Cloud
89
89
90
-
To configure the IoT cloud you can follow this [tutorial](content/cloud/iot-cloud/tutorials/iot-cloud-getting-started).
90
+
To configure the Arduino IoT cloud you can follow this [tutorial](content/cloud/iot-cloud/tutorials/iot-cloud-getting-started).
91
91
92
92
93
-
Create a new thing at <https://create.arduino.cc/iot/things>, we called it "PRO - Portenta and Nicla". You will need to attach the Portenta H7 as a new device to your **Thing setup.** After that go to **Variables** and click the **add** button and select a float variable called **temperature** to store the temperature readings.
93
+
Create a new Thing at <https://create.arduino.cc/iot/things>, you can call it "PRO - Portenta and Nicla". You will need to attach the Portenta H7 as a new device to your **Thing setup.** After that, go to **Variables**, click the **add** button and select a float variable called **temperature** to store the temperature readings.
***Remember to add your Wi-Fi SSID name, and its password (you can do that inside the Thing setup tab) to be able to connect to the Arduino IoT Cloud.***
97
+
***Remember to add your Wi-Fi SSID name and its password (you can do that inside the Thing setup tab) to be able to connect to the Arduino IoT Cloud.***
98
98
99
99
### Host Board: Edit the Cloud Sketch
100
100
101
-
You can edit the sketch by clicking the **sketch tab** inside your **Thing page**. The sketch is automatically generated with the enough code to upload it and connect to the cloud.
101
+
You can edit the sketch by clicking the **sketch tab** inside your **Thing page**. The sketch is automatically generated with enough code to upload it and connect it to the Cloud.
102
102
103
-
Before uploading you should add the following code:
103
+
Before uploading, you should add the following code:
104
104
105
105
First include the headers that you need and declare the temperature sensor by adding the **temperature sensor ID**.
***You can find all the Sensor IDs at <https://docs.arduino.cc/tutorials/nicla-sense-me/cheat-sheet#sensor-ids>.***
116
116
117
-
Inside `void setup()` initialize the `Serial` communication, configure the variables and configuration for the Arduino IoT Cloud(properties), wait until the **Portenta H7** is connected to the Wi-Fi and IoT Cloud and after that it will setup the communication with the **Nicla Sense ME** and configure the temperature sensor.
117
+
Inside `void setup()` initialize the `Serial` communication, set up the variables and configuration for the Arduino IoT Cloud(properties) and wait until the **Portenta H7** is connected to the Wi-Fi and IoT Cloud. At this point, the communication with the **Nicla Sense ME** will be set up and you can start configuring the temperature sensor.
118
118
119
119
***Note: Now we are using "NICLA_VIA_ESLOV". In case you mount it as a shield use "NICLA_AS_SHIELD" as the second parameter of the `begin()` function, or "NICLA_VIA_BLE" if you use Bluetooth® Low Energy.***
120
120
@@ -150,11 +150,11 @@ Inside `void setup()` initialize the `Serial` communication, configure the varia
150
150
}
151
151
```
152
152
153
-
***If you use `yourSensor.begin()` it will be configured the same as with `yourSensor.configure(1,0)`.***
153
+
***If you use `yourSensor.begin()`, it will be configured the same as with `yourSensor.configure(1,0)`.***
154
154
155
-
If the Nicla Sense ME shall communicate through Bluetooth® Low Energy, we recommend wrapping `BHY2Host.begin(false, NICLA_VIA_BLE)` in a `while` clause to make sure the connection is established before the sketch continues.
155
+
If the Nicla Sense ME communicates through Bluetooth® Low Energy, we recommend wrapping `BHY2Host.begin(false, NICLA_VIA_BLE)` in a `while` clause to make sure the connection is established before the sketch continues.
156
156
157
-
Inside the `void loop()` function you will make the **Portenta H7** get all the needed data from the **Nicla Sense ME**, store and print the temperature sensor's value and update the data to the IoT Cloud.
157
+
Inside the `void loop()` function you will make the **Portenta H7** get all the needed data from the **Nicla Sense ME**, store and print the temperature sensor value and update the data to the Arduino IoT Cloud.
158
158
159
159
```cpp
160
160
voidloop(){
@@ -168,7 +168,7 @@ void loop(){
168
168
}
169
169
```
170
170
171
-
Upload the sketch from the **sketch tab** by clicking the second button at the top left of the left side of the sketch bar. Once it has been uploaded you can see the temperature value that it is being uploaded by going to your **Thing Setup** tab, and looking at the last value of the **temperature**'s value, you can also open the serial monitor to see the live data.
171
+
Upload the sketch from the **sketch tab** by clicking the second button at the top left of the left side of the sketch bar. Once it has been uploaded, you can see the temperature value just uploaded by going to your **Thing Setup** tab and looking at the last value of the **temperature** variable. You can also open the Serial Monitor to see your data live.
In this tutorial you learned how to upload the temperature values from the Nicla sense to the IoT cloud. You followed the process to set up the Nicla board to send data via the Eslov connection, and you configured the IoT cloud to receive the temperature data.
245
+
In this tutorial you learned how to upload the temperature values from the Nicla Sense ME to the Arduino IoT Cloud. You followed the process to set up the Nicla board in order to send data via ESLOV connection and you configured the Arduino IoT Cloud to receive the temperature data.
246
246
247
247
### Next Steps
248
248
249
-
- Try to upload other sensor data from he Nicla sense. You can see the available sensors in the [cheat sheet](https://docs.arduino.cc/tutorials/nicla-sense-me/cheat-sheet#sensor-data-over-eslov).
249
+
- Try to upload other sensor data from he Nicla Sense ME. You can see the available sensors in the [cheat sheet](https://docs.arduino.cc/tutorials/nicla-sense-me/cheat-sheet#sensor-data-over-eslov).
250
250
- Experiment with the dashboard to add more data for a more sophisticated project.
0 commit comments