This forum uses cookies
This forum makes use of cookies to store your login information if you are registered, and your last visit if you are not. Cookies are small text documents stored on your computer; the cookies set by this forum can only be used on this website and pose no security risk. Cookies on this forum also track the specific topics you have read and when you last read them. Please confirm that you accept these cookies being set.

Push Button for shutter
#1
Dear All,
I would like to make a pushbutton for shutter. I mean that this button should send "1" or "0" everytime I push it but graphically the state has to come back to the original state.
I hope to be clear.

Thank you very much.

Claudio
Reply
#2
(30.09.2016, 14:43)Domoticatorino Wrote: Dear All,
I would like to make a pushbutton for shutter. I mean that this button should send "1" or "0" everytime I push it but graphically the state has to come back to the original state.
I hope to be clear.

Thank you very much.

Claudio

This should be 2 buttons: up and down. Every button should has the status object. Like here:
UP main:1/1/1 status:1/1/2
DOWN main:1/1/3 status:1/1/4

Main object should have event script with e.g.
Code:
status = '1/1/2'
time = 1 -- how much seconds to go back to normal image
grp.write(status, true) -- change the image to "clicked"
os.sleep(time) -- wait
grp.write(status, false) -- change the image to "normal"
Reply
#3
(30.09.2016, 19:41)buuuudzik Wrote:
(30.09.2016, 14:43)Domoticatorino Wrote: Dear All,
I would like to make a pushbutton for shutter. I mean that this button should send "1" or "0" everytime I push it but graphically the state has to come back to the original state.
I hope to be clear.

Thank you very much.

Claudio

This should be 2 buttons: up and down. Every button should has the status object. Like here:
UP main:1/1/1 status:1/1/2
DOWN main:1/1/3 status:1/1/4

Main object should have event script with e.g.
Code:
status = '1/1/2'
time = 1 -- how much seconds to go back to normal image
grp.write(status, true) -- change the image to "clicked"
os.sleep(time) -- wait
grp.write(status, false) -- change the image to "normal"

Ok. Done. Thank you.
Reply
#4
(01.10.2016, 14:18)Domoticatorino Wrote:
(30.09.2016, 19:41)buuuudzik Wrote:
(30.09.2016, 14:43)Domoticatorino Wrote: Dear All,
I would like to make a pushbutton for shutter. I mean that this button should send "1" or "0" everytime I push it but graphically the state has to come back to the original state.
I hope to be clear.

Thank you very much.

Claudio

This should be 2 buttons: up and down. Every button should has the status object. Like here:
UP main:1/1/1 status:1/1/2
DOWN main:1/1/3 status:1/1/4

Main object should have event script with e.g.
Code:
status = '1/1/2'
time = 1 -- how much seconds to go back to normal image
grp.write(status, true) -- change the image to "clicked"
os.sleep(time) -- wait
grp.write(status, false) -- change the image to "normal"

Ok. Done. Thank you.

Hi,
I am upgrading this function and as you can see KNX movement object is the same (eg. 1/1/1). 0 for the up and 1 for the down.

It mean that graphically especially in phone visualisation we have on button up and the other down. How can we fix the visualisation always down?

Thanks.
Reply
#5
Hi
Just use if else statement.
If value of 1/1/1 == 0 do ...script for status 1 else script for status 2.
BR
------------------------------
Ctrl+F5
Reply
#6
Hi Daniel,
the problem is that in Phone Visualisation, the icon in the right (toggle or checkbox) remain always UP. Where I put as fix value 0.

How can I sort it up?

Thanks.
Reply
#7
I don't think you can control smartphone visu this way. It ignores status when controlling it, this trick will work only in normal visu. You would be better in using Mosaic/Touch visu for smartphone. in there you have ready widgets for blinds.
------------------------------
Ctrl+F5
Reply
#8
Hi,
If I understand the problem correctly then you can solve the touch visualization issue by inverting the status variables and assigning the UP button the normal state variable and the DOWN button the inverted value (or the other way around - generally the button sending 0 needs the inverted status variable). This however breaks the normal/desktop/non-touch visualization. So you have to have two layouts, one for touch and one for normal visualization.

I think it is a bug in the touch visualization honestly, as the behavior is inconsistent between touch and normal visualization (the status it is inverted).



Example:
1/1/1 = control variable up/down
1/1/2 = status variable up/down
1/1/3 = inverted status variable: if 1/1/2 is 1 then 1/1/3 is 0 and the other way around. You can control this variable by simple event script. This variable can also be virtual.

Buttons will be then configured like this:
Up button = controls 1/1/1, always sends 0, status variable 1/1/3
Down button = controls 1/1/1, always sends 1, status variable 1/1/2

I hope this helps. Smile
Reply
#9
(04.10.2018, 10:01)Domoticatorino Wrote:
(01.10.2016, 14:18)Domoticatorino Wrote:
(30.09.2016, 19:41)buuuudzik Wrote:
(30.09.2016, 14:43)Domoticatorino Wrote: Dear All,
I would like to make a pushbutton for shutter. I mean that this button should send "1" or "0" everytime I push it but graphically the state has to come back to the original state.
I hope to be clear.

Thank you very much.

Claudio

This should be 2 buttons: up and down. Every button should has the status object. Like here:
UP main:1/1/1 status:1/1/2
DOWN main:1/1/3 status:1/1/4

Main object should have event script with e.g.
Code:
status = '1/1/2'
time = 1 -- how much seconds to go back to normal image
grp.write(status, true) -- change the image to "clicked"
os.sleep(time) -- wait
grp.write(status, false) -- change the image to "normal"

Ok. Done. Thank you.

Hi,
I am upgrading this function and as you can see KNX movement object is the same (eg. 1/1/1). 0 for the up and 1 for the down.

It mean that graphically especially in phone visualisation we have on button up and the other down. How can we fix the visualisation always down?

Thanks.

Hi Daniel,
have you improved the manage of shutter in visu format? Is there a ready widget like in Mosaic for shutter?

Thank you very much.
Reply
#10
Hi
There are no ready widgets in custom visu but you can make your own ones.
BR
------------------------------
Ctrl+F5
Reply
#11
(13.03.2019, 09:24)Daniel. Wrote: Hi
There are no ready widgets in custom visu but you can make your own ones.
BR

Hi Daniel,
I know that I have to create a widget by myself. I would like to know if you improve the manage shutter in visu view.
Do you know the question about the status view?
Reply


Forum Jump: