Lamp-Da 0.1
A compact lantern project
Loading...
Searching...
No Matches
Public Member Functions | Public Attributes | List of all members
lampda::logic::alerts::Alert_TempCritical Struct Reference

This alert is raised when the temperature gets too high. If it keeps climbing, the components will get dammaged. More...

Inheritance diagram for lampda::logic::alerts::Alert_TempCritical:
lampda::logic::alerts::AlertBase

Public Member Functions

bool should_be_raised () const override
 return true if this alert type should be raised
 
uint32_t alert_shutdown_timeout () const override
 Shutdown fast.
 
bool show () const override
 display this alert on the indicator
 
Type get_type () const override
 return the Defined type of this alert
 
bool should_prevent_lamp_output () const override
 Prevent lamp output.
 
bool should_prevent_battery_charge () const override
 prevent battery charging
 
bool should_prevent_usb_port_use () const override
 prevent USB port use
 
virtual void execute () const
 function executed when this alert is raised
 
virtual bool should_be_cleared () const
 return true if this alert type should be cleared
 
virtual bool should_shutdown_system (const uint32_t time) final
 Return true if the system should shutdown from this alert.
 
virtual bool handle_raised_state (const uint32_t time)
 Handler for the raised state of the alert. If the alert is not raised, raise the alert.
 
void update_raise_time (const uint32_t time)
 Update the raised time of this alert. An alert continuously firing as to be updated.
 
virtual bool handle_lowered_state (const uint32_t time)
 Handler for the lowered state of the alert. If the alert is raised, lower the alert.
 

Public Attributes

bool _isRaisedHandled = false
 Alert raise signal has been handled.
 
bool _isLoweredHandled = false
 Alert lower signal has been handled.
 
uint32_t raisedTime = 0
 Store the latest time at which this alert raise() was called.
 
uint32_t loweredTime = 0
 Store the latest time at which this alert lower() was called.
 

Detailed Description

This alert is raised when the temperature gets too high. If it keeps climbing, the components will get dammaged.

Member Function Documentation

◆ alert_shutdown_timeout()

uint32_t lampda::logic::alerts::Alert_TempCritical::alert_shutdown_timeout ( ) const
inlineoverridevirtual

Shutdown fast.

Reimplemented from lampda::logic::alerts::AlertBase.

◆ execute()

virtual void lampda::logic::alerts::AlertBase::execute ( ) const
inlinevirtualinherited

function executed when this alert is raised

Reimplemented in lampda::logic::alerts::Alert_BatteryLow, and lampda::logic::alerts::Alert_TempTooHigh.

◆ get_type()

Type lampda::logic::alerts::Alert_TempCritical::get_type ( ) const
inlineoverridevirtual

return the Defined type of this alert

Implements lampda::logic::alerts::AlertBase.

◆ handle_lowered_state()

virtual bool lampda::logic::alerts::AlertBase::handle_lowered_state ( const uint32_t  time)
inlinevirtualinherited

Handler for the lowered state of the alert. If the alert is raised, lower the alert.

Returns
True if the alert was lowered by this function call

◆ handle_raised_state()

virtual bool lampda::logic::alerts::AlertBase::handle_raised_state ( const uint32_t  time)
inlinevirtualinherited

Handler for the raised state of the alert. If the alert is not raised, raise the alert.

Returns
True if the alert was raised by this function call

◆ should_be_cleared()

virtual bool lampda::logic::alerts::AlertBase::should_be_cleared ( ) const
inlinevirtualinherited

◆ should_be_raised()

bool lampda::logic::alerts::Alert_TempCritical::should_be_raised ( ) const
inlineoverridevirtual

return true if this alert type should be raised

Reimplemented from lampda::logic::alerts::AlertBase.

◆ should_prevent_battery_charge()

bool lampda::logic::alerts::Alert_TempCritical::should_prevent_battery_charge ( ) const
inlineoverridevirtual

prevent battery charging

Reimplemented from lampda::logic::alerts::AlertBase.

◆ should_prevent_lamp_output()

bool lampda::logic::alerts::Alert_TempCritical::should_prevent_lamp_output ( ) const
inlineoverridevirtual

Prevent lamp output.

Reimplemented from lampda::logic::alerts::AlertBase.

◆ should_prevent_usb_port_use()

bool lampda::logic::alerts::Alert_TempCritical::should_prevent_usb_port_use ( ) const
inlineoverridevirtual

prevent USB port use

Reimplemented from lampda::logic::alerts::AlertBase.

◆ show()

bool lampda::logic::alerts::Alert_TempCritical::show ( ) const
inlineoverridevirtual

display this alert on the indicator

Reimplemented from lampda::logic::alerts::AlertBase.


The documentation for this struct was generated from the following file: