ESPixelStick Firmware
Firmware for the ESPixelStick
Loading...
Searching...
No Matches
c_OutputMgr Class Reference

#include <OutputMgr.hpp>

Public Types

enum  e_OutputProtocolType { OutputProtocol_Disabled = 0 , OutputProtocol_Last }
 

Public Member Functions

 c_OutputMgr ()
 < Start up the driver and put it into a safe mode
 
virtual ~c_OutputMgr ()
 < deallocate any resources and put the output channels into a safe state
 
void Begin ()
 set up the operating environment based on the current config (or defaults)
 
void Poll ()
 Call from loop(), renders output data.
 
void ScheduleLoadConfig ()
 
void LoadConfig ()
 Read the current configuration data from nvram.
 
void GetConfig (byte *Response, uint32_t maxlen)
 
void GetConfig (String &Response)
 
void SetConfig (const char *NewConfig)
 Save the current configuration data to nvram.
 
void SetConfig (ArduinoJson::JsonDocument &NewConfig)
 Save the current configuration data to nvram.
 
void GetStatus (JsonObject &jsonStatus)
 
uint8_t * GetBufferAddress ()
 Get the address of the buffer into which the E1.31 handler will stuff data.
 
uint32_t GetBufferUsedSize ()
 Get the size (in intensities) of the buffer into which the E1.31 handler will stuff data.
 
uint32_t GetBufferSize ()
 Get the size (in intensities) of the buffer into which the E1.31 handler will stuff data.
 
void DeleteConfig ()
 
void PauseOutputs (bool NewState)
 
void GetDriverName (String &Name)
 
void WriteChannelData (uint32_t StartChannelId, uint32_t ChannelCount, uint8_t *pData)
 
void ReadChannelData (uint32_t StartChannelId, uint32_t ChannelCount, uint8_t *pTargetData)
 
void ClearBuffer ()
 
void TaskPoll ()
 
void RelayUpdate (uint8_t RelayId, String &NewValue, String &Response)
 
void ClearStatistics (void)
 
uint8_t GetNumPorts ()
 

Public Attributes

uint32_t NumberOfOutputProtocols = uint32_t(0)
 

Private Member Functions

bool ProcessJsonConfig (JsonDocument &jsonConfig)
 
void CreateJsonConfig (JsonObject &jsonConfig)
 
void UpdateDisplayBufferReferences (void)
 
void InstantiateNewOutputChannel (uint32_t PortIndex, e_OutputProtocolType NewChannelType, bool StartDriver=true)
 
void CreateNewConfig ()
 
void SetSerialUart ()
 
bool FindJsonChannelConfig (JsonDocument &jsonConfig, OM_PortId_t PortId, JsonObject &ChanConfig)
 
bool SetPortDefnitionDefaults (uint32_t PortIndex, e_OutputProtocolType TargetProtocolType)
 

Private Attributes

uint8_t NumOutputPorts
 
bool HasBeenInitialized = false
 
time_t ConfigLoadNeeded = NO_CONFIG_NEEDED
 
bool ConfigInProgress = false
 
bool OutputIsPaused = false
 
bool BuildingNewConfig = false
 
String ConfigFileName
 
uint8_t * pOutputBuffer = nullptr
 
uint32_t UsedBufferSize = 0
 
gpio_num_t ConsoleTxGpio = DEFAULT_CONSOLE_TX_GPIO
 
gpio_num_t ConsoleRxGpio = DEFAULT_CONSOLE_RX_GPIO
 

Member Enumeration Documentation

◆ e_OutputProtocolType

Enumerator
OutputProtocol_Disabled 
OutputProtocol_Last 

Constructor & Destructor Documentation

◆ c_OutputMgr()

c_OutputMgr::c_OutputMgr ( )

< Start up the driver and put it into a safe mode

Here is the call graph for this function:

◆ ~c_OutputMgr()

c_OutputMgr::~c_OutputMgr ( )
virtual

< deallocate any resources and put the output channels into a safe state

Member Function Documentation

◆ Begin()

void c_OutputMgr::Begin ( )

set up the operating environment based on the current config (or defaults)

< Start the module

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ClearBuffer()

void c_OutputMgr::ClearBuffer ( )
Here is the call graph for this function:
Here is the caller graph for this function:

◆ ClearStatistics()

void c_OutputMgr::ClearStatistics ( void )
Here is the call graph for this function:
Here is the caller graph for this function:

◆ CreateJsonConfig()

void c_OutputMgr::CreateJsonConfig ( JsonObject & jsonConfig)
private
Here is the call graph for this function:
Here is the caller graph for this function:

◆ CreateNewConfig()

void c_OutputMgr::CreateNewConfig ( )
private
Here is the call graph for this function:
Here is the caller graph for this function:

◆ DeleteConfig()

void c_OutputMgr::DeleteConfig ( )
inline
Here is the call graph for this function:
Here is the caller graph for this function:

◆ FindJsonChannelConfig()

bool c_OutputMgr::FindJsonChannelConfig ( JsonDocument & jsonConfig,
OM_PortId_t PortId,
JsonObject & ChanConfig )
private
Here is the call graph for this function:
Here is the caller graph for this function:

◆ GetBufferAddress()

