Skip to content

Commit 5b31185

Browse files
committed
cheat sheet updates
1 parent eede88a commit 5b31185

File tree

4 files changed

+58
-60
lines changed

4 files changed

+58
-60
lines changed
Binary file not shown.
Lines changed: 58 additions & 60 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
2-
title: 'MKR IoT Carrier Cheat Sheet'
3-
description: 'Learn how to set up the MKR IoT Carrier, get a quick overview of the compatible boards, components, and the library.'
4-
author: 'Liam Aljundi'
2+
title: 'MKR IoT Carrier Rev2 Cheat Sheet'
3+
description: 'Learn how to set up the MKR IoT Carrier Rev2, get a quick overview of the compatible boards, components, and the library.'
4+
author: 'Liam Aljundi, Karl Söderby'
55
tags:
66
- API
77
- Installation
@@ -10,16 +10,16 @@ libraries:
1010
- name: Arduino MKRIoTCarrier
1111
url: https://www.arduino.cc/reference/en/libraries/arduino_mkriotcarrier/
1212
hardware:
13-
- hardware/01.mkr/03.carriers/mkr-iot-carrier
13+
- hardware/01.mkr/03.carriers/mkr-iot-carrier-rev2
1414
---
1515

16-
![The Arduino MKR IoT Carrier](assets/mkrIotCarrier-overview.png)
16+
![The Arduino MKR IoT Carrier Rev2](assets/mkrIotCarrier-overview.png)
1717

18-
The Arduino® MKR IoT Carrier is equipped with different sensors, actuators and with a display to leave you free to focus on prototyping and programming your next IoT projects. The carrier does not come equipped with a microcontroller, meaning it only works in combination with an Arduino board. The MKR IoT Carrier comes equipped with 5 RGB LEDs, 5 capacitive touch buttons, a colored display, IMU and a variety of quality sensors. It also features a battery holder for a 18650 Li-Ion battery, SD card holder and Grove connectors.
18+
The Arduino® MKR IoT Carrier Rev2 is equipped with different sensors, actuators and with a display to leave you free to focus on prototyping and programming your next IoT projects. The carrier does not come equipped with a microcontroller, meaning it only works in combination with an Arduino board. The MKR IoT Carrier Rev2 comes equipped with 5 RGB LEDs, 5 capacitive touch buttons, a colored display, IMU and a variety of quality sensors. It also features a battery holder for a 18650 Li-Ion battery, SD card holder and Grove connectors.
1919

2020
## Compatible Boards
2121

22-
The MKR family of boards share a common pinout, meaning that they can all be easily connected to the MKR IoT Carrier. Here is a list of the MKR boards:
22+
The MKR family of boards share a common pinout, meaning that they can all be easily connected to the MKR IoT Carrier Rev2. Here is a list of the MKR boards:
2323

2424
- [MKR 1000 WiFi](https://docs.arduino.cc/hardware/mkr-1000-wifi)
2525
- [MKR FOX 1200](https://docs.arduino.cc/hardware/mkr-fox-1200)
@@ -35,19 +35,19 @@ The MKR family boards offer different features that can be useful for your proje
3535

3636
### Assembly
3737

38-
The chosen Arduino MKR board needs to be mounted on top of the MKR IoT Carrier and connected to a computer. The board can be connected as shown in the image below, matching the pin numbers on the board to the ones on the carrier.
38+
The chosen Arduino MKR board needs to be mounted on top of the MKR IoT Carrier Rev2 and connected to a computer. The board can be connected as shown in the image below, matching the pin numbers on the board to the ones on the carrier.
3939

40-
![Mounting board on the MKR IoT Carrier](assets/mkrIotCarrier-mounting-board.png)
40+
![Mounting board on the MKR IoT Carrier Rev2](assets/mkrIotCarrier-mounting-board.png)
4141

4242
## Datasheet
4343

4444
The full datasheet is available as a downloadable PDF from the link below:
4545

46-
- [Download the Arduino MKR IoT Carrier datasheet](https://content.arduino.cc/assets/MKR%20IoT%20Carrier%20-%20Datasheet.pdf?_gl=1*13zil78*_ga*MTgzMTI1MTI1Mi4xNjE3ODc1MzM2*_ga_NEXN8H46L5*MTYzMDQwMTY0OS4xMzAuMS4xNjMwNDA2MTcwLjA.)
46+
- [Download the Arduino MKR IoT Carrier Rev2 datasheet](https://content.arduino.cc/assets/MKR%20IoT%20Carrier%20-%20Datasheet.pdf?_gl=1*13zil78*_ga*MTgzMTI1MTI1Mi4xNjE3ODc1MzM2*_ga_NEXN8H46L5*MTYzMDQwMTY0OS4xMzAuMS4xNjMwNDA2MTcwLjA.)
4747

4848
## Arduino IoT Cloud
4949

50-
The MKR IoT Carrier can be controlled through the [Arduino IoT Cloud](https://create.arduino.cc/iot/things), a cloud service that allows us to create IoT applications in just minutes, if combined with an Arduino IoT Cloud compatible board. Here's a list of the Arduino MKR family boards that are compatible with the Arduino IoT Cloud:
50+
The MKR IoT Carrier Rev2 can be controlled through the [Arduino IoT Cloud](https://create.arduino.cc/iot/things), a cloud service that allows us to create IoT applications in just minutes, if combined with an Arduino IoT Cloud compatible board. Here's a list of the Arduino MKR family boards that are compatible with the Arduino IoT Cloud:
5151

5252
- [MKR 1000 WiFi](https://docs.arduino.cc/hardware/mkr-1000-wifi)
5353
- [MKR GSM 1400](https://docs.arduino.cc/hardware/mkr-gsm-1400)
@@ -62,25 +62,23 @@ If you need help to get started, you can go through the [Arduino IoT Cloud tutor
6262

6363
## Pinout
6464

65-
![The pinout for MKR IoT Carrier](assets/mkrIoTCarrier-pinout.png)
65+
![The pinout for MKR IoT Carrier Rev2](assets/mkrIoTCarrier-pinout.png)
6666

67-
To see the full pinout, you can download the PDF from the link below.
68-
69-
- [The MKR IoT Carrier full pinout (PDF)](https://content.arduino.cc/assets/Pinout-MKRIOTCARRIER_latest.pdf)
67+
The full pinout is available in the [resources section](/hardware/mkr-iot-carrie-rev2#resources).
7068

7169
## Grove Connectors
7270

73-
![Grove connectors on the MKR IoT Carrier](assets/mkriotcarrier-grove-connectors.png)
71+
![Grove connectors on the MKR IoT Carrier Rev2](assets/mkriotcarrier-grove-connectors.png)
7472

75-
The MKR IoT Carrier comes with **three grove connectors** (2 analog and 1 I2C) that enables us to easily connect external sensors. The type of the connector is labeled clearly on the back of the carrier.
73+
The MKR IoT Carrier Rev2 comes with **three grove connectors** (2 analog and 1 I2C) that enables us to easily connect external sensors. The type of the connector is labeled clearly on the back of the carrier.
7674

7775
## Carrier Library
7876

79-
To program the MKR IoT Carrier, the **[Arduino_MKRIoTCarrier](https://www.arduino.cc/reference/en/libraries/arduino_mkriotcarrier/)** library needs to be included. This library allows us to control and read all the components of the MKR IoT Carrier. Setting up the MKRIoTCarrier library requires an addition of few code lines in the **initialization** and **setup**. Practically speaking, the code used in the initialization and setup is rarely changed, and it is required in every sketch.
77+
To program the MKR IoT Carrier Rev2, the **[Arduino_MKRIoTCarrier](https://www.arduino.cc/reference/en/libraries/arduino_mkriotcarrier/)** library needs to be included. This library allows us to control and read all the components of the MKR IoT Carrier Rev2. Setting up the **Arduino_MKRIoTCarrier** library requires an addition of few code lines in the **initialization** and **setup**. Practically speaking, the code used in the initialization and setup is rarely changed, and it is required in every sketch.
8078

8179
### Initialization
8280

83-
In the initialization (the very top) of every sketch, the **MKRIoTCarrier** library needs to be included, which includes the individual libraries of the components mounted onto the carrier.
81+
In the initialization (the very top) of every sketch, the **Arduino_MKRIoTCarrier** library needs to be included, which includes the individual libraries of the components mounted onto the carrier.
8482

8583
Next, an object of type `MKRIoTCarrier` needs to be created. We'll call it `carrier` for simplicity.
8684

@@ -116,46 +114,46 @@ void setup() {
116114
}
117115
```
118116

119-
## Humidity & Temperature Sensor
117+
## BME680 Environmental Sensor
118+
119+
![The HTS221 Humidity Sensor on the MKR IoT Carrier Rev2](assets/mkrIotCarrier-sensor-temp&humi.png)
120120

121-
![The HTS221 Humidity Sensor on the MKR IoT Carrier](assets/mkrIotCarrier-sensor-temp&humi.png)
121+
The **[BME680 Environmental Sensor](https://www.bosch-sensortec.com/media/boschsensortec/downloads/datasheets/bst-bme688-ds000.pdf)** is a 4 in 1 sensor capable of providing the following measurements:
122+
- **Humidity**, 0‒100% r.H.
123+
- **Temperature**, -40 to +85 °C.
124+
- **Pressure**, 300-1100 hPa.
125+
- **Gas**, IAQ, VOC, CO2.
122126

123-
The **HTS221 Humidity Sensor** is mounted on the top side of the carrier under the display, marked with a drop icon. The sensor uses capacitive sensing with a **humidity sensing range** of **0-100%** and **accuracy** of **± 3.5% rH (20 to +80% rH)**, and a **temperature sensing range** of **-40 to 120° C**, with an **accuracy** of **± 0.5 °C,15 to +40 °C**. The sensor uses a low power consumption (2μA at 1 Hz sampling rate) and connects to the mounted Arduino MKR board through a I2C interface.
127+
BME680 is a low-power sensor with current consumption as low as **2.1 µA at 1 Hz**. It communicates over the I²C bus as other sensors onboard this carrier.
124128

125129
### Code
126130

127-
The values from the **temperature** and **humidity** sensors can be retrieved and stored in **float** variables as shown below.
131+
The values from the **temperature, humidity & pressure** can be retrieved and stored in **float** variables as shown below. For this, we need to use the `Env` class.
128132

129133
```arduino
130134
float temperature = carrier.Env.readTemperature();
135+
float temperature = carrier.Env.readTemperature(FAHRENHEIT);
131136
float humidity = carrier.Env.readHumidity();
137+
float pressure = carrier.Env.readPressure(); //returns value in kPa
132138
```
133139

134-
Temperature is returned in degrees Celsius, while relative humidity is returned in percentage.
135-
136-
The underlying library used to read the sensor is **[Arduino_HTS221](https://www.arduino.cc/reference/en/libraries/arduino_hts221/)**.
137-
138-
## Pressure Sensor
139-
140-
![The LPS22HBTR Pressure Sensor on the MKR IoT Carrier](assets/mkrIotCarrier-sensor-pressure.png)
140+
***Temperature is returned in degrees Celsius, while relative humidity is returned in percentage.***
141141

142-
The **LPS22HBTR Pressure Sensor** is mounted on the top side of the carrier under the display, marked with a meter icon. The sensor measures **absolute pressure range** of **260 to 1260 hPa (0.25 to 1.24 atm)** and connects to the mounted Arduino MKR board through a I2C interface.
143-
144-
### Code
145-
146-
The value from the **pressure** sensor, expressed in kiloPascal (kPa) can be retrieved and stored in a **float** variable as shown below.
142+
To access **gas** various values, we need to use the `AirQuality` class.
147143

148144
```arduino
149-
float pressure = carrier.Pressure.readPressure();
145+
float gasResistor = carrier.AirQuality.readGasResistor();
146+
float volatileOrganicCompounds = carrier.AirQuality.readVOC();
147+
float co2 = carrier.AirQuality.readCO2();
150148
```
151149

152-
The underlying library used to read the sensor is **[Arduino_LPS22HB](https://www.arduino.cc/reference/en/libraries/arduino_lps22hb/)**.
153-
154150
## IMU Accelerometer & Gyroscope Sensors
155151

156-
![The IMU on the MKR IoT Carrier](assets/mkrIotCarrier-sensor-imu.png)
152+
![The IMU on the MKR IoT Carrier Rev2](assets/mkrIotCarrier-sensor-imu.png)
153+
154+
### LSM6DSOXTR
157155

158-
The carrier includes a **LSM6DS3** sensor from STM which is an IMU (Inertial Measurement Unit) featuring a 3D digital accelerometer and a 3D digital gyroscope.
156+
The [LSM6DSOX](https://www.st.com/resource/en/datasheet/lsm6dsox.pdf) from STM is an IMU (Inertial Measurement Unit) that features a 3D digital **accelerometer** and a 3D digital **gyroscope**.
159157

160158
### Code
161159

@@ -188,13 +186,13 @@ carrier.IMUmodule.readAcceleration(x, y, z);
188186

189187
Reads acceleration data from the sensor on the three axis and assigns it to the provided variables.
190188

191-
The underlying library used to read the sensor is **[Arduino_LSM6DS3](https://www.arduino.cc/reference/en/libraries/arduino_lsm6ds3/)**.
189+
The underlying library used to read the sensor is **[LSM6DSOX](https://github.com/arduino-libraries/Arduino_LSM6DSOX)**.
192190

193191
## RGB and Gesture Sensor
194192

195-
![The APDS-9660 sensor on the MKR IoT Carrier](assets/mkrIotCarrier-sensor-rgb.png)
193+
![The APDS-9660 sensor on the MKR IoT Carrier Rev2](assets/mkrIotCarrier-sensor-rgb.png)
196194

197-
The MKR IoT Carrier contains a Broadcom **APDS-9660 RGB and Gesture sensors**, situated under the display and marked with a bulb icon. The sensor is useful for **ambient light** and **RGB** color sensing, **proximity** sensing, and **gesture** detection.
195+
The MKR IoT Carrier Rev2 contains a Broadcom **APDS-9660 RGB and Gesture sensors**, situated under the display and marked with a bulb icon. The sensor is useful for **ambient light** and **RGB** color sensing, **proximity** sensing, and **gesture** detection.
198196

199197
### Code
200198

@@ -259,9 +257,9 @@ The underlying library used to read the sensor is **[Arduino_APDS9960](https://w
259257

260258
## Relays
261259

262-
![The relays on the MKR IoT Carrier](assets/mkrIotCarrier-relays-01.png)
260+
![The relays on the MKR IoT Carrier Rev2](assets/mkrIotCarrier-relays-01.png)
263261

264-
The MKR IoT Carrier is equipped with two 5V Coil voltage **KEMET EE2-5NU-L relays**, located on the back side of the carrier. The relays are non-latching with a **COM** (common), **NO** (Normally open) and **NC** (normally closed) contacts, and can take up a max of **2A** Current and **24 V** of input each.
262+
The MKR IoT Carrier Rev2 is equipped with two 5V Coil voltage **KEMET EE2-5NU-L relays**, located on the back side of the carrier. The relays are non-latching with a **COM** (common), **NO** (Normally open) and **NC** (normally closed) contacts, and can take up a max of **2A** Current and **24 V** of input each.
265263

266264
The connections between a high power circuit and the relays will be done through these connectors.
267265

@@ -300,21 +298,21 @@ carrier.Relay2.getStatus();
300298

301299
### Display
302300

303-
![The MKR IoT Carrier's display](assets/mkrIotCarrier-display.png)
301+
![The MKR IoT Carrier Rev2's display](assets/mkrIotCarrier-display.png)
304302

305-
The screen on the MKR IoT Carrier is a **rounded 1.3” TFT display**, with a 240 x 240 resolution and a diameter of 36 x 40 mm.
303+
The screen on the MKR IoT Carrier Rev2 is a **rounded 1.3” TFT display**, with a 240 x 240 resolution and a diameter of 36 x 40 mm.
306304

307305
#### Code
308306

309-
The display is controlled through the `carrier.display` object which is an instance of the **Adafruit_ST7789** class, based on the more general **Adafruit_GFX** interface. Most tutorials mentioning **Adafruit_GFX** should be usable on your MKR IoT Carrier.
307+
The display is controlled through the `carrier.display` object which is an instance of the **Adafruit_ST7789** class, based on the more general **Adafruit_GFX** interface. Most tutorials mentioning **Adafruit_GFX** should be usable on your MKR IoT Carrier Rev2.
310308

311309
To get started, check the [Adafruit_GFX documentation](https://learn.adafruit.com/adafruit-gfx-graphics-library) and see the examples included in the Arduino_MKTIoTCarrier library.
312310

313311

314312

315313
](https://www.arduino.cc/reference/en/libraries/adafruit-st7735-and-st7789-library/), which is included in the carrier's library, meaning that it does not need to be added it separately.
316314

317-
We'll list here some of the most useful methods to configure the MKR IoT Carrier's display, including basic configurations, background and text colors, font size, position of the cursor and a loading animation.
315+
We'll list here some of the most useful methods to configure the MKR IoT Carrier Rev2's display, including basic configurations, background and text colors, font size, position of the cursor and a loading animation.
318316

319317
```arduino
320318
carrier.display.fillScreen(color);
@@ -370,11 +368,11 @@ This method will print the text inside the string at the current cursor position
370368

371369
#### More Resources
372370

373-
In order to develop a graphical user interface with the MKR IoT Carrier, the **[Arduino_OplaUI](https://www.arduino.cc/reference/en/libraries/arduino_oplaui/)** library can be used. This library uses the color LEDs, the buzzer and the touch buttons to build an interactive user interface featuring multiple pages. It also includes a few predefined gauges to display values. See the library examples to get started.
371+
In order to develop a graphical user interface with the MKR IoT Carrier Rev2, the **[Arduino_OplaUI](https://www.arduino.cc/reference/en/libraries/arduino_oplaui/)** library can be used. This library uses the color LEDs, the buzzer and the touch buttons to build an interactive user interface featuring multiple pages. It also includes a few predefined gauges to display values. See the library examples to get started.
374372

375373
### Buttons
376374

377-
![The MKR IoT Carrier's buttons](assets/mkrIotCarrier-buttons.png)
375+
![The MKR IoT Carrier Rev2's buttons](assets/mkrIotCarrier-buttons.png)
378376

379377
The carrier has five **capacitive touch buttons** on its top side, numbered from 0 to 4. The buttons are sensitive to direct touch and can also detect wireless touch.
380378

@@ -429,17 +427,17 @@ Replace `TOUCH0` with `TOUCH1`, `TOUCH2`, `TOUCH3`, `TOUCH4` in the examples abo
429427

430428
### LEDs
431429

432-
![The LEDs on the MKR IoT Carrier](assets/mkrIotCarrier-leds.png)
430+
![The LEDs on the MKR IoT Carrier Rev2](assets/mkrIotCarrier-leds.png)
433431

434-
The MKR IoT Carrier comes with 5 **digital RGB LEDs** placed on the top side of the carrier in front of the buttons.
432+
The MKR IoT Carrier Rev2 comes with 5 **digital RGB LEDs** placed on the top side of the carrier in front of the buttons.
435433

436434
#### Code
437435

438436
The LEDs are controlled with the Adafruit’s DotStar library, which is included in the `MKRIoTCarrier` library.
439437

440438
The `carrier.leds.show();` method is necessary for updating the new state of the LEDs and needs to be called after any change of the state of the LEDs (turning on & off or change of color).
441439

442-
Here are some of the useful methods used to control the LEDs on the MKR IoT Carrier:
440+
Here are some of the useful methods used to control the LEDs on the MKR IoT Carrier Rev2:
443441

444442
```arduino
445443
carrier.leds.setPixelColor(index, red, green, blue);
@@ -491,9 +489,9 @@ void setup() {
491489

492490
### Buzzer
493491

494-
![The buzzer on the MKR IoT Carrier](assets/mkriotcarrier-buzzer.png)
492+
![The buzzer on the MKR IoT Carrier Rev2](assets/mkriotcarrier-buzzer.png)
495493

496-
The MKR IoT Carrier is equipped with a **sound buzzer** on the bottom side of the carrier, under the MKR board.
494+
The MKR IoT Carrier Rev2 is equipped with a **sound buzzer** on the bottom side of the carrier, under the MKR board.
497495

498496
#### Code
499497

@@ -520,7 +518,7 @@ This method is a handy shortcut generating a beep. The two arguments are optiona
520518

521519
## Memory
522520

523-
The MKR IoT Carrier contains a **SD card slot** that accepts a Micro SD.
521+
The MKR IoT Carrier Rev2 contains a **SD card slot** that accepts a Micro SD.
524522

525523
### Code
526524

@@ -546,11 +544,11 @@ In order to learn more, check any of the many tutorials about using the `SD` lib
546544

547545
## Power
548546

549-
![JST battery connector on the MKR IoT Carrier.](assets/mkriotcarrier-battery.png)
547+
![JST battery connector on the MKR IoT Carrier Rev2.](assets/mkriotcarrier-battery.png)
550548

551-
The MKR IoT Carrier can be either powered through a USB cable connected to the mounted MKR board, or through a battery. The battery used should be a LI-ION 18650 3.7v battery, which can be mounted to the carrier via the battery holder on the bottom side.
549+
The MKR IoT Carrier Rev2 can be either powered through a USB cable connected to the mounted MKR board, or through a battery. The battery used should be a LI-ION 18650 3.7v battery, which can be mounted to the carrier via the battery holder on the bottom side.
552550

553-
In order to use the USB power to charge the battery, a little cable with JST connectors on both ends is needed between the MKR IoT Carrier and the MKR board. The bBattery can then be recharged via a USB connection through the MKR Board (runs up to 48h with a 3.7v 2500mAh).
551+
In order to use the USB power to charge the battery, a little cable with JST connectors on both ends is needed between the MKR IoT Carrier Rev2 and the MKR board. The bBattery can then be recharged via a USB connection through the MKR Board (runs up to 48h with a 3.7v 2500mAh).
554552

555553
<video width="100%" controls="true">
556554
<source src="assets/mkrIoTCarrier-battery-assembly.mp4" type="video/mp4"/>

0 commit comments

Comments
 (0)