SSCMA-Micro CPP SDK  v2.0.0
SSCMA-Micro is a cross-platform machine learning inference framework designed for embedded devices.
ma::Semaphore Class Reference

#include <ma_osal.h>

Collaboration diagram for ma::Semaphore:

Public Member Functions

 Semaphore (size_t count=0) noexcept
 
 ~Semaphore () noexcept
 
 operator bool () const
 
bool wait (ma_tick_t timeout=Tick::waitForever)
 
uint32_t getCount () const
 
void signal ()
 

Constructor & Destructor Documentation

◆ Semaphore()

ma::Semaphore::Semaphore ( size_t  count = 0)
explicitnoexcept

◆ ~Semaphore()

ma::Semaphore::~Semaphore ( )
noexcept

Member Function Documentation

◆ getCount()

uint32_t ma::Semaphore::getCount ( ) const

◆ operator bool()

ma::Semaphore::operator bool ( ) const

◆ signal()

void ma::Semaphore::signal ( )

◆ wait()

bool ma::Semaphore::wait ( ma_tick_t  timeout = Tick::waitForever)