NAME
App::RPi::EnvUI::Event - Asynchronous events for the Perl portion of App::RPi::EnvUI
SYNOPSIS
use App::RPi::EnvUI::API;
use App::RPi::EnvUI::Event;
my $api = App::RPi::EnvUI::API->new;
my $events = App::RPi::EnvUI::Event->new;
my $env_to_db_event = $events->env_to_db;
my $env_action_event = $events->env_action;
$env_to_db_event->start;
$env_action_event->start;
DESCRIPTION
This is a helper module for App::RPi::EnvUI, which contains the scheduled asynchronous Perl events on the server side of the webapp.
These events are objects of the Async::Event::Interval class, and run in a separate process than the rest of the application.
METHODS
new(%args)
Returns a new App::RPi::EnvUI::Event
object. The parameters are passed in within a hash format.
Parameters:
testing
Optional, Bool: 0
disables testing mode, 1
enables it.
env_to_db
Returns the event that polls the environment sensors, and updates the stats
environment database table.
env_action
Returns the event that enables/disables the GPIO pins associated with the environment.
SEE ALSO
AUTHOR
Steve Bertrand, <steveb@cpan.org<gt>
LICENSE AND COPYRIGHT
Copyright 2017 Steve Bertrand.
This program is free software; you can redistribute it and/or modify it under the terms of either: the GNU General Public License as published by the Free Software Foundation; or the Artistic License.
See http://dev.perl.org/licenses/ for more information.