Limiting Mycroft's operating hours

Hi

This idea might seem strange, but I’m trying to make a version of Mycroft that is only operational between the hours of 9am - 5pm.

Outside these times, i’d like Mycroft to respond to any request from the user by saying something like: ‘don’t bother me, it’s outside my working hours’.

I’ve tried to look into whether or not this requires changes to the config file or a new skill of some kind but i’m totally lost. If anyone has any suggestions, that’d be unreal.

Thanks
Julian

I think there’s multiple ways you could go around doing this.

One would be to pre-record the outside hours phrase and have an external service actually start/stop mycroft depending on the time and then merely play the phrase if the microphone levels go above a certain level for a specified time.

Another would be using something like GitHub - jannewmarch/mycroft-with-fail: Mycroft core adapted to allow fail of intents, so others can be tried, where you could in theory define a skill that responds to all utterances and fail if whiting working hours so the other skills can respond and return your phrase otherwise.

Depends if you need mycroft to actually run or not during the off time I guess.

That’s really helpful, thanks @MoffKalast.

I like the idea of a skill that responds to all utterances and fails within working hours. If a request is made outside working hours, the skill could be activated and then toggle through a few random utterances.

I will keep the second option in mind if i can’t get the coding to work!

Thanks again!

1 Like

Maybe the “naptime skill” can help here or give an idea how to implement your requirement.