[SOLVED] Average room temperature - indoor and outdoor separation

Hi,
Under group overview I have Average room temperature which is collecting all temperature readings and dividing by total qty. I believe this aver room temp was copied from demo house.

Capture1

Now because I have one sensor which is located outside and also using weather binding my room temperature is naturally lowered. Currently I only have one sensor at home.

Capture2

Questions is , how to separate indoor and outdoor reading to avoid this situation ? And also where is this average temperature calculated ?

Pasted copies of my current items and sitemap.

/* active groups */
Group:Switch:OR(ON, OFF) 		Lights 		"All Lights [(%d)]" 								(All)
Group:Switch:OR(ON, OFF) 		Heating 	"No. of Active Heatings [(%d)]" 	<heating> 		(All)
Group:Number:AVG 				Temperature	"Avg. Room Temp. [%.1f °C]" 	<temperature>	(Status)
Group:Contact:OR(OPEN, CLOSED) 	Windows 	"Open windows [(%d)]"				<contact>		(All)
Group:Contact:OR(OPEN, CLOSED) 	Doors 	    "Open doors [(%d)]"			    	<door>		(All)
* Indoor Temperatures */
Number Temperature_GF_Hallway 
Number Temperature_GF_Living "Temperature [%.1f °C]"   <temperature>   (Temperature, GF_Living) [ "CurrentTemperature" ] { mqtt="<[broker:/sonoff/switch5/temperature:state:default]"}

/* Outdoor Temperatures */
Number Temperature_Outdoor 	"Temperature [%.1f °C]"   <temperature>   (Temperature, Outdoor) [ "CurrentTemperature" ] { mqtt="<[broker:/sonoff/switch1/temperature:state:default]"}
/* Weather binding item */
Group Weather_Chart													(Weather)
Number Weather_Temperature 		"Outside Temperature [%.1f °C]"	<temperature> (Weather_Chart, Temperature) { http="<[http://weather.yahooapis.com/forecastrss?w=10559
&u=c:60000:XSLT(yahoo_weather_temperature.xsl)]" }
Frame label="Overview" {
		Text label="Group Overview" icon="group" {
			Switch item=Lights mappings=[OFF="All Off"]
			Group item=Heating
            Group item=Windows
			Group item=Doors
			Group item=Temperature

Group:Number:AVG Temperature " …

So to leave outside temperature out, don’t include that Item in that Group

Thanks that worked.

Just one more thing if I can add to this subject.
I have divided my house into separate rooms. So for example when I look into Living room tab I will see various items , switches, temperature , humidity etc.

Capture3

Problem I have , when go to Group tab and look inside Avr room temperature or other like (door for example) I will see multiple items with the same name - Temperature or Door unless I add Living room name to this item. Is there any work around and will I need to name every item starting with location "Living room Door"and so on.

Capture4

Remove the outsite temperature from the Temperature group:

/* Outdoor Temperatures */
Number Temperature_Outdoor 	"Temperature [%.1f °C]"   <temperature>   (Outdoor) [ "CurrentTemperature" ] { mqtt="<[broker:/sonoff/switch1/temperature:state:default]"}

Write the labels one by one in the sitemap… I am afraid but that’s the only way
Well… Almost… You could also change the labels for each items in the item definition but then when you go into the group ‘Living room’ you will see ‘LivingRoom Temp’…
Also listing the sitemaps items one by one may seem a big job instead of using group tags but in the end you have control of the display order and much more flexibility

Thanks Vincent, could you give me example how to write labels one by one , sorry little confused with that.

gPiHole is a group but I display it as a text item with a sub frame {…} in which you put the items of the group
You need to populate the items by hand not like the group item in the sitemap but you have control over the order of the items and the m=way they are displayed individually.

    Frame {
        Text item=gPiHole label="Pi-Hole" icon=pihole {
            Text item=PiHole_DomainsBeingBlocked label="label1 [%s]"
            Text item=PiHole_DnsQueriesToday label="label2 [%d]"
            ....
        }
    }

Thanks this will work.

Looking at my layout there are two things which still causing me problem.

  1. How to display items under Server ? Tried changing to Text items but goes in error.

Capture1

Frame label="System"	{
	    Text label="Server" icon="settings" 
/* System Info binding item */
String Network_IP               "IP address"   (Server) { channel="systeminfo:computer:work:network#ip" } 

Number Sysinfo_Pi_Memory_Total (Server) { channel="systeminfo:computer:openHABianPi:memory#total" } 
  1. How to list all lights here but to keep “All Off” button.

Capture2

Frame label="Overview" {
		Text label="Group Overview" icon="group" {
			Switch item=Lights mappings=[OFF="All Off"]
/* Lights */
Switch Light_GF_Living_Ceiling 		"Living Room Ceiling" 		(GF_Living, Lights) [ "Lighting" ] {mqtt=">[broker:/sonoff/switch5/switch5/cmd:command:ON:on],>[broker:/sonoff/switch5/switch5/cmd:command:OFF:off],<[broker:/sonoff/switch5/switch5/state:state:ON:on],<[broker:/sonoff/switch5/switch5/state:state:OFF:off]"}

Thanks in advance

Slow down, use the documentation

If you want to display an Item, the item= parameter is of interest

No worries got it now. Thanks for link.

Please mark the thread as solved, thanks

Hi,

I’m trying to achieve the same (avg room temp - indoor), but it seems I cannot get my head around the Group setup and I seem to miss some basic understanding of it. Therefore, some help and guidance on this topic would be highly appreciated.

I have the below setup:

ITEMS:

    Group Tempus "Temperatur" <temp> (Home) // This Group collects all Temperature-related items, Indoor and Outdoor
    Group TempIndoor "Haustemperatur" <temperature> (Home) //This Group just groups all indoor temperature sensors. 

Group:Number:AVG TempIndoor "Durchschnittstemp Haus" <temperature> (Tempus)   //I'd like to get an average of all indoor temperature items 

In my SITEMAP, I have the below:

	Group item=TempIndoor
	Group item=Tempus

When I do that, it seems like openhab starts to hang.
See my LOGFILES:

[WARN ] [me.core.internal.events.EventHandler] - Dispatching event to subscriber 'org.eclipse.smarthome.core.internal.items.ItemUpdater@24fc5e' takes more than 5000ms.

2018-11-04 09:54:56.397 [WARN ] [me.core.internal.events.EventHandler] - Dispatching event to subscriber 'org.eclipse.smarthome.io.monitor.internal.EventLogger@3ea8f5' takes more than 5000ms.

2018-11-04 10:02:20.850 [WARN ] [me.core.internal.events.EventHandler] - Dispatching event to subscriber 'org.eclipse.smarthome.core.thing.internal.CommunicationManager@faf4fe' takes more than 5000ms.

2018-11-04 10:02:24.596 [WARN ] [me.core.internal.events.EventHandler] - Dispatching event to subscriber 'org.eclipse.smarthome.core.internal.items.ItemUpdater@24fc5e' takes more than 5000ms.


Changing it back won’t help and I need to restart openhab.service.

what am I doing wrong and why is openhab freezing?
I am on openHAB 2.3.0-1 (Release Build)

thanks upfront for your guidance,
Kurt

You have 2 items with the same name:

Group Tempus "Temperatur" <temp> (Home) // This Group collects all Temperature-related items, Indoor and Outdoor
Group TempIndoor "Haustemperatur" <temperature> (Home) //This Group just groups all indoor temperature sensors. 
Group:Number:AVG TempIndoorAVG "Durchschnittstemp Haus" <temperature> //I'd like to get an average of all indoor temperature items 

Make the indoor temperature items member of the group TempIndoorAVG
OR
Remove the AVG group and make the TempIndoor group an AVG group:

    Group Tempus "Temperatur" <temp> (Home) // This Group collects all Temperature-related items, Indoor and Outdoor
    Group:Number:AVG TempIndoor "Haustemperatur" <temperature> (Home) //This Group just groups all indoor temperature sensors. 

Ah - thanks a lot.
I can see the group updating in my logfiles:

TempIndoor changed from NULL to 20.48 through GF_Kitchen_Heating_Tado_temp

However -and here comes the next noob question for you- this value is not displayed in my Sitemap.

Text item=TempIndoor label="Innentemperatur:" valuecolor=[>=25="orange", >=15="green", 0="white", <15="blue"]

why is that?

Kurt

label="Innentemperatur: [%. 1f °C]"

thanks a million!