mirror of https://github.com/ARMmbed/mbed-os.git
Add Atomic<T> template
Add a C++ `Atomic<T>` template to make atomics even easier. Basically compatible with C++11 `std::atomic<T>`, but using the underlying `core_util_atomic_xxx` functions from mbed_atomic.h, so appropriate for synchronising with interrupts and optimised for uniprocessor. One extra piece of functionality beyond the `core_util_atomic_xxx` functions is the ability to have an arbitrary atomic type - eg a small structure with 2 `uint16_t`s can be stored in a `uint32_t` container.pull/10274/head
parent
5d2b37d205
commit
f9f073245b
2
mbed.h
2
mbed.h
|
|
@ -88,7 +88,7 @@
|
|||
#include "drivers/InterruptIn.h"
|
||||
#include "platform/mbed_wait_api.h"
|
||||
#include "hal/sleep_api.h"
|
||||
#include "platform/mbed_atomic.h"
|
||||
#include "platform/Atomic.h"
|
||||
#include "platform/mbed_power_mgmt.h"
|
||||
#include "platform/mbed_rtc_time.h"
|
||||
#include "platform/mbed_poll.h"
|
||||
|
|
|
|||
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue