Skip to content

php class helps you executing pilight-control from Pilight for your raspberrypi

License

Notifications You must be signed in to change notification settings

onkeloki/pilighthelper

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 

Repository files navigation

pilighthelper

php class helps you executing pilight-control from pilight for your raspberrypi

this class provides two functions to trigger on or trigger of your pilight configurations by php. the possibility to add a delay is also included.

Example Usage

<?php
include "pilighthelper.php";
$plh = new pilighthelper();
$plh->turnOn("YOUR_LOCATION","YOUR_DEVICE");
$plh->turnOff("YOUR_LOCATION","YOUR_DEVICE",5);
?>

This will power on "YOUR_DEVICE" on "YOUR_LOCATION" and will power off it in 5 seconds.

depending on your configuration you might need to add

ignore_user_abort(true);
set_time_limit(0);

to your php file

Attention

you definitley need to add www-data to your /etc/sudoers file www-data ALL = NOPASSWD: ALL

About

php class helps you executing pilight-control from Pilight for your raspberrypi

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 2

  •  
  •  

Languages