Weather binding help

Hey everybody.

I have a question about the weather binding ( i think i could be for every binding)

First of all, this is my sitemap:

Frame item=Vejret Text item=Viborg_Temperatur valuecolor=[>30=“red”,>25=“orange”,>15=“green”,>5=“orange”,<=5=“blue”]

{

				Text item=Viborg_Temperatur			valuecolor=[>30="red",>25="orange",>15="green",>5="orange",<=5="blue"]
				Text item=Viborg_Feel 				valuecolor=[>30="red",>25="orange",>15="green",>5="orange",<=5="blue"]				
				Text item=Viborg_idag_Min 			valuecolor=[>30="red",>25="orange",>15="green",>5="orange",<=5="blue"]
				Text item=Viborg_idag_Max 			valuecolor=[>30="red",>25="orange",>15="green",>5="orange",<=5="blue"]
				Text item=Viborg_chance_regn		valuecolor=[>5="blue",>15="green",>40="orange",<=100="red"]

				Text item=Viborg_imorgen_Min			valuecolor=[>30="red",>25="orange",>15="green",>5="orange",<=5="blue"]
				Text item=Viborg_imorgen_Max 			valuecolor=[>30="red",>25="orange",>15="green",>5="orange",<=5="blue"]
				Text item=Viborg_imorgen_chance_regn
}

My question is, and if its possible:

Weather ->

The weather today:
Text item=Viborg_Temperatur (current temp)
Text item=Viborg_Feel (temp feeling)
Text item=Viborg_idag_Min (day min temp)
Text item=Viborg_idag_Max (day max temp)
Text item=Viborg_chance_regn (chance of rain)

The weather (the next days name (mon, tue…))
Text item=Viborg_idag_Min
Text item=Viborg_idag_Max
Text item=Viborg_chance_regn

The weather (the next days name (mon, tue…))
Text item=Viborg_idag_Min
Text item=Viborg_idag_Max
Text item=Viborg_chance_regn

( text marked as bold, shall be “frame” text)

and so on

Can i do this? and if it can, can anyone help me with this issue?

Thanks,
Peter

The Frame element will take a label.

Frame label="The weather today: " {
    Text item=Viborg_Temperature (current temp)
    ...
}

Hey

Here is some pictures of my problem / question:

Can i instead of “TOMORROW” have a automatic day name (if tomorrow is Friday, then its written FRIDAY) (the same with " THE DAY AFTER TOMORROW"

In the top its written “Temperatur” but why have the C (degrees) disappeared?

Why and what is the error in the code? The error is: Link able widget should contain either only frames or non at all. what does that mean?

Here is my sitemap:

sitemap demo label="Det smarte hus" 

{

						/*Grupper i mappen Lokation*/
			Frame label="Lokation"	
				{
					Group item=Indenfor 				label="Indenfor" 											icon="inde"
					Group item=Udenfor 					label="Udenfor" 											icon="tree"
				}
	
	
						/*Hurtigfunktioner*/
			Frame label="Hurtig Funktioner" 
				{
				Switch item=sluklys						label="Sluk alt lys"	mappings=[OFF="Sluk"]				icon="lightoff"
				Switch item=slukmusik					label="Sluk alt musik"	mappings=[OFF="Sluk"] 				icon="voloff"
				Switch item=sluktv						label="Sluk TV"			mappings=[OFF="Sluk"] 				icon="computer"
				}
		
						/*Vejr Start*/
			Frame label=Vejret							Text item=Viborg_Temperatur 	valuecolor=[>30="red",>25="orange",>15="green",>5="orange",<=5="blue"]
		{				
			Frame label="Today"
				Text item=Viborg_Temperatur				valuecolor=[>30="red",>25="orange",>15="green",>5="orange",<=5="blue"]
				Text item=Viborg_Feel 					valuecolor=[>30="red",>25="orange",>15="green",>5="orange",<=5="blue"]				
				Text item=Viborg_idag_Min 				valuecolor=[>30="red",>25="orange",>15="green",>5="orange",<=5="blue"]
				Text item=Viborg_idag_Max 				valuecolor=[>30="red",>25="orange",>15="green",>5="orange",<=5="blue"]
				Text item=Viborg_chance_regn			
		
					Frame label="Tomorrow"
		 
				Text item=Viborg_imorgen_Min			valuecolor=[>30="red",>25="orange",>15="green",>5="orange",<=5="blue"]
				Text item=Viborg_imorgen_Max 			valuecolor=[>30="red",>25="orange",>15="green",>5="orange",<=5="blue"]
				Text item=Viborg_imorgen_chance_regn
				
					Frame label="The day after tomorrow"
		 
				Text item=Viborg_iovermorgen_Min			valuecolor=[>30="red",>25="orange",>15="green",>5="orange",<=5="blue"]
				Text item=Viborg_iovermorgen_Max 			valuecolor=[>30="red",>25="orange",>15="green",>5="orange",<=5="blue"]
				Text item=Viborg_iovermorgen_chance_regn
				
				}
				
				}

Item:

/Overgrupper/
Group All
Group Indenfor (All)
Group Udenfor (All)
Group Hurtigfunktioner (All)

/---------------------------------------------------------------------------------------------------------/

/Undergrupper/
Group IN_Stue “Stue” (Indenfor)
Group IN_kitchen “Køkken” (Indenfor)
Group IN_Bathroom “Badeværelse” (Indenfor)
Group IN_Toilet “Toilet” (Indenfor)
Group IN_Vicktoria “Vicktoria” (Indenfor)
Group IN_Bedroom “Soveværelse” (Indenfor)
Group IN_Guestroom “Gæsteværelse” (Indenfor)
Group IN_Office “Kontor” (Indenfor)
Group IN_Hall “Gang” (Indenfor)
Group IN_Entre “Forgang” (Indenfor)

Group OU_outlight “Udelys” (Udenfor)
Group OU_Garage “Garage” (Udenfor)
Group OU_Jazucci “Jazucci” (Udenfor)
Group OU_Garden “Haven” (Udenfor)

/---------------------------------------------------------------------------------------------------------/

/Lys kontakter/
Switch lyskontor “Lys over bord” (IN_Office) {ihc=">[OFF:1113873:100]"}
Switch lyskontoron “Lys over bord” (IN_Office) {ihc=">[ON:1111644:100]"}
Switch lyskontoronoff “Lys over bord” (IN_Office) {ihc=">[ON:1111644:100, OFF:1113873:100]"}
Dimmer Sovevaerlse_spot_dimmer “Spots soveværelse” (IN_Bedroom) {ihc=">[ON:1003794:100]"}

/Hurtigfunktioner/
Switch sluklys “Sluk alt lys” (Hurtigfunktioner) {ihc=">[OFF:432988:100]"}

Switch slukmusik
Switch slukmusik1 “Sluk alt musik” {sonos="[OFF:RINCON_000E58D71BD201400:stop]"}
Switch slukmusik2 “Sluk alt musik” {sonos="[OFF:RINCON_000E58DA528001400:stop]"}
Switch slukmusik3 “Sluk alt musik” {sonos="[OFF:RINCON_000E58D7F10E01400:stop]"}
Switch slukmusik4 “Sluk alt musik” {sonos="[OFF:RINCON_5CAAFD13A20601400:stop]"}
Switch slukmusik5 “Sluk alt musik” {sonos="[OFF:RINCON_000E58D84C7C01400:stop]"}
Switch slukmusik6 “Sluk alt musik” {sonos="[OFF:RINCON_000E5838ED5A01400:stop]"}
Switch slukmusik7 “Sluk alt musik” {sonos="[OFF:RINCON_000E58DAD00C01400:stop]"}
Switch slukmusik8 “Sluk alt musik” {sonos="[OFF:RINCON_000E5866454A01400:stop]"}
/**skukmusik1: Soveværelse */
/**skukmusik2: Badeværelse */
/**skukmusik3: Vicktoria */
/**skukmusik4: Stue */
/**skukmusik5: Gæsteværelse */
/**skukmusik6: Kontor */
/**skukmusik7: Køkken */
/**skukmusik7: Bridge */

Switch sluktv
Switch sluktv1 “Sluk” {samsungtv=“OFF:Stue:KEY_POWEROFF”}
Switch sluktv2 “Sluk” {samsungtv=“OFF:Bedroom:KEY_POWEROFF”}
/**stuktv1: stue */
/**sluktv2: soveværelse */

/---------------------------------------------------------------------------------------------------------/

/* Vejr */
Number Viborg_Temperatur “Temperatur [%.1f °C]” (Vejret) {weather=“locationId=home, type=temperature, property=current”}
Number Viborg_Feel “Føles som [%.2f °C]” (Vejret) {weather=“locationId=home, type=temperature, property=feel”}
Number Viborg_idag_Min “Dagens min. temp.:[%.2f °C]” (Vejret) {weather=“locationId=home, forecast=0, type=temperature, property=min”}
Number Viborg_idag_Max “Dagens max. temp.: [%.2f °C]” (Vejret) {weather=“locationId=home, forecast=0, type=temperature, property=max”}
Number Viborg_chance_regn “Chance for regn idag: [%d %%]” (Vejret) {weather=“locationId=home, forecast=0, type=precipitation, property=probability”}

Number Viborg_imorgen_Min “Min. temp.:[%.2f °C]” (Vejret) {weather=“locationId=home, forecast=1, type=temperature, property=min”}
Number Viborg_imorgen_Max “Max. temp.: [%.2f °C]” (Vejret) {weather=“locationId=home, forecast=1, type=temperature, property=max”}
Number Viborg_imorgen_chance_regn “Chance for regn: [%d %%]” (Vejret) {weather=“locationId=home, forecast=1, type=precipitation, property=probability”}

Number Viborg_iovermorgen_Min “Min. temp.:[%.2f °C]” (Vejret) {weather=“locationId=home, forecast=2, type=temperature, property=min”}
Number Viborg_iovermorgen_Max “Max. temp.: [%.2f °C]” (Vejret) {weather=“locationId=home, forecast=2, type=temperature, property=max”}
Number Viborg_iovermorgen_chance_regn “Chance for regn: [%d %%]” (Vejret) {weather=“locationId=home, forecast=2, type=precipitation, property=probability”}

/---------------------------------------------------------------------------------------------------------/

/*Lys IHC oversigt
*Sovevaerlse_spot_on DIMMER on: 1002257
*Sovevaerlse_spot_off DIMMER off: 1002513
*Sovevaerlse_natlampe_matina_kip KIP on/off: 1516049
*Sovevaerlse_natlampe_matina_off KIP off: 1516561
*Sovevaerlse_natlampe_peter_kip KIP on/off: 1524241
*Sovevaerlse_natlampe_peter_off KIP off: 1524753
*Vicktoria_lys_on on: 1083921
*Vicktoria_lys_off off: 1084177
*Gaestetoilet_spot_on DIMMER on: 1448977
*Gaestetoilet_spot_off DIMMER off: 1449233
*Gaestevaerlse_lys_on on: 1103377
*Gaestevaerlse_lys_off off: 1103633
*Kontor_lys_on on: 1113617
*Kontor_lys_off off: 1113873
*
*

  • */

Hope i can get some help :slight_smile:

Peter

To get it to say the actual day of the week rather than Tomorrow, you need to create a new Item for Tomorrow and The Day After Tomorrow and a rule to populate that Item with the proper day of the week.

String Tomorrow "[%s]"
String DayAfterTomorrow "[%s]"
rule "Update days of the week"
when
    Time midnight
then
    Tomorrow.postUpdate(now.plusDays(1).dayOfWeek.getAsText
    DayAfterTomorrow.postUpdate(now.plusDays(1).dayOfWeek.getAsText
end

The Frames for your Sitemap then becomes:

Frame item=Tomorrow {

Frame item=DayAfterTomorrow {

I don’t know

The missing degrees C probably has to do with this error. The error is caused by your attempt to use valuecolor with a Fame element. Frames neight support visibility nor valuecolor.

im getting an error in the designer regarding “getAsText” ?

I don’t have access to a computer right now. Search the forum for getAsText and I’m sure you will find examples.

hey

I cant find any solution for this in this forum, could you please help me :slight_smile:

Peter

You should try “toString” instead of “getAsText”. And do not Forget the the parenthesis at the end of each line…

Tomorrow.postUpdate(now.plusDays(1).dayOfWeek.toString)
DayAfterTomorrow.postUpdate(now.plusDays(1).dayOfWeek.toString)

(not tested, because I have no access to my openhab right now)

Hey alle…

now i try again… and now im maybe a bit more confused :slight_smile:

This is what i have now, and its still dosnt work :frowning:

rule "Update days of the week"
when
Time is midnight
then
var culture = new System.Globalization.CultureInfo(“da-DK”)
var day = culture.DateTimeFormat.GetDayName(DateTime.Today.DayOfWeek)

Imorgen.postUpdate(now.plusDays(1).dayOfWeek.ToString
Iovermorgen.postUpdate(Now.plusDays(1).dayOfWeek.toString)

end

please help me

Case matters. “ToString” should be “toString” and “Now” should be “now”.

Hey

This is strange, so i try something new, the idea is the same, but now the frame title should be the day name. But its still dosnt work ??

here is my sitemap:

Frame label="weather comming days"	
					{
						Group item=daynameplus1 						label="daynameplus1  [%s]"														icon="inde"
						Group item=daynameplus2 	 					label="daynameplus2  [%s]"										icon="tree"
						Group item=daynameplus3 	 					label="daynameplus3  [%s]"										icon="tree"
						Group item=daynameplus4 						label="daynameplus4  [%s]"										icon="tree"
						Group item=daynameplus5 	 					label="daynameplus5  [%s]"										icon="tree"
					
					}

Here is the rule:

rule "Update days of the week"
when
    Time is midnight 
then

    daynameplus1.postUpdate(now.plusDays(1).dayOfWeek.toString)
    daynameplus2.postUpdate(now.plusDays(2).dayOfWeek.toString)
    daynameplus3.postUpdate(now.plusDays(3).dayOfWeek.toString)
    daynameplus4.postUpdate(now.plusDays(4).dayOfWeek.toString)
    daynameplus5.postUpdate(now.plusDays(5).dayOfWeek.toString)
    
    
end

Item

String 		daynameplus1 					"[%s]"														(commingdays)
String 		daynameplus2  					"[%s]"														(commingdays)
String 		daynameplus3  					"[%s]"														(commingdays)
String 		daynameplus4  					"[%s]"														(commingdays)
String 		daynameplus5  					"[%s]"														(commingdays)```


What is wrong :unamused:

Do you actually have Group items called daynameplus1 etc?

I’m going to guess @pahansen is right. You can only use Group Items with the Group tag on your sitemap.

To get the behavior you want you need to do something like the following:

Text item=daynameplus1 {
    Frame{
        Text item=forecastItem1 
        Text item=forecastItem2
        ...
    }
}

Hey…

I dont know what im doing wrong!!! its a bit frustrated…

here is my rule, who i imagen is wrong?

rule "Update days of the week"
when
    Time is midnight 
then

    daynameplus1.postUpdate(now.plusDays(1).dayOfWeek.toString)
    daynameplus2.postUpdate(now.plusDays(2).dayOfWeek.toString)
    daynameplus3.postUpdate(now.plusDays(3).dayOfWeek.toString)
    daynameplus4.postUpdate(now.plusDays(4).dayOfWeek.toString)
    daynameplus5.postUpdate(now.plusDays(5).dayOfWeek.toString)
    
    
end

and the item:

String 		daynameplus1 					"[%s]"														(commingdays)
String 		daynameplus2  					"[%s]"														(commingdays)
String 		daynameplus3  					"[%s]"														(commingdays)
String 		daynameplus4  					"[%s]"														(commingdays)
String 		daynameplus5  					"[%s]"														(commingdays)

Peter

The screenshot indicates the Items are undefined.

Add some logging to the rule to verify that it is running. You might set the trigger so it runs more frequently during testing.

Look for errors in the log around the last time it ran.

This is the error?

00:38:00.001 [DEBUG] [.o.m.r.i.engine.ExecuteRuleJob:53 ] - Executing scheduled rule 'Update days of the week’
00:38:00.021 [ERROR] [.o.m.r.i.engine.ExecuteRuleJob:57 ] - Error during the execution of rule Update days of the week
java.lang.RuntimeException: The name ‘.toString’ cannot be resolved to an item or type.
at org.openhab.model.script.interpreter.ScriptInterpreter.internalFeatureCallDispatch(ScriptInterpreter.java:67) ~[na:na]
at org.eclipse.xtext.xbase.interpreter.impl.XbaseInterpreter._evaluateMemberFeatureCall(XbaseInterpreter.java:549) ~[na:na]
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.8.0_111]
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) ~[na:1.8.0_111]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) ~[na:1.8.0_111]
at java.lang.reflect.Method.invoke(Unknown Source) ~[na:1.8.0_111]
at org.eclipse.xtext.util.PolymorphicDispatcher.invoke(PolymorphicDispatcher.java:291) ~[na:na]
at org.eclipse.xtext.xbase.interpreter.impl.XbaseInterpreter.internalEvaluate(XbaseInterpreter.java:218) ~[na:na]
at org.eclipse.xtext.xbase.interpreter.impl.XbaseInterpreter.evaluateArgumentExpressions(XbaseInterpreter.java:751) ~[na:na]
at org.eclipse.xtext.xbase.interpreter.impl.XbaseInterpreter._featureCallOperation(XbaseInterpreter.java:712) ~[na:na]
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.8.0_111]
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) ~[na:1.8.0_111]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) ~[na:1.8.0_111]
at java.lang.reflect.Method.invoke(Unknown Source) ~[na:1.8.0_111]
at org.eclipse.xtext.util.PolymorphicDispatcher.invoke(PolymorphicDispatcher.java:291) ~[na:na]
at org.openhab.model.script.interpreter.ScriptInterpreter.internalFeatureCallDispatch(ScriptInterpreter.java:69) ~[na:na]
at org.eclipse.xtext.xbase.interpreter.impl.XbaseInterpreter._evaluateMemberFeatureCall(XbaseInterpreter.java:549) ~[na:na]
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.8.0_111]
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) ~[na:1.8.0_111]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) ~[na:1.8.0_111]
at java.lang.reflect.Method.invoke(Unknown Source) ~[na:1.8.0_111]
at org.eclipse.xtext.util.PolymorphicDispatcher.invoke(PolymorphicDispatcher.java:291) ~[na:na]
at org.eclipse.xtext.xbase.interpreter.impl.XbaseInterpreter.internalEvaluate(XbaseInterpreter.java:218) ~[na:na]
at org.eclipse.xtext.xbase.interpreter.impl.XbaseInterpreter._evaluateBlockExpression(XbaseInterpreter.java:321) ~[na:na]
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.8.0_111]
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) ~[na:1.8.0_111]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) ~[na:1.8.0_111]
at java.lang.reflect.Method.invoke(Unknown Source) ~[na:1.8.0_111]
at org.eclipse.xtext.util.PolymorphicDispatcher.invoke(PolymorphicDispatcher.java:291) ~[na:na]
at org.eclipse.xtext.xbase.interpreter.impl.XbaseInterpreter.internalEvaluate(XbaseInterpreter.java:218) ~[na:na]
at org.eclipse.xtext.xbase.interpreter.impl.XbaseInterpreter.evaluate(XbaseInterpreter.java:204) ~[na:na]
at org.openhab.model.script.internal.engine.ScriptImpl.execute(ScriptImpl.java:59) ~[na:na]
at org.openhab.model.rule.internal.engine.ExecuteRuleJob.execute(ExecuteRuleJob.java:55) ~[na:na]
at org.quartz.core.JobRunShell.run(JobRunShell.java:213) [quartz-all-2.1.7.jar:na]
at org.quartz.simpl.SimpleThreadPool$WorkerThread.run(SimpleThreadPool.java:557) [quartz-all-2.1.7.jar:na]

What do you get when you remove the toStrings?

now its giving this debug:

02:39:03.050 [DEBUG] [.myopenhab.internal.MyOHClient:150 ] - Transport.EVENT_REQUEST_HEADERS

oh, sorry…

here is the newest debug:

02:22:00.001 [DEBUG] [.o.m.r.i.engine.ExecuteRuleJob:53 ] - Executing scheduled rule 'Update days of the week’
02:22:00.009 [ERROR] [.o.m.r.i.engine.ExecuteRuleJob:57 ] - Error during the execution of rule Update days of the week
java.lang.IllegalStateException: Could not invoke method: org.openhab.model.script.actions.BusEvent.postUpdate(org.openhab.core.items.Item,java.lang.Number) on instance: null
at org.eclipse.xtext.xbase.interpreter.impl.XbaseInterpreter.invokeOperation(XbaseInterpreter.java:738) ~[na:na]
at org.eclipse.xtext.xbase.interpreter.impl.XbaseInterpreter._featureCallOperation(XbaseInterpreter.java:713) ~[na:na]
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.8.0_111]
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) ~[na:1.8.0_111]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) ~[na:1.8.0_111]
at java.lang.reflect.Method.invoke(Unknown Source) ~[na:1.8.0_111]
at org.eclipse.xtext.util.PolymorphicDispatcher.invoke(PolymorphicDispatcher.java:291) ~[na:na]
at org.openhab.model.script.interpreter.ScriptInterpreter.internalFeatureCallDispatch(ScriptInterpreter.java:69) ~[na:na]
at org.eclipse.xtext.xbase.interpreter.impl.XbaseInterpreter._evaluateMemberFeatureCall(XbaseInterpreter.java:549) ~[na:na]
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.8.0_111]
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) ~[na:1.8.0_111]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) ~[na:1.8.0_111]
at java.lang.reflect.Method.invoke(Unknown Source) ~[na:1.8.0_111]
at org.eclipse.xtext.util.PolymorphicDispatcher.invoke(PolymorphicDispatcher.java:291) ~[na:na]
at org.eclipse.xtext.xbase.interpreter.impl.XbaseInterpreter.internalEvaluate(XbaseInterpreter.java:218) ~[na:na]
at org.eclipse.xtext.xbase.interpreter.impl.XbaseInterpreter._evaluateBlockExpression(XbaseInterpreter.java:321) ~[na:na]
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.8.0_111]
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) ~[na:1.8.0_111]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) ~[na:1.8.0_111]
at java.lang.reflect.Method.invoke(Unknown Source) ~[na:1.8.0_111]
at org.eclipse.xtext.util.PolymorphicDispatcher.invoke(PolymorphicDispatcher.java:291) ~[na:na]
at org.eclipse.xtext.xbase.interpreter.impl.XbaseInterpreter.internalEvaluate(XbaseInterpreter.java:218) ~[na:na]
at org.eclipse.xtext.xbase.interpreter.impl.XbaseInterpreter.evaluate(XbaseInterpreter.java:204) ~[na:na]
at org.openhab.model.script.internal.engine.ScriptImpl.execute(ScriptImpl.java:59) ~[na:na]
at org.openhab.model.rule.internal.engine.ExecuteRuleJob.execute(ExecuteRuleJob.java:55) ~[na:na]
at org.quartz.core.JobRunShell.run(JobRunShell.java:213) [quartz-all-2.1.7.jar:na]
at org.quartz.simpl.SimpleThreadPool$WorkerThread.run(SimpleThreadPool.java:557) [quartz-all-2.1.7.jar:na]
Caused by: java.lang.IllegalArgumentException: argument type mismatch
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.8.0_111]
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) ~[na:1.8.0_111]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) ~[na:1.8.0_111]
at java.lang.reflect.Method.invoke(Unknown Source) ~[na:1.8.0_111]
at org.eclipse.xtext.xbase.interpreter.impl.XbaseInterpreter.invokeOperation(XbaseInterpreter.java:729) ~[na:na]
… 26 common frames omitted

OK, that is telling. So dayOfWeek is returning a Number or perhaps even a primitive int.

It should be able to handle this but I honestly have never tried to send a Number to a String Item. Besides, I suspect that what you really want is a String and not a number.

Before moving on log out the values before we can see what is really being returned. Then we can move on to figuring out from there.