Turn my kids xbox off if they don't do their chores


#1

1) Give a description of the problem
virtual switch wont reset

2) What is the expected behaviour?
I’d like to execute a google home routine that turn a virtual switch on that triggers this piston. The piston should blink my kids lights, wait x seconds, and then turn his outlet off. If I press the up button a few times on a different switch, it should cancel the “xbox shutdown sequence” :slight_smile:

3) What is happening/not happening?
When i turn the virtual switch on, it stays on, and is not ready for me to execute the command at a later time. Im thinking the switch needs to be automatically set to off. I thought a momentary push button would work better, but i can seem to link a google home routine to a momentary push button.

**4) Post a Green Snapshot of the piston![image|45x37]


#2

Sorry for this dumb question, but can your kids access the outlet?

Keeping in mind their “bond” with the Xbox, I would imagine any kid at least 6 years old will quickly bypass the smart outlet, and plug directly into the wall. (thereby ignoring your logic entirely)

IE: You will spend 100 times longer coding this, than it will take for them to get around it.


Translation: I would only attempt this project if you really wanted a learning exercise…
After the first or second success, I would not expect it to be reliable any longer…
(unless the kids are real young)

For a moment, I was thinking the Xbox may be “controllable” if the outlet was under lock & key, but then I remembered a spare cord can easily bypass that as well…


#3

yes, i realize that. I’m definitely also interested in learning :slight_smile:


#4

my mom’s slap would blink all my lights… Good ol’days, she didn’t need pistons, her hands were just enough LOL (of course just kidding, she never even punished me, bless her soul)


#5

I’m assuming Dimmer 1’s button #9 is the virtual switch that the google routine turns on? Whichever it is, you need to add something to your piston to turn the virtual switch off when you are done processing the request. I would suggest at the end of the first If block in your piston.


#6

I always found angry Dad standing in the door worked best.

My daughter is 33 now, and when she was at home we didn’t have all the home automation stuff I have now, but I think I still would have went with the personal approach.


#7

For anyone that is interested, I got it working. I created a google assistant routine that sends a broadcast throughout the house letting my kids know its time to do their chores and turn on a virtual switch. The virtual switch triggers this piston that blinks their lights a few times giving them a 15 minute warning. If they dont come find me and let me know they are starting their chores, their outlet will be turned off. If they do find me and let me know they started their chores. I’ll press the up button on one of my switches 4 times. This will cancel the 15 minute timer and blink a nearby light one time. the purpose of the blink is to verify i clicked the button 4 times. Heres a copy of the piston. Enjoy!


#8

Just so you know, the way piston “7itw” is worded, you can also cancel turning off Switch 11 (Xbox) by turning off Switch 14.