Oplà IoT Kit really works?

Probably I am the worst "Arduiner" around the world, but I don't understand way NONE of the templates' codes that appear as "ready to go" examples in create.arduino.cc works in any way and they are full of errors, bugs, lack of libraries that don't are in the documentation...

I purchased this kit to avoid waste hours configuring things and it seems that any Arduino Uno with conventional sensors and the traditional IDE and libraries would make me save 100€ and more than 100 hours already spent.

Does anybody if this code has been actually debugged? Does anybody demostrate that it works?

I'm desperate, indeed.

Any help would be pretty appreciated.

Thanks to the community.

Paco L.

Most of the people here on the forum won't be familiar with the "codes" you are referring to. However, some of those same people would likely be able to help you if you provide more details, such as:

  • Links to the specific "codes" you are having trouble with.
  • Full and exact text of any error or warning messages you might be getting.

Hi,

Thanks for your support and help. For sure that these little issues will be solved with good will from all parties.

Links with the templates:

https://create.arduino.cc/iot/templates

Link with Smart Garden template:

https://create.arduino.cc/iot/templates/smart-garden

Error text when importing template:

/Smart_Garden_nov23a.ino:106:32: error: 'ST77XX_WHITE' was not declared in this scope carrier.display.setTextColor(ST77XX_WHITE); ^~~~~~~~~~~~ /tmp/200332876/Smart_Garden_nov23a/Smart_Garden_nov23a.ino:106:32: note: suggested alternative: 'T_WRITE' carrier.display.setTextColor(ST77XX_WHITE); ^~~~~~~~~~~~ T_WRITE /tmp/200332876/Smart_Garden_nov23a/Smart_Garden_nov23a.ino:107:11: error: 'class MKRIoTCarrier' has no member named 'display' carrier.display.setTextSize(3); ^~~~~~~ /tmp/200332876/Smart_Garden_nov23a/Smart_Garden_nov23a.ino:109:11: error: 'class MKRIoTCarrier' has no member named 'display' carrier.display.setCursor(40, 50); ^~~~~~~ /tmp/200332876/Smart_Garden_nov23a/Smart_Garden_nov23a.ino:110:11: error: 'class MKRIoTCarrier' has no member named 'display' carrier.display.print(waterPumpState); ^~~~~~~ /tmp/200332876/Smart_Garden_nov23a/Smart_Garden_nov23a.ino:111:11: error: 'class MKRIoTCarrier' has no member named 'display' carrier.display.setCursor(40, 90); ^~~~~~~ /tmp/200332876/Smart_Garden_nov23a/Smart_Garden_nov23a.ino:112:11: error: 'class MKRIoTCarrier' has no member named 'display' carrier.display.print(coolingFanState); ^~~~~~~ /tmp/200332876/Smart_Garden_nov23a/Smart_Garden_nov23a.ino:113:11: error: 'class MKRIoTCarrier' has no member named 'display' carrier.display.setCursor(40, 130); ^~~~~~~ /tmp/200332876/Smart_Garden_nov23a/Smart_Garden_nov23a.ino:114:11: error: 'class MKRIoTCarrier' has no member named 'display' carrier.display.print(lightState); ^~~~~~~ Error during build: exit status 1

Full tutorial Link for the same project;

https://opla.arduino.cc/opla/module/iot-starter-kit-maker/lesson/06-smart-garden?_gl=1mpo9fc_gaMjAwMTE5NDUzNi4xNjM3NjYxODA1_ga_NEXN8H46L5*MTYzNzY2NjYzNy4yLjEuMTYzNzY2NjY3Ny4w

Code Import link for this project

Arduino IoT Cloud139eo1x_gaMjAwMTE5NDUzNi4xNjM3NjYxODA1_ga_NEXN8H46L5*MTYzNzY2NjYzNy4yLjEuMTYzNzY2Njk2OC4w

Error when import the code from that link:

/Smart_Garden_nov23a.ino:106:32: error: 'ST77XX_WHITE' was not declared in this scope carrier.display.setTextColor(ST77XX_WHITE); ^~~~~~~~~~~~ /tmp/020614087/Smart_Garden_nov23a/Smart_Garden_nov23a.ino:106:32: note: suggested alternative: 'T_WRITE' carrier.display.setTextColor(ST77XX_WHITE); ^~~~~~~~~~~~ T_WRITE /tmp/020614087/Smart_Garden_nov23a/Smart_Garden_nov23a.ino:107:11: error: 'class MKRIoTCarrier' has no member named 'display' carrier.display.setTextSize(3); ^~~~~~~ /tmp/020614087/Smart_Garden_nov23a/Smart_Garden_nov23a.ino:109:11: error: 'class MKRIoTCarrier' has no member named 'display' carrier.display.setCursor(40, 50); ^~~~~~~ /tmp/020614087/Smart_Garden_nov23a/Smart_Garden_nov23a.ino:110:11: error: 'class MKRIoTCarrier' has no member named 'display' carrier.display.print(waterPumpState); ^~~~~~~ /tmp/020614087/Smart_Garden_nov23a/Smart_Garden_nov23a.ino:111:11: error: 'class MKRIoTCarrier' has no member named 'display' carrier.display.setCursor(40, 90); ^~~~~~~ /tmp/020614087/Smart_Garden_nov23a/Smart_Garden_nov23a.ino:112:11: error: 'class MKRIoTCarrier' has no member named 'display' carrier.display.print(coolingFanState); ^~~~~~~ /tmp/020614087/Smart_Garden_nov23a/Smart_Garden_nov23a.ino:113:11: error: 'class MKRIoTCarrier' has no member named 'display' carrier.display.setCursor(40, 130); ^~~~~~~ /tmp/020614087/Smart_Garden_nov23a/Smart_Garden_nov23a.ino:114:11: error: 'class MKRIoTCarrier' has no member named 'display' carrier.display.print(lightState); ^~~~~~~ Error during build: exit status 1

Step by step process to build this project link:

https://opla.arduino.cc/opla/module/iot-starter-kit-maker-long/lesson/smart-garden-long

I did follow all the entire process to create the thing, dashboard, variables, assigh board, connect it to the cloud and install the code and it fails every time.

This is the full code:

#include "thingProperties.h"

#include <Arduino_MKRIoTCarrier.h>

MKRIoTCarrier carrier;

int moistPin = A5;

String waterPumpState;

String coolingFanState;

String lightState;

uint32_t lightsOn = carrier.leds.Color(82, 118, 115);

uint32_t lightsOff = carrier.leds.Color(0, 0, 0);

void setup() {

// Initialize serial and wait for port to open:

Serial.begin(9600);

delay(1500);

// Defined in thingProperties.h

initProperties();

// Connect to Arduino IoT Cloud

ArduinoCloud.begin(ArduinoIoTPreferredConnection);

//Get Cloud Info/errors , 0 (only errors) up to 4

setDebugMessageLevel(2);

ArduinoCloud.printDebugInfo();

//Wait to get cloud connection to init the carrier

while (ArduinoCloud.connected() != 1) {

ArduinoCloud.update();

delay(500);

}

delay(500);

CARRIER_CASE = false;

carrier.begin();

carrier.display.setRotation(0);

delay(1500);

}

void loop() {

//Update the Cloud

ArduinoCloud.update();

//read temperature and humidity

temperature = carrier.Env.readTemperature();

humidity = carrier.Env.readHumidity();

//read raw moisture value

int raw_moisture = analogRead(moistPin);

//map raw moisture to a scale of 0 - 100

moisture = map(raw_moisture, 0, 1023, 100, 0);

//read ambient light

while (!carrier.Light.colorAvailable()) {

delay(5);

}

int none; //We dont need RGB colors

carrier.Light.readColor(none, none, none, light);

delay(100);

}

void onWaterpumpChange() {

if (waterpump == true) {

carrier.Relay2.open();

waterPumpState = "PUMP: ON";

} else {

carrier.Relay2.close();

waterPumpState = "PUMP: OFF";

}

updateScreen();

}

void onCoolingFanChange() {

if (cooling_fan == true) {

carrier.Relay1.open();

coolingFanState = "FAN: ON";

} else {

carrier.Relay1.close();

coolingFanState = "FAN: OFF";

}

updateScreen();

}

void onArtificialLightChange() {

if (artificial_light == true) {

carrier.leds.fill(lightsOn, 0, 5);

carrier.leds.show();

lightState = "LIGHTS: ON";

} else {

carrier.leds.fill(lightsOff, 0, 5);

carrier.leds.show();

lightState = "LIGHTS: OFF";

}

updateScreen();

}

//Update displayed Info

void updateScreen() {

carrier.display.fillScreen(ST77XX_BLACK);

carrier.display.setTextColor(ST77XX_WHITE);

carrier.display.setTextSize(3);

carrier.display.setCursor(40, 50);

carrier.display.print(waterPumpState);

carrier.display.setCursor(40, 90);

carrier.display.print(coolingFanState);

carrier.display.setCursor(40, 130);

carrier.display.print(lightState);

}

Errors when verifying:

In file included from /tmp/270604951/Smart_Garden_nov22a/Arduino_MKRIoTCarrier.cpp:21:0:

/mnt/create-efs/webide/73/65/7365eb3d33e519d58afd5a8474000a0d:paquo/libraries_v2/Arduino_MKRIoTCarrier/src/Arduino_MKRIoTCarrier.h:120:5: error: 'Adafruit_ST7789' does not name a type; did you mean 'Adafruit_DotStar'?

Adafruit_ST7789 display = Adafruit_ST7789(&SPI, TFT_CS, TFT_DC, -1);

^~~~~~~~~~~~~~~

Adafruit_DotStar

/tmp/270604951/Smart_Garden_nov22a/Arduino_MKRIoTCarrier.cpp: In member function 'int MKRIoTCarrier::begin()':

/tmp/270604951/Smart_Garden_nov22a/Arduino_MKRIoTCarrier.cpp:32:3: error: 'display' was not declared in this scope

display.init(240, 240);//.begin(true); // Initialize ST7789 screen

^~~~~~~

/tmp/270604951/Smart_Garden_nov22a/Arduino_MKRIoTCarrier.cpp:32:3: note: suggested alternative: 'delay'

display.init(240, 240);//.begin(true); // Initialize ST7789 screen

^~~~~~~

delay

/tmp/270604951/Smart_Garden_nov22a/Arduino_MKRIoTCarrier.cpp:37:22: error: 'ST77XX_BLACK' was not declared in this scope

display.fillScreen(ST77XX_BLACK);

^~~~~~~~~~~~

In file included from /tmp/270604951/Smart_Garden_nov22a/Smart_Garden_nov22a.ino:3:0:

/mnt/create-efs/webide/73/65/7365eb3d33e519d58afd5a8474000a0d:paquo/libraries_v2/Arduino_MKRIoTCarrier/src/Arduino_MKRIoTCarrier.h:121:5: error: 'Adafruit_ST7789' does not name a type; did you mean 'Adafruit_DotStar'?

Adafruit_ST7789 display = Adafruit_ST7789(&SPI, TFT_CS, TFT_DC, -1);

^~~~~~~~~~~~~~~

Adafruit_DotStar

/tmp/270604951/Smart_Garden_nov22a/Smart_Garden_nov22a.ino: In function 'void setup()':

/tmp/270604951/Smart_Garden_nov22a/Smart_Garden_nov22a.ino:39:11: error: 'class MKRIoTCarrier' has no member named 'display'

carrier.display.setRotation(0);

^~~~~~~

/tmp/270604951/Smart_Garden_nov22a/Smart_Garden_nov22a.ino: In function 'void updateScreen()':

/tmp/270604951/Smart_Garden_nov22a/Smart_Garden_nov22a.ino:105:11: error: 'class MKRIoTCarrier' has no member named 'display'

carrier.display.fillScreen(ST77XX_BLACK);

^~~~~~~

/tmp/270604951/Smart_Garden_nov22a/Smart_Garden_nov22a.ino:105:30: error: 'ST77XX_BLACK' was not declared in this scope

carrier.display.fillScreen(ST77XX_BLACK);

^~~~~~~~~~~~

/tmp/270604951/Smart_Garden_nov22a/Smart_Garden_nov22a.ino:106:11: error: 'class MKRIoTCarrier' has no member named 'display'

carrier.display.setTextColor(ST77XX_WHITE);

^~~~~~~

/tmp/270604951/Smart_Garden_nov22a/Smart_Garden_nov22a.ino:106:32: error: 'ST77XX_WHITE' was not declared in this scope

carrier.display.setTextColor(ST77XX_WHITE);

^~~~~~~~~~~~

/tmp/270604951/Smart_Garden_nov22a/Smart_Garden_nov22a.ino:106:32: note: suggested alternative: 'T_WRITE'

carrier.display.setTextColor(ST77XX_WHITE);

^~~~~~~~~~~~

T_WRITE

/tmp/270604951/Smart_Garden_nov22a/Smart_Garden_nov22a.ino:107:11: error: 'class MKRIoTCarrier' has no member named 'display'

carrier.display.setTextSize(3);

^~~~~~~

/tmp/270604951/Smart_Garden_nov22a/Smart_Garden_nov22a.ino:109:11: error: 'class MKRIoTCarrier' has no member named 'display'

carrier.display.setCursor(40, 50);

^~~~~~~

/tmp/270604951/Smart_Garden_nov22a/Smart_Garden_nov22a.ino:110:11: error: 'class MKRIoTCarrier' has no member named 'display'

carrier.display.print(waterPumpState);

^~~~~~~

/tmp/270604951/Smart_Garden_nov22a/Smart_Garden_nov22a.ino:111:11: error: 'class MKRIoTCarrier' has no member named 'display'

carrier.display.setCursor(40, 90);

^~~~~~~

/tmp/270604951/Smart_Garden_nov22a/Smart_Garden_nov22a.ino:112:11: error: 'class MKRIoTCarrier' has no member named 'display'

carrier.display.print(coolingFanState);

^~~~~~~

/tmp/270604951/Smart_Garden_nov22a/Smart_Garden_nov22a.ino:113:11: error: 'class MKRIoTCarrier' has no member named 'display'

carrier.display.setCursor(40, 130);

^~~~~~~

/tmp/270604951/Smart_Garden_nov22a/Smart_Garden_nov22a.ino:114:11: error: 'class MKRIoTCarrier' has no member named 'display'

carrier.display.print(lightState);

^~~~~~~

Error during build: exit status 1

I'm going to ask you to post some additional information that might help us to identify the problem.
Please do this:

  1. Open your Things list: https://create.arduino.cc/iot/things
  2. Click "Smart Garden".
  3. Click the "Sketch" tab.
  4. Click the :heavy_check_mark: (verify) button.
  5. After the compilation fails, click the icon in the top right corner of the black console window at the bottom of the Arduino Web Editor window that looks like two pieces of paper.
    image
  6. In a forum reply here, click on the reply field.
  7. Click the </> button on the forum toolbar. This will add the forum's code block markup (```) to your reply to make sure the compilation output is correctly formatted.
    codetags
  8. Press Ctrl+V. This will paste the compilation output between the code tags.
  9. Move the cursor outside of the code tags before you add any additional text to your reply.
  10. Click the Reply button to post the output.
Start verifying
/tmp/arduino-build-E66D3EDC51466BE911209192632374DB/libraries/arduino_mkriotcarrier_1_0_2/objs.a(Arduino_MKRIoTCarrier.cpp.o): In function `MKRIoTCarrier::MKRIoTCarrier()':
/home/builder/opt/libraries/latest/arduino_mkriotcarrier_1_0_2/src/Arduino_MKRIoTCarrier.cpp:27: multiple definition of `MKRIoTCarrier::MKRIoTCarrier()'
/tmp/arduino-build-E66D3EDC51466BE911209192632374DB/sketch/objs.a(Arduino_MKRIoTCarrier.cpp.o):/tmp/152600161/Smart_Garden_nov22a/Arduino_MKRIoTCarrier.cpp:27: first defined here
/tmp/arduino-build-E66D3EDC51466BE911209192632374DB/libraries/arduino_mkriotcarrier_1_0_2/objs.a(Arduino_MKRIoTCarrier.cpp.o): In function `MKRIoTCarrier::MKRIoTCarrier()':
/home/builder/opt/libraries/latest/arduino_mkriotcarrier_1_0_2/src/Arduino_MKRIoTCarrier.cpp:27: multiple definition of `MKRIoTCarrier::MKRIoTCarrier()'
/tmp/arduino-build-E66D3EDC51466BE911209192632374DB/sketch/objs.a(Arduino_MKRIoTCarrier.cpp.o):/tmp/152600161/Smart_Garden_nov22a/Arduino_MKRIoTCarrier.cpp:27: first defined here
/tmp/arduino-build-E66D3EDC51466BE911209192632374DB/libraries/arduino_mkriotcarrier_1_0_2/objs.a(Arduino_MKRIoTCarrier.cpp.o): In function `MKRIoTCarrier::begin()':
/home/builder/opt/libraries/latest/arduino_mkriotcarrier_1_0_2/src/Arduino_MKRIoTCarrier.cpp:30: multiple definition of `MKRIoTCarrier::begin()'
/tmp/arduino-build-E66D3EDC51466BE911209192632374DB/sketch/objs.a(Arduino_MKRIoTCarrier.cpp.o):/tmp/152600161/Smart_Garden_nov22a/Arduino_MKRIoTCarrier.cpp:30: first defined here
/tmp/arduino-build-E66D3EDC51466BE911209192632374DB/libraries/arduino_mkriotcarrier_1_0_2/objs.a(Arduino_MKRIoTCarrier.cpp.o):(.bss.CARRIER_CASE+0x0): multiple definition of `CARRIER_CASE'
/tmp/arduino-build-E66D3EDC51466BE911209192632374DB/sketch/objs.a(Arduino_MKRIoTCarrier.cpp.o):(.bss.CARRIER_CASE+0x0): first defined here
collect2: error: ld returned 1 exit status
Error during build: exit status 1

/tmp/arduino-build-E66D3EDC51466BE911209192632374DB/libraries/arduino_mkriotcarrier_1_0_2/objs.a(Arduino_MKRIoTCarrier.cpp.o): In function `MKRIoTCarrier::MKRIoTCarrier()':
/home/builder/opt/libraries/latest/arduino_mkriotcarrier_1_0_2/src/Arduino_MKRIoTCarrier.cpp:27: multiple definition of `MKRIoTCarrier::MKRIoTCarrier()'
/tmp/arduino-build-E66D3EDC51466BE911209192632374DB/sketch/objs.a(Arduino_MKRIoTCarrier.cpp.o):/tmp/152600161/Smart_Garden_nov22a/Arduino_MKRIoTCarrier.cpp:27: first defined here
/tmp/arduino-build-E66D3EDC51466BE911209192632374DB/libraries/arduino_mkriotcarrier_1_0_2/objs.a(Arduino_MKRIoTCarrier.cpp.o): In function `MKRIoTCarrier::MKRIoTCarrier()':
/home/builder/opt/libraries/latest/arduino_mkriotcarrier_1_0_2/src/Arduino_MKRIoTCarrier.cpp:27: multiple definition of `MKRIoTCarrier::MKRIoTCarrier()'
/tmp/arduino-build-E66D3EDC51466BE911209192632374DB/sketch/objs.a(Arduino_MKRIoTCarrier.cpp.o):/tmp/152600161/Smart_Garden_nov22a/Arduino_MKRIoTCarrier.cpp:27: first defined here
/tmp/arduino-build-E66D3EDC51466BE911209192632374DB/libraries/arduino_mkriotcarrier_1_0_2/objs.a(Arduino_MKRIoTCarrier.cpp.o): In function `MKRIoTCarrier::begin()':
/home/builder/opt/libraries/latest/arduino_mkriotcarrier_1_0_2/src/Arduino_MKRIoTCarrier.cpp:30: multiple definition of `MKRIoTCarrier::begin()'
/tmp/arduino-build-E66D3EDC51466BE911209192632374DB/sketch/objs.a(Arduino_MKRIoTCarrier.cpp.o):/tmp/152600161/Smart_Garden_nov22a/Arduino_MKRIoTCarrier.cpp:30: first defined here
/tmp/arduino-build-E66D3EDC51466BE911209192632374DB/libraries/arduino_mkriotcarrier_1_0_2/objs.a(Arduino_MKRIoTCarrier.cpp.o):(.bss.CARRIER_CASE+0x0): multiple definition of `CARRIER_CASE'
/tmp/arduino-build-E66D3EDC51466BE911209192632374DB/sketch/objs.a(Arduino_MKRIoTCarrier.cpp.o):(.bss.CARRIER_CASE+0x0): first defined here
collect2: error: ld returned 1 exit status
Error during build: exit status 1

Hi all,

I had open a case with Arduino and Truss Kongdet (the tecnician in charge for this case) has helped me to solve the issue and now is working fine.

I had to revise the version of the board's firmware, the version of the Create Agent and the most important, it is a must to delete ALL custom libraries who would be able to interfere with the libraries that the templates will use.

That's done and my Smart Garden "thing" is working as expected.

I will try the others and I will post here my comments.

Opla IoT kit actually works... but documentation is not the best that one's expecting.

Thanks to all the people who collaborate to solve the issue. Special mention to Truss.

Paco L.

Thanks for taking the time to post an update. I'm glad to hear you have it working now!

FYI, the only one of those three things that was necessary to solve the compilation errors you shared is deleting the libraries. The other two will never fix a compilation error (though they could fix other problems).

Thanks to you for your patience!

But there was a simultaneous error about hardware which obligued to update firmware, agents, etc.

Now, it seems to work. The problem now (I'm in constant sorrow) is that MKR 1010 are unavailable in the market...

If you are looking for a board to use with the Arduino IoT Cloud in general (rather than with the Opla kit specifically), check out the Nano 33 IoT. It uses the same ATSAMD21G18 and "NINA" WiFi modem (ESP32) as the MKR WiFi 1010, so the same code will work on either board. The main difference between the two boards is the different form factor (which means you can't plug the Nano 33 IoT into the Opla's MKR IoT Carrier: