36#ifndef NUMBER_OF_WORKERS
37#define NUMBER_OF_WORKERS 1
void * lf_mutex_t
Definition lf_arduino_support.h:118
void lf_semaphore_destroy(lf_semaphore_t *semaphore)
Destroy the 'semaphore'.
Definition lf_semaphore.c:100
void lf_semaphore_wait(lf_semaphore_t *semaphore)
Wait on the 'semaphore' if count is 0.
Definition lf_semaphore.c:86
lf_semaphore_t * lf_semaphore_new(size_t count)
Create a new semaphore.
Definition lf_semaphore.c:44
void lf_semaphore_acquire(lf_semaphore_t *semaphore)
Acquire the 'semaphore'. Will block if count is 0.
Definition lf_semaphore.c:71
void lf_semaphore_release(lf_semaphore_t *semaphore, size_t i)
Release the 'semaphore' and add 'i' to its count.
Definition lf_semaphore.c:58
Definition lf_POSIX_threads_support.h:41
Definition lf_semaphore.h:43
lf_cond_t cond
Definition lf_semaphore.h:46
lf_mutex_t mutex
Definition lf_semaphore.h:45
size_t count
Definition lf_semaphore.h:44