Arduino DLNA Server
Loading...
Searching...
No Matches
Public Member Functions | Protected Member Functions | Static Protected Member Functions | Protected Attributes | List of all members
tiny_dlna::TaskRTOS Class Reference

FreeRTOS task. More...

#include <TaskRTOS.h>

Public Member Functions

 TaskRTOS (const char *name, int stackSize, int priority=1, int core=-1)
 Defines and creates a FreeRTOS task.
 
 TaskRTOS ()
 
 ~TaskRTOS ()
 
void remove ()
 deletes the FreeRTOS task
 
bool begin (std::function< void()> process)
 
void end ()
 suspends the task
 
void suspend ()
 
void resume ()
 
TaskHandle_t & getTaskHandle ()
 
void setReference (void *r)
 
void * getReference ()
 

Protected Member Functions

bool create (const char *name, int stackSize, int priority=1, int core=-1)
 If you used the empty constructor, you need to call create!
 

Static Protected Member Functions

static void nop ()
 
static void task_loop (void *arg)
 

Protected Attributes

TaskHandle_t xHandle = nullptr
 
std::function< void()> loop_code = nop
 
void * ref
 

Detailed Description

FreeRTOS task.

Author
Phil Schatzmann

Constructor & Destructor Documentation

◆ TaskRTOS() [1/2]

tiny_dlna::TaskRTOS::TaskRTOS ( const char *  name,
int  stackSize,
int  priority = 1,
int  core = -1 
)
inline

Defines and creates a FreeRTOS task.

◆ TaskRTOS() [2/2]

tiny_dlna::TaskRTOS::TaskRTOS ( )
inline

◆ ~TaskRTOS()

tiny_dlna::TaskRTOS::~TaskRTOS ( )
inline

Member Function Documentation

◆ begin()

bool tiny_dlna::TaskRTOS::begin ( std::function< void()>  process)
inline

◆ create()

bool tiny_dlna::TaskRTOS::create ( const char *  name,
int  stackSize,
int  priority = 1,
int  core = -1 
)
inlineprotected

If you used the empty constructor, you need to call create!

◆ end()

void tiny_dlna::TaskRTOS::end ( )
inline

suspends the task

◆ getReference()

void * tiny_dlna::TaskRTOS::getReference ( )
inline

◆ getTaskHandle()

TaskHandle_t & tiny_dlna::TaskRTOS::getTaskHandle ( )
inline

◆ nop()

static void tiny_dlna::TaskRTOS::nop ( )
inlinestaticprotected

◆ remove()

void tiny_dlna::TaskRTOS::remove ( )
inline

deletes the FreeRTOS task

◆ resume()

void tiny_dlna::TaskRTOS::resume ( )
inline

◆ setReference()

void tiny_dlna::TaskRTOS::setReference ( void *  r)
inline

◆ suspend()

void tiny_dlna::TaskRTOS::suspend ( )
inline

◆ task_loop()

static void tiny_dlna::TaskRTOS::task_loop ( void *  arg)
inlinestaticprotected

Member Data Documentation

◆ loop_code

std::function<void()> tiny_dlna::TaskRTOS::loop_code = nop
protected

◆ ref

void* tiny_dlna::TaskRTOS::ref
protected

◆ xHandle

TaskHandle_t tiny_dlna::TaskRTOS::xHandle = nullptr
protected

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