# $Id: 98_WeekdayTimer.pm 4055 2013-10-16 20:44:49Z dietmar63 $
##############################################################################
#
# 98_WeekdayTimer.pm
# written by Dietmar Ortmann
#
# This file is part of fhem.
#
# Fhem is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 2 of the License, or
# (at your option) any later version.
#
# Fhem is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with fhem. If not, see
define <name> weekdayTimer <device> <profile> <command>|<condition>
set <device> <para>
The following parameter are defined:
Example:
define shutter WeekdayTimer bath 12345|05:20|up 12345|20:30|down
define heatingBath WeekdayTimer bath 07:00|16 Mo,Tu,Th-Fr|16:00|18.5 20:00|eco
{fhem("set dummy on"); fhem("set @ desired-temp %");}
At the given times and weekdays only(!) the command will be executed.
define dimmer WeekdayTimer livingRoom Sa-Su,We|07:00|dim30% Sa-Su,We|21:00|dim90% (ReadingsVal("WeAreThere", "state", "no") eq "yes")
The dimmer is only set to dimXX% if the dummy variable WeAreThere is "yes"(not a real live example).
If you want to have set all WeekdayTimer their current value (after a phase of exception),
you can call the function WeekdayTimer_SetAllParms ().
This call can be automatically coupled to a dummy by notify:
define WDStatus2 notify Dummy:. * {WeekdayTimer_SetAllParms ()}