Free domotica! › Forums › How can I …? › Synology NAS › make my washing maschine tell me, that washing is finished
- This topic has 2 replies, 2 voices, and was last updated 4 years, 10 months ago by
djandib.
-
AuthorPosts
-
March 24, 2016 at 11:31 am #3016
djandib
ParticipantI’ve been working since a few days at this scene:
GOAL:
Send a message, if washing is done and the wet clothes can be taken out of the machineHARDWARE:
– additional FIBARO WALL switchHOWTO (This Version does NOT finally work!):
// Machine is turned on and is started
IF COMPARATOR=”Machine” Power > “10” AND Variable “Var_Machine” =”0″
DO Set Variable “Var_Machine” to “1”// Machine has finished, but is not turned off
IF Variable “Var_Maschine”=”1″
DO IF COMPARATOR=”Machine” Power > “0” AND COMPARATOR=”Machine” Power < “10”
DO Send Pushover “Machine Finished; Take out clothes”
Sleep 5 Minutes //Pupose: Send Message again in 5 Minutes
ELSE IF COMPARATOR=”Machine” Power = “0” // Machine has finished and is turned off
DO Set Variable “Var_Machine” to “0”
EXIT
EXITPROBLEM:
I made some experiments with sending me pushover and recognized, that in the end the Variable “Var_Machine” is to “0”.
But in the next run (one minute later) in the beginning of Scene the Variable “Var_Machine” is “”…
So: The Variable “VAR_Machine” seems not to be saved…Any idea?
March 24, 2016 at 4:43 pm #3017K.Rens
KeymasterDo you have the database service installed and properly configured?
The variable status might be saved in the database.Can you take a screenshot of your scene, just to see it exactly, as you may have implemented it different then what we expected.
Kind regards,
K.RensApril 8, 2016 at 11:20 am #3157djandib
ParticipantFinal Solution: (final tested)
HOWTO:
PHP-Block: $waschmaschine = file_get_contents(‘waschmaschine’, FILE_USE_INCLUDE_PATH);
// Machine is turned on and is started
IF COMPARATOR=”Machine” Power < “50” AND Variable “Waschmaschine” <> ”1″
DO PHP-Block:
$file = ‘waschmaschine’;
$current = file_get_contents($waschmaschine);
$current = “1”;
file_put_contents($file, $current);
PHP-Block
$waschmaschine = file_get_contents(‘waschmaschine’, FILE_USE_INCLUDE_PATH);
// Machine has finished, but is not turned off
IF Variable “waschmaschine”=”1″
DO IF COMPARATOR=”Machine” Power > “2” AND COMPARATOR=”Machine” Power < “3”
DO Send Pushover “Machine Finished; Take out clothes”
Sleep 5 Minutes //Pupose: Send Message again in 5 Minutes
IF COMPARATOR=”Machine” Power < “1” // Machine has finished and is turned off
DO PHP-Block:
$file = ‘waschmaschine’;
$current = file_get_contents($waschmaschine);
$current = “0”;
file_put_contents($file, $current);
EXIT
EXIT
***
Thanx to Koen for support -
AuthorPosts
- You must be logged in to reply to this topic.