FIRMWARE UPLOAD: Difference between revisions

From lechacal
Jump to navigation Jump to search
No edit summary
 
(3 intermediate revisions by the same user not shown)
Line 30: Line 30:
Set the variable =0 or =1 depending on which sensor you wish to enable/disable. Note that for RP1 RP2 RP3 associated CT1 ct2 ct3 must also be enabled.
Set the variable =0 or =1 depending on which sensor you wish to enable/disable. Note that for RP1 RP2 RP3 associated CT1 ct2 ct3 must also be enabled.


5/ Install all required libraries:
Emonlib Library:
https://github.com/openenergymonitor/EmonLib
JeeLib:
http://github.com/jcw/jeelib
Timer:
http://playground.arduino.cc/Code/SimpleTimer
One Wire
http://www.pjrc.com/teensy/td_libs_OneWire.html
Dallas Temparature:
http://milesburton.com/Main_Page?title=Dallas_Temperature_Control_Library


5/ Connect the FTDI adaptor to the emontx board on the FTDI port. Make sure grounds are connected together. Connect the other end of the FTDI adaptor to the USB port of the computer.
6/ Connect the FTDI adaptor to the emontx board on the FTDI port. Make sure grounds are connected together. Connect the other end of the FTDI adaptor to the USB port of the computer.


6/ Upload the sketch with the IDE.
7/ Upload the sketch with the IDE.


[[File:IMG_0606_small.jpg | right]]
[[File:IMG_0606_small.jpg]]

Latest revision as of 12:39, 17 July 2016

Upload emontx Arduino sketch to the EmonWRT

Required Equipment

  • 1 screw driver
  • 1 FTDI/USB adaptor
  • A computer running the Arduino IDE

Steps

1/ Open the EMonWRT enclosure removing the two screws.

2/ Download and install the Arduino IDE. https://www.arduino.cc/en/Main/Software

3/ Open the sketch template given on the main EmonWRT page.

4/ Modify it to your needs. The main parameters to change are at the top of the sketch.

const boolean CT1  = 1;                                                 // Set to 0 to disable CT channel 1
const boolean CT2  = 1;                                                 // Set to 0 to disable CT channel 2
const boolean CT3  = 1;                                                 // Set to 0 to disable CT channel 3
const boolean TEMP = 1;                                                 // Set to 0 to disable Temperature Channel
const boolean RP1  = 1;                                                 // Set to 0 to disable Real Power on CT1 channel (requires ac/ac adaptor)
const boolean RP2  = 1;                                                 // Set to 0 to disable Real Power on CT1 channel (requires ac/ac adaptor)
const boolean RP3  = 1;                                                 // Set to 0 to disable Real Power on CT1 channel (requires ac/ac adaptor) 
const boolean VRMS = 1;                                                 // Set to 0 to disable VRMS channel (requires ac/ac adaptor)
const boolean PULS = 0;                                                 // Set to 0 to disable PULSE channel (requires TSL257 sensor)
const boolean RF   = 0;                                                 // Set to 0 to disable RFM12B forwarding.

Set the variable =0 or =1 depending on which sensor you wish to enable/disable. Note that for RP1 RP2 RP3 associated CT1 ct2 ct3 must also be enabled.

5/ Install all required libraries:

Emonlib Library:
https://github.com/openenergymonitor/EmonLib
JeeLib:
http://github.com/jcw/jeelib
Timer:
http://playground.arduino.cc/Code/SimpleTimer
One Wire
http://www.pjrc.com/teensy/td_libs_OneWire.html
Dallas Temparature:
http://milesburton.com/Main_Page?title=Dallas_Temperature_Control_Library

6/ Connect the FTDI adaptor to the emontx board on the FTDI port. Make sure grounds are connected together. Connect the other end of the FTDI adaptor to the USB port of the computer.

7/ Upload the sketch with the IDE.