Leosac  0.8.0
Open Source Access Control
Leosac::Module::LedBuzzer Namespace Reference

Namespace where implementation of Led (or buzzer) support is done. More...

Namespaces

 SM
 

Classes

class  CRUDHandler
 CRUD handler for Buzzer and LED. More...
 
struct  CRUDHandlerHelper
 
class  LedBuzzerImpl
 Implementation class, for use by the LED module only. More...
 
class  LEDBuzzerModule
 Main class for LED support. More...
 
class  WSHelperThread
 

Typedefs

typedef boost::msm::back::state_machine< SM::LedBuzzerSM_LedBuzzerSM
 

Functions

template<typename T >
std::shared_ptr< T > find_led_or_buzzer_by_id (const Hardware::DeviceId &id, DBPtr db)
 
template<>
Hardware::LEDPtr find_led_or_buzzer_by_id< Hardware::LED > (const Hardware::DeviceId &id, DBPtr db)
 
template<>
Hardware::BuzzerPtr find_led_or_buzzer_by_id< Hardware::Buzzer > (const Hardware::DeviceId &id, DBPtr db)
 

Detailed Description

Namespace where implementation of Led (or buzzer) support is done.

While LED are basically a GPIO, this module is here to provide "higher level" construct to LED device, like BLINKing. For simple command (ON, OFF, TOGGLE) it simply forwards them to the backend GPIO device that is linked with the led, so it does not provide very useful addition. However, For blinking (which requires multiple command, with varying delay) it's pretty useful.

Since logical buzzer (that you can toggle on or off) work in the same way, this modules handles both.

See also
Led Module Documentation for end-user documentation.

Typedef Documentation

◆ LedBuzzerSM

typedef boost::msm::back::state_machine<SM::LedBuzzerSM_> Leosac::Module::LedBuzzer::LedBuzzerSM

Definition at line 331 of file LedBuzzerSM.hpp.

Function Documentation

◆ find_led_or_buzzer_by_id()

template<typename T >
std::shared_ptr<T> Leosac::Module::LedBuzzer::find_led_or_buzzer_by_id ( const Hardware::DeviceId id,
DBPtr  db 
)

◆ find_led_or_buzzer_by_id< Hardware::Buzzer >()

◆ find_led_or_buzzer_by_id< Hardware::LED >()