User Tools

Site Tools


projects:open_energy_monitor_unmonastery:2_installation

This is an old revision of the document!


Basic installation

1 Equipment

1.1 emonTx

1.1.1 Wiring

  • Plug in the SMA antenna to the emonTx board.
  • Plug in the USB to serial uart module to the emonTx board and connect it to the USB port of your computer.
  • Connect the CT clips from the electrical panel to the emonTx board :

1.1.2 Install the firmware for a three-phases power installation

The full-assembled emonTx v3 is shipped with the emonTxV3_RFM12B_Discrete Sampling firmware as pre-loaded which is suited for a one-phase power installation. As we have a three-phases power installation we can't use it. The solution is to upload a new firmware, using the Arduino environment as the RFM12B module is Arduino compatible. Here is what we did (Linux) :

  • Install the Arduino environment.
  • Install the git software.
  • Install the required Arduino libraries for emonTx v3 :
    cd ~/.arduino/libraries
    git clone https://github.com/openenergymonitor/EmonLib
    git clone https://github.com/jcw/jeelib
    git clone https://github.com/openenergymonitor/RFu_jeelib
  • Get emonTx v3 latest sources :
    cd ~/.arduino
    git clone https://github.com/openenergymonitor/emonTxFirmware.git
  • Connect the the USB to serial uart module to the emonTx v3 and to your computer.
  • Launch the Arduino IDE.
  • In the menu “Tools / Boards” select “Arduino Uno”.
  • In the menu “Tools / Port” select the port (for example /dev/ttyUSB0).
  • In the menu “File / Sketches” open the “emonTxFirmware / emonTxV3 / RFM12B / Examples / emonTxV3_3Phase_Voltage.ino” file.
  • Eventually uncomment the #define DEBUGGING if you want to have detailed output over the serial port.
  • [TODO : set up Vcal, Ical values]
  • Compile and upload the sketch to the board.

1.1.3 Test it

  • Connect the emonTx power adaptor. A red led should be on and then flash regularly.
  • Test it is working (on Linux) :
    • Install the python-serial package
    • On your computer run this python test script (name it serialtest.py), which reads the values emitted from the emonTx over the serial port (make sure the serial port is correct, you can see it executing the dmesg command) :
      import serial, sys
      ser = serial.Serial('/dev/ttyUSB0', 9600)
      while 1:
          sys.stdout.write(ser.readline())
    • You should have an output like this (after about 10s)
    • The first three columns correspond to the power consumption of each phase (in W).
    • The fourth column is the operating voltage (multiplied by 100) of the electrical installation.
    • If you have negative values for the power consumption, turn up side down the CT clip on the electrical panel.

1.2 emonTh

1.3 Raspberry Pi and emonCms

To collect and display the data from emonTx (power consumption) and emonTh (temperature and humidity) we will use the Raspberry Pi.

All the data received will be published to a emonCms server. This one can be either :

/var/www/tech_mirelsol/data/attic/projects/open_energy_monitor_unmonastery/2_installation.1403076019.txt.gz · Last modified: 18/06/2014 09:20 by Mirelsol