Rollershutter state on nodered

Hi all

I’ve some issue on using the roller shutter items on nodered
In particular I’ve create a virtual Rolleshutter Iem to test a rule

Switch ESP1 "ESP1" { mqtt=">[home:/Ta020a614ab82/gpio/12:command:ON:0],>[home:/Ta020a614ab82/gpio/12:command:OFF:1]"}
Switch ESP2 "ESP2" { mqtt=">[home:/Ta020a614ab82/gpio/13:command:ON:0],>[home:/Ta020a614ab82/gpio/13:command:OFF:1]"}

Rollershutter Persiana_Salone "Persiana_Studio"

I’ve set an openhab button to send the UP command

01

but when i push the button the item assume on the first pressing of the button the 0 value and on the second the UP value and the same for the DOWN Button on the first pressing of the button the 100 value and on the second the DOWN value

17
25

Platform information:

  • Hardware: VM
  • OS: Ubuntu Server
  • Java Runtime Environment: Oracle
  • openHAB version: 2.2

Can you show your event log when you press the buttons?

2018-04-04 17:01:13.820 [ome.event.ItemCommandEvent] - Item 'Serranda_Studio' received command UP

2018-04-04 17:01:13.831 [vent.ItemStateChangedEvent] - Serranda_Studio changed from NULL to 0

2018-04-04 17:01:23.978 [ome.event.ItemCommandEvent] - Item 'Serranda_Studio' received command UP

What is the item definition of Persiana_Salone?

For Now is empty for demo

Rollershutter Serranda_Studio	"Serranda Studio [(%d)]"

My understanding it that rollershutter items are numbers like a dimmer item between 0 and 100 BUT they accept commands like UP, DOWN, STOP, MOVE and a value

In the log we can see that the item received the command UP but the state changed to 0
The state of a rollershutter will always be a number between 0 and 100
So in node-red, in the node-configuration, monitor the state if the rollershutter and react to the value.

Did that help?

Thanks for the reply, but the problem is that in nodered I can not see the stop command, I think I would use a string to handle the commands

I will try something and come back to you, I am in the process of re-cabling my switch and server set-up. Big tangle!!

I did some tests and this is the result of debugging if I press the DOWN key and then STOP

as you can see the commands arrive but only if I take the channel 2 with the raw data

and i don’t now how to filter this data

I’ve try but it didn’t work

I’ve found the solution the correct property is msg.payload.payload.value

Many thanks Vincent

I’ve now an other problem every time I select the UP command the percent value going automatically to 0 and the same is for the Down selection that going to 100 value

this is real problem because i need to inject UP state but to leave the percent value inalterate

Use a change node or a function node to change the value