Page 1 of 1

is it possible to run a loop in blockly ?

Posted: Tuesday 08 October 2019 10:50
by Dave21w
I need to toggle the state of a switch every hour (depending on another switches state) and i've been trying to figure it out in blocky but at present I've drawn a blank, am i just being a bit thick or is it not possible ?

Thanks

Dave

Just answered my own question, yes it is, although I don't know if how I've done it is the correct way but it seems to work for me :D

Re: is it possible to run a loop in blockly ?

Posted: Thursday 10 October 2019 10:22
by Peterus
I see you fixed it but since I'm trying to learn myself:

Can't you just make a Else If and a timer?
If On set to Off after 60 min.
If Off set to On after 60 min

Re: is it possible to run a loop in blockly ?

Posted: Friday 11 October 2019 22:58
by Dave21w
Good point, I think I will try it that way as well, always happy to learn a bit more, mine looks like this.
1hr toggle.jpg
1hr toggle.jpg (28.58 KiB) Viewed 931 times