Skip to content
Additional Module for MagicMirror² https://github.com/MichMich/MagicMirrorShows the temperature and humidity from the sensor HDC1080 on the MagicMirror²
JavaScript C
Branch: master
Clone or download
MichaelF1 Update README.md
corrected filename of c program
Latest commit e136c2a May 19, 2018
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
MMM-HDC1080.js Add files via upload Aug 28, 2017
README.md Update README.md May 19, 2018
ReadHDC1080 Add files via upload Aug 28, 2017
ReadHDC1080_Pi.c Add files via upload Aug 28, 2017
node_helper.js Add files via upload Aug 29, 2017
npm-debug.log Add files via upload Aug 28, 2017

README.md

MMM-HDC1080

This module shows the temperature and humidity of a HDC1080 Sensor by using the I2C of the RaspberryPi and displays it at your MagicMirror² https://github.com/MichMich/MagicMirror. The Pins 2 and 3 are used for I2C and can not be changed. The main function and code is from @Bangee44 (https://github.com/Bangee44/MMM-DHT22) where he used it for a DHT22-Sensor.

Dependencies

Installation

Navigate into your MagicMirror's modules folder:

cd ~/MagicMirror/modules

Clone this repository:

git clone https://github.com/MichaelF1/MMM-HDC1080

Setup the address (default is 0x40) of your used I2C - HDC1080 Sensor in the ReadHDC1080.c-file at ~/MagicMirror/modules/MMM-HDC1080/:

int iI2cAddress = 0x40; //put in your I2C-Address here

If you do not need to change the file you are fine now, but if you have to you have to compile it with:

cc -Wall ReadHDC1080_Pi.c -o ReadHDC1080 -lwiringPi

Navigate to the new MMM-HDC1080 folder and make ReadHDC1080 executable.

cd MMM-HDC1080
chmod 755 ReadHDC1080

You can change the ReadHDC1080.c file for your own needs if you like to. You'll have to recompile it using wirinpi lib.

cc -Wall ReadHDC1080.c -o ReadHDC1080 -lwiringPi

Configure the module in your config.js file.

Using the module

To use this module, add it to the modules array in the config/config.js file:

modules: [
  {
    module: 'MMM-HDC1080',
    position: 'top_right',
    config: {
            updateInterval: 0.5, // Minutes    
    },
  },
]

Configuration options

The configuration options are still the same of https://github.com/Bangee44/MMM-DHT22

The following properties can be configured:

Option Description
updateInterval Updateinterval for HDC1080 sensor in minutes
Possible values: int
Default value: 0.5

You can’t perform that action at this time.