mbed-os/rtos
Kevin Bracey 436301dc5e Add Mutex::trylock_until and trylock_for
Given the 64-bit timebase, add trylock_until to Mutex.

Naming is based on a combination of Mutex::trylock, Thread::wait_until,
and C++11 timed_mutex::try_lock_until.

pthreads and C11 use "timedlock", but that's not a good fit against our
existing trylock() and lock(timeout) - they have only absolute-time
waits, not relative.

To increase the similarity to C++11, add trylock_for - same parameters
as lock, but with the bool return value of trylock and trylock_until.

Add an assertion when convering status codes to booleans to check that
there are no non-timeout errors.
2018-02-09 14:18:44 +00:00
..
TARGET_CORTEX Remove tickless assert for tick count 2018-01-27 00:57:55 -06:00
ConditionVariable.cpp Add ConditionVariable::wait_until 2018-02-09 14:18:44 +00:00
ConditionVariable.h Add ConditionVariable::wait_until 2018-02-09 14:18:44 +00:00
EventFlags.cpp Shrink RTOS classes 2017-11-03 15:22:22 +02:00
EventFlags.h Copy edit EventFlags.h 2018-01-27 00:57:21 -06:00
Kernel.cpp Add Kernel::get_ms_count 2018-02-09 14:18:44 +00:00
Kernel.h Add Kernel::get_ms_count 2018-02-09 14:18:44 +00:00
Mail.h Copy edit Mail.h 2018-01-27 00:57:21 -06:00
MemoryPool.h Copy edit MemoryPool.h 2018-01-27 00:57:21 -06:00
Mutex.cpp Add Mutex::trylock_until and trylock_for 2018-02-09 14:18:44 +00:00
Mutex.h Add Mutex::trylock_until and trylock_for 2018-02-09 14:18:44 +00:00
Queue.h Copy edit Queue.h 2018-01-27 00:57:21 -06:00
RtosTimer.cpp Shrink RTOS classes 2017-11-03 15:22:22 +02:00
RtosTimer.h Copy edit RtosTimer.h 2018-01-27 00:57:22 -06:00
Semaphore.cpp Shrink RTOS classes 2017-11-03 15:22:22 +02:00
Semaphore.h Copy edit Semaphore.h 2018-01-27 00:57:22 -06:00
Thread.cpp Fixed whitespace 2017-12-20 16:05:44 +00:00
Thread.h Copy edit Thread.h 2018-01-27 00:57:22 -06:00
mbed_lib.json RTOS - add config mbed_lib.json file 2016-06-08 18:41:29 +01:00
rtos.h Add Kernel::get_ms_count 2018-02-09 14:18:44 +00:00
rtos_idle.h Doxygen comment updates and fixes 2017-10-26 15:36:26 -05:00