Skip to content

Commit 9acb141

Browse files
committed
Image added
1 parent 614837f commit 9acb141

File tree

2 files changed

+5
-10
lines changed
  • content/hardware/06.nicla/boards/nicla-sense-env/tutorials/environmental-monitor-application-note

2 files changed

+5
-10
lines changed
428 KB
Loading

content/hardware/06.nicla/boards/nicla-sense-env/tutorials/environmental-monitor-application-note/content.md

Lines changed: 5 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -78,12 +78,7 @@ This application note uses advanced sensors to provide accurate, real-time measu
7878

7979
The AQI scale ranges from 0 to 500, with the following classifications:
8080

81-
- 0-50: Good air quality.
82-
- 51-100: Moderate air quality.
83-
- 101-150: Unhealthy for sensitive groups.
84-
- 151-200: Unhealthy for everyone.
85-
- 201-300: Very unhealthy.
86-
- 301-500: Hazardous conditions.
81+
![AQI scale ranges and health advice](assets/AQI.png)
8782

8883
The AQI makes it easy to understand how outdoor air quality affects public health, particularly when pollutant levels reach unhealthy or hazardous thresholds.
8984

@@ -222,7 +217,7 @@ uint32_t lastReadTime = 0;
222217
NiclaSenseEnv device;
223218
```
224219

225-
In the code snippet shown before:
220+
In the code snippet shown above:
226221

227222
- The `Arduino_NiclaSenseEnv` library is included to provide access to the onboard sensors.
228223
- The constant `READ_INTERVAL` defines the time between each sensor reading (10 seconds in this example).
@@ -253,7 +248,7 @@ void setup() {
253248
}
254249
```
255250

256-
In the code snippet shown before:
251+
In the code snippet shown above:
257252

258253
- Serial communication is initialized at `115200` baud rate, allowing data to be sent to the IDE's Serial Monitor.
259254
- The Nicla Sense Env board is initialized to read temperature, humidity and the outdoor Air Quality Index (AQI).
@@ -277,7 +272,7 @@ void loop() {
277272
}
278273
```
279274

280-
In the code snippet shown before:
275+
In the code snippet shown above:
281276

282277
- The `loop()` function continuously checks if the time interval (10 seconds) has passed since the last reading.
283278
- Once the interval is reached, the `displayAllData()` function is called to read sensor data.
@@ -335,7 +330,7 @@ The complete improved example sketch can be downloaded [here](assets/outdoor_air
335330

336331
## Improving the Simple Environmental Monitor Example Sketch
337332

338-
In the previous section, we explored setting up a simple environmental monitor using the Nicla Sense Env and the Portenta C33 boards. While the example sketch provided detailed readings on temperature, humidity and air quality, we can improve the example sketch by incorporating a visual indicator for the outdoor Air Quality Index (AQI).
333+
In the previous section, we explored setting up a simple environmental monitor using the Nicla Sense Env and the Portenta C33 board. While the example sketch provided detailed readings on temperature, humidity and air quality, we can improve the example sketch by incorporating a visual indicator for the outdoor Air Quality Index (AQI).
339334

340335
In this section, we will improve the example sketch by adding control of the onboard RGB LED on the Nicla Sense Env board. The RGB LED will provide a visual representation of the outdoor AQI, changing colors based on its value.
341336

0 commit comments

Comments
 (0)