uint8_t * c_OutputMgr::GetBufferAddress ( )
inline

Get the address of the buffer into which the E1.31 handler will stuff data.

Here is the caller graph for this function:

◆ GetBufferSize()

uint32_t c_OutputMgr::GetBufferSize ( )
inline

Get the size (in intensities) of the buffer into which the E1.31 handler will stuff data.

Here is the caller graph for this function:

◆ GetBufferUsedSize()

uint32_t c_OutputMgr::GetBufferUsedSize ( )
inline

Get the size (in intensities) of the buffer into which the E1.31 handler will stuff data.

Here is the caller graph for this function:

◆ GetConfig() [1/2]

void c_OutputMgr::GetConfig ( byte * Response,
uint32_t maxlen )
Here is the call graph for this function:
Here is the caller graph for this function:

◆ GetConfig() [2/2]

void c_OutputMgr::GetConfig ( String & Response)
Here is the call graph for this function:

◆ GetDriverName()

void c_OutputMgr::GetDriverName ( String & Name)
inline
Here is the caller graph for this function:

◆ GetNumPorts()

uint8_t c_OutputMgr::GetNumPorts ( )
inline
Here is the caller graph for this function:

◆ GetStatus()

void c_OutputMgr::GetStatus ( JsonObject & jsonStatus)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ InstantiateNewOutputChannel()

void c_OutputMgr::InstantiateNewOutputChannel ( uint32_t PortIndex,
e_OutputProtocolType NewChannelType,
bool StartDriver = true )
private
Here is the call graph for this function:
Here is the caller graph for this function:

◆ LoadConfig()

void c_OutputMgr::LoadConfig ( )

Read the current configuration data from nvram.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ PauseOutputs()

void c_OutputMgr::PauseOutputs ( bool NewState)
Here is the caller graph for this function:

◆ Poll()

void c_OutputMgr::Poll ( )

Call from loop(), renders output data.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ ProcessJsonConfig()

bool c_OutputMgr::ProcessJsonConfig ( JsonDocument & jsonConfig)
private
Here is the call graph for this function:

◆ ReadChannelData()

void c_OutputMgr::ReadChannelData ( uint32_t StartChannelId,
uint32_t ChannelCount,
uint8_t * pTargetData )
Here is the call graph for this function:
Here is the caller graph for this function:

◆ RelayUpdate()

void c_OutputMgr::RelayUpdate ( uint8_t RelayId,
String & NewValue,
String & Response )
Here is the caller graph for this function:

◆ ScheduleLoadConfig()

void c_OutputMgr::ScheduleLoadConfig ( )
inline
Here is the caller graph for this function:

◆ SetConfig() [1/2]

void c_OutputMgr::SetConfig ( ArduinoJson::JsonDocument & NewConfig)

Save the current configuration data to nvram.

Here is the call graph for this function:

◆ SetConfig() [2/2]

void c_OutputMgr::SetConfig ( const char * NewConfig)

Save the current configuration data to nvram.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ SetPortDefnitionDefaults()

bool c_OutputMgr::SetPortDefnitionDefaults ( uint32_t PortIndex,
e_OutputProtocolType TargetProtocolType )
private
Here is the caller graph for this function:

◆ SetSerialUart()

void c_OutputMgr::SetSerialUart ( )
private
Here is the caller graph for this function:

◆ TaskPoll()

void c_OutputMgr::TaskPoll ( )

◆ UpdateDisplayBufferReferences()

void c_OutputMgr::UpdateDisplayBufferReferences ( void )
private
Here is the call graph for this function:
Here is the caller graph for this function:

◆ WriteChannelData()

void c_OutputMgr::WriteChannelData ( uint32_t StartChannelId,
uint32_t ChannelCount,
uint8_t * pData )
Here is the call graph for this function:
Here is the caller graph for this function:

Member Data Documentation

◆ BuildingNewConfig

bool c_OutputMgr::BuildingNewConfig = false
private

◆ ConfigFileName

String c_OutputMgr::ConfigFileName
private

◆ ConfigInProgress

bool c_OutputMgr::ConfigInProgress = false
private

◆ ConfigLoadNeeded

time_t c_OutputMgr::ConfigLoadNeeded = NO_CONFIG_NEEDED
private

◆ ConsoleRxGpio

gpio_num_t c_OutputMgr::ConsoleRxGpio = DEFAULT_CONSOLE_RX_GPIO
private

◆ ConsoleTxGpio

gpio_num_t c_OutputMgr::ConsoleTxGpio = DEFAULT_CONSOLE_TX_GPIO
private

◆ HasBeenInitialized

bool c_OutputMgr::HasBeenInitialized = false
private

◆ NumberOfOutputProtocols

uint32_t c_OutputMgr::NumberOfOutputProtocols = uint32_t(0)

◆ NumOutputPorts

uint8_t c_OutputMgr::NumOutputPorts
private

◆ OutputIsPaused

bool c_OutputMgr::OutputIsPaused = false
private

◆ pOutputBuffer

uint8_t* c_OutputMgr::pOutputBuffer = nullptr
private

◆ UsedBufferSize

uint32_t c_OutputMgr::UsedBufferSize = 0
private

The documentation for this class was generated from the following files: