MKR Zero Weather Data Logger

Read temperature and humidity values in a remote location and store the data in an SD card.

Nov 10, 2016

44868 views

49 respects

Components and supplies

1

Medium breadboard

1

Arduino MKR Zero

1

Resistor 4.75k ohm

1

microSD card

1

DHT22 Temperature and Humidity sensor

1

Capacitor 100 nF

3

Jumper wires (generic)

Apps and platforms

1

Arduino IDE

1

Arduino Web Editor

Project description

Code

Downloadable files

MKRZERO.png

MKRZERO.png

Comments

Only logged in users can leave comments

Anonymous user

2 years ago

My micro sd card is not being recognized for some reason. I tried two different ones too. It fails right here and prints out "Card Failed or not present". if (!SD.begin(chipSelect)) { Serial.println("Card failed, or not present"); // don't do anything more: return; Am I using the wrong chipselect port or something? I have it on SS1. Thanks in advance for the help guys.

Anonymous user

2 years ago

Fixed the issue!! I just had to update my SD library. Thanks for the help.

Anonymous user

2 years ago

I had same problem with SDcard using IDE 1.8.0. Then I uninstalled it and installed the previous version (Arduino IDE 1.6.11) and now SD card and sketch seem to work perfectly! Anyway, I lost a lot of time.... Chipselect SS1 is correct.

Anonymous user

2 years ago

Would MKRZero be suitable for long running battery applications?

Anonymous user

2 years ago

Yes of course, but you have to use low power politics like standby mode on event driven applications

Arduino_Genuino

2 years ago

yes, if you use low power politics like standby and event driven wakeups

Anonymous user

2 years ago

Can I use arduino uno in place of MKRZero? If yes, what changes do i have to make in the project?

Anonymous user

2 years ago

I have the same question!

Anonymous user

2 years ago

Either the code is flawed, or the battery I purchased is flawed because when on battery the temperature and humidity outputs are 'nan'. It works just fine when plugged into USB power.

Anonymous user

2 years ago

What is the maximum size of SD card that can be used?

Anonymous user

2 years ago

I am currently trying to get the code to run on my computer, I have followed all the steps but I still get an error code that tells me " Arduino: 1.8.0 (Windows 10), Board: "Arduino MKRZero" C:\\Users\\Tina\\Documents\\Arduino\\MKRZERO_Weather_Data_Logger\\MKRZERO_Weather_Data_Logger.ino:20:21: fatal error: RTCZero.h: No such file or directory #include <RTCZero.h> ^ compilation terminated. exit status 1 Error compiling for board Arduino MKRZero. This report would have more information with "Show verbose output during compilation" option enabled in File -> Preferences. " I checked all the Git hub repository libraries and it does look like it is missing that library that this code requires. I'm not sure where to find it. or, where could I find this library?

Arduino_Genuino

2 years ago

Hi! You need to install the RTCZero library using the library manager https://www.arduino.cc/en/Guide/Libraries#toc3

smellai

2 years ago

I can compile the sketch on the Web IDE: https://create.arduino.cc/editor/Arduino_Genuino/9a077c75-51b7-42b0-9a73-5e5b5562a429/preview RTCZero is a builtin library

Anonymous user

2 years ago

How long does the 1200mAh battery last? Apparently a raspberry pi zero can do this aw well, but maybe at a large amount of power consumption?

Anonymous user

2 years ago

Using this very cool tool http://www.digikey.com/en/resources/conversion-calculators/conversion-calculator-battery-life you can compute battery life for your application. Obviously this depends on the board power consumption and used low power politics. If you don't use any the MKRZero sinks about 20mA so a 1200mAh battery lasts for 42h

Anonymous user

2 years ago

The circuit diagram shows reversed polarity on battery connection. This is pretty serious mistake, please correct it.

Anonymous user

2 years ago

Great stuff! How do you charge the battery?

Anonymous user

2 years ago

I made a version of this project using a Pro Mini back in 2016 & made a poor quality video about it https://youtu.be/6YQyEG4u-vE A.H.W.

Anonymous user

2 years ago

How to calculate the voltage on Mkr zero? Is it voltage = sensor value *3.3/1023 Or sensor value *3.3/4095 Or (sensorValue / 4095) * 5;

Anonymous user

2 years ago

can we store the data in a pendrive instead? and use an UNO R3?

Anonymous user

3 years ago

The circuit diagram shows reversed polarity on battery connection. This is pretty serious mistake, please correct it.

Anonymous user

4 years ago

How to calculate the voltage on Mkr zero? Is it voltage = sensor value *3.3/1023 Or sensor value *3.3/4095 Or (sensorValue / 4095) * 5;

Anonymous user

6 years ago

What is the maximum size of SD card that can be used?

Anonymous user

7 years ago

Great stuff! How do you charge the battery?

Anonymous user

7 years ago

Either the code is flawed, or the battery I purchased is flawed because when on battery the temperature and humidity outputs are 'nan'. It works just fine when plugged into USB power.

Anonymous user

8 years ago

Can I use arduino uno in place of MKRZero? If yes, what changes do i have to make in the project?

Anonymous user

2 years ago

I have the same question!

suckyducky24_

8 years ago

can we store the data in a pendrive instead? and use an UNO R3?

Anonymous user

8 years ago

My micro sd card is not being recognized for some reason. I tried two different ones too. It fails right here and prints out "Card Failed or not present". if (!SD.begin(chipSelect)) { Serial.println("Card failed, or not present"); // don't do anything more: return; Am I using the wrong chipselect port or something? I have it on SS1. Thanks in advance for the help guys.

Anonymous user

2 years ago

Fixed the issue!! I just had to update my SD library. Thanks for the help.

tinacao

8 years ago

I am currently trying to get the code to run on my computer, I have followed all the steps but I still get an error code that tells me " Arduino: 1.8.0 (Windows 10), Board: "Arduino MKRZero" C:\\Users\\Tina\\Documents\\Arduino\\MKRZERO_Weather_Data_Logger\\MKRZERO_Weather_Data_Logger.ino:20:21: fatal error: RTCZero.h: No such file or directory #include <RTCZero.h> ^ compilation terminated. exit status 1 Error compiling for board Arduino MKRZero. This report would have more information with "Show verbose output during compilation" option enabled in File -> Preferences. " I checked all the Git hub repository libraries and it does look like it is missing that library that this code requires. I'm not sure where to find it. or, where could I find this library?

smellai

2 years ago

I can compile the sketch on the Web IDE: https://create.arduino.cc/editor/Arduino_Genuino/9a077c75-51b7-42b0-9a73-5e5b5562a429/preview RTCZero is a builtin library

Arduino_Genuino

2 years ago

Hi! You need to install the RTCZero library using the library manager https://www.arduino.cc/en/Guide/Libraries#toc3

Anonymous user

8 years ago

Would MKRZero be suitable for long running battery applications?

Arduino_Genuino

2 years ago

yes, if you use low power politics like standby and event driven wakeups

Anonymous user

2 years ago

Yes of course, but you have to use low power politics like standby mode on event driven applications

liuzengqiang

8 years ago

How long does the 1200mAh battery last? Apparently a raspberry pi zero can do this aw well, but maybe at a large amount of power consumption?

Anonymous user

2 years ago

Using this very cool tool http://www.digikey.com/en/resources/conversion-calculators/conversion-calculator-battery-life you can compute battery life for your application. Obviously this depends on the board power consumption and used low power politics. If you don't use any the MKRZero sinks about 20mA so a 1200mAh battery lasts for 42h