Displaying EmonTH data on emonLCD for outdoor temp monitoring.

Hi. Have any of you tried to display emonTH data on EmonLCD display for outdoor min/max temperature display.

I am trying to use the "if (node_id == 19)" '19 being the Emonth.

Will I need to create a typedef struct for the emonTH?

for the emontx there is a

"typedef struct { int power1, power2, power3, Vrms; } PayloadTX;         // neat way of packaging data for RF comms
PayloadTX emontx";"

when looking at the next part of the loop, it seems that i can get the data directly as

"rf12_data[1], rf12_data[2], rf12_data[3]" is used to set the RTC.

I get a bit lost here, as i cant find any examples that is doing this, and is too unexperienced in how to send, format and receive data via the RFM12b.

Any suggestions on how to get this done ?

Future development of the system is to add another emonth to show if the garage door is open or closed, also on the EmonLCD.

My plan is to display the outdoor temperature, as well as water temperature in a outdoor spa on the EmonLCD, plus modifying the Solar PV sketch to display power usage for my heatpump, outdoor spa, and waterheater.

Robert Wall's picture

Re: Displaying EmonTH data on emonLCD for outdoor temp monitoring.

You're on the right lines. You need to create a struct - identical to the one inside the emonTH code - to receive the transmitted data in the GLCD sketch.

Then lower down in the GLCD sketch, you'll need to copy the section of code for the emonTx and change it to suit the TH node number and data structure. Give it a different name to the emonTx one, of course.

Inside loop( ), you'll access the data as emonth.temp, emonth.humidity, etc.

If you are confused by the way the received data is mapped onto the structure, see here: RFM12B - Part 2 - Sending Data Between Modules. You'll need to scale the values to display correctly.

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.