Arduino Wifi Temperature Logger

22,249

83

50

Posted

Introduction: Arduino Wifi Temperature Logger

This is a simple demo using the ESP8266 and Cactus Micro (a arduino compatible board) to update a remote server (https://data.sparkfun.com/) using a digital temperature sensor.

Step 1: Materials

The Cactus Micro is an arduino compatible dev board, it integrated a WIFI chip ESP8266.

Step 2: Connecting the Wires Together

  • Connect esp8266 module is easy. Just plug in to the pins.
  • DS18B20 - DQ(2) -> Cactus pin 14, DQ(2) -> 4.7KR -> VCC(3.3V)

Step 3: Arduino Setup and Sketch

The sketch code: https://github.com/AprilBrother/cactus-micro/blob/...

For Cactus Micro Rev2, the default firmware for esp8266 is espduino. Please use this sketch instead. https://github.com/AprilBrother/cactus-micro-r2/tree/master/libraries/CactusMicro/examples/temperatureLogger

Step 4: SparkFun Setup

We create a data stream at SparkFun, follow this link to do this. https://data.sparkfun.com/streams/make

Once you've created your stream, keep the window open so you have easy access to your public and private keys handy - you'll need those to replace the KEY in the Arduino sketch.

Now you are ready to start sending data.

Share

Recommendations

  • Epilog Challenge 9

    Epilog Challenge 9
  • Sew Warm Contest 2018

    Sew Warm Contest 2018
  • Gluten Free Challenge

    Gluten Free Challenge
user

We have a be nice policy.
Please be positive and constructive.

Tips

Questions

49 Comments

hi,

could you update the code for cactus micro rev2 please?

trying, but i can not.

question: how long data keeps on sparkfun? (the free one)

user

Hi, We've updated the sketch for Cactus Micro Rev2 today. It should work with default esp8266 espduino firmware.

https://github.com/AprilBrother/cactus-micro-r2/tree/master/libraries/CactusMicro/examples/temperatureLogger

Can you make it reading temperature from several sensors? Should it be like example below or there is better way? Thanks.

tempSenNum++;

if (tempSenNum > 3){

tempSenNum = 1;

}

switch (tempSenNum) {

case 1:

DeviceAddress thermometer = { xxxxxxxxxxxxxxxxxxxxx }; //sensor #1

break;

case 2:

DeviceAddress thermometer = { xxxxxxxxxxxxxxxxxxxxx }; //sensor #2

break;

case 3:

DeviceAddress thermometer = { xxxxxxxxxxxxxxxxxxxxx }; //sensor #3

break;

}

My order from Tindie arrived... ready to build... but link for code not there...

https://github.com/AprilBrother/cactus-micro/blob/master/examples/arduino/temperatureLogger/temperatureLogger.ino

user

Hi,

I have just updated the link for the sketch.

Please note: the code is only work on rev1. You must change the code to hardware serial port Serial1.

Hi there,

I'm interested in using this Cactus micro in my project for sending data to a website.

Do the flash memory,ram and ROM stack when I use it with Arduino Uno? Or any different in term of speed?

Thank you

user

You should compare it with Arduino Leonardo or Arduino Micro. The micro controller is ATMega32U4.

user

It looks great! I

user

I made some change with your code. Not tested. I replace some "Serial" with the SoftwareSerial port "debug". Please diff the code.

https://gist.github.com/volca/da178cd000abb91d649f