Software

Downloading the Firmware

DataGoo’s firmware is open-source and can be downloaded from GitHub: https://github.com/yesimon/datagoo. Feel free to send a pull request if you want to contribute changes either to the source code or the documentation.

For write access to the repository, please contact Simon at sye737+github@gmail.com.

Building with Arduino IDE

Download the required external libraries (see Software Libraries) and place them in the Arduino libraries/ directory. Open datagoo.ino, compile and upload using the GUI.

Software Libraries

External Libraries

EmonLib

A significant portion of our code is based on the OpenEnergyMonitor project, which is building an open source energy monitoring solution targeted at homes in the UK/Europe (and to a lesser extent the US). Their library does much of the heavy lifting for us in converting the raw voltage and current inputs coming into the DataGoo device into power measurements.

We forked their code base primarily because we needed to output our readings over GSM and to an SD logger, rather than over a custom (low-power) RF system which OpenEMon uses to transmit their data.

Cell Phone Communication

There isn’t exactly a library for communicating with the GSM module; instead, it presents itself as a Serial device which can read and write messages.

In particular, see the AT command set.

Also, see this tutorial for some example code using the GSM module.

Standard Arduino Libraries

SD Library

The library to write text to SD cards is part of the Arduino standard library. It lets us write to the SD card just by creating a file and then calling file.print().

SD Library

SoftwareSerial Library

This library is also part of the Arduino standard library and emulates a Serial port over software, which is especially critical for interfacing with the GSM module (which takes input and provides output over Serial).

SoftwareSerial Library

Project Versions

Previous topic

Mechanical

Next topic

Team

Table Of Contents

This Page