µOS++ IIIe Reference 7.0.0
The third edition of µOS++, a POSIX inspired open source framework, written in C++
Loading...
Searching...
No Matches
os-decls.h File Reference
#include <cmsis-plus/os-versions.h>
#include <cmsis-plus/rtos/port/os-decls.h>
#include <cmsis-plus/diag/trace.h>
#include <cstdint>
#include <cstddef>
#include <cerrno>
#include <cstring>
#include <cmsis-plus/rtos/internal/os-lists.h>
#include <cmsis-plus/rtos/os-types.h>
#include <cmsis-plus/estd/system_error>

Go to the source code of this file.

Classes

class  os::rtos::internal::attributes_clocked
 Base class for attributes. More...
 
class  os::rtos::port::clock_highres
 
class  os::rtos::port::clock_rtc
 
class  os::rtos::port::clock_systick
 
class  os::rtos::port::context
 
class  os::rtos::port::interrupts::critical_section
 
class  os::rtos::null_locker
 Null locker. More...
 
class  os::rtos::internal::object_named
 Base class for named objects. More...
 
class  os::rtos::internal::object_named_system
 Base class for named system objects. More...
 
class  os::rtos::port::thread
 
class  os::rtos::port::interrupts::uncritical_section
 

Namespaces

namespace  os
 System namespace.
 
namespace  os::rtos
 RTOS namespace.
 
namespace  os::rtos::flags
 Generic flags namespace.
 
namespace  os::rtos::flags::mode
 Flags modes.
 
namespace  os::rtos::internal
 A namespace to group all internal implementation objects.
 
namespace  os::rtos::interrupts
 Interrupts namespace.
 
namespace  os::rtos::memory
 
namespace  os::rtos::port
 
namespace  os::rtos::port::clock
 
namespace  os::rtos::port::interrupts
 
namespace  os::rtos::port::scheduler
 
namespace  os::rtos::port::this_thread
 
namespace  os::rtos::result
 Values returned by RTOS functions.
 
namespace  os::rtos::scheduler
 Scheduler namespace.
 
namespace  os::rtos::statistics
 Statistics namespace.
 
namespace  os::rtos::this_thread
 A convenience namespace to access the current running thread.
 

Macros

#define os_assert_err(__e, __er)   assert(__e)
 Assert or return an error.
 
#define os_assert_throw(__e, __er)   assert(__e)
 Assert or throw a system error exception.
 
#define OS_BOOL_RTOS_SCHEDULER_PREEMPTIVE   (true)
 
#define OS_INTEGER_RTOS_IDLE_STACK_SIZE_BYTES   (os::rtos::port::stack::default_size_bytes)
 
#define OS_INTEGER_RTOS_MAIN_STACK_SIZE_BYTES   (os::rtos::port::stack::default_size_bytes)
 
#define OS_INTEGER_RTOS_REUSE_MAGIC   (0xA55AAA55)
 
#define OS_INTEGER_SYSTICK_FREQUENCY_HZ   (1000)
 

Typedefs

using os::rtos::statistics::counter_t = uint64_t
 Type of variables holding context switches counters.
 
using os::rtos::statistics::duration_t = uint64_t
 Type of variables holding durations in CPU cycles.
 
using os::rtos::port::clock::duration_t = uint32_t
 Type of variables holding timer durations.
 
using os::rtos::flags::mask_t = uint32_t
 Type of variables holding flags masks.
 
using os::rtos::flags::mode_t = uint32_t
 Type of variables holding flags modes.
 
using os::rtos::port::clock::offset_t = int64_t
 
using os::rtos::result_t = uint32_t
 Type of values returned by RTOS functions.
 
using os::rtos::scheduler::state_t = port::scheduler::state_t
 Type of variables holding scheduler state codes.
 
using os::rtos::interrupts::state_t = port::interrupts::state_t
 Type of variables holding interrupts statu codes.
 
using os::rtos::port::clock::timestamp_t = uint64_t
 Type of variables holding time stamps.
 

Enumerations

enum  : result_t { os::rtos::result::ok = 0 }
 Custom enumerated values. More...
 
enum  : mask_t {
  os::rtos::flags::any = 0 ,
  os::rtos::flags::all = 0xFFFFFFFF
}
 Flags sets with special meaning. More...
 
enum  : mode_t {
  os::rtos::flags::mode::all = 1 ,
  os::rtos::flags::mode::any = 2 ,
  os::rtos::flags::mode::clear = 4
}
 Bits used to specify the flags modes. More...
 

Functions

void os::rtos::port::scheduler::_wait_for_interrupt (void)
 
void os::rtos::port::scheduler::greeting (void)
 
bool os::rtos::port::interrupts::in_handler_mode (void)
 
result_t os::rtos::port::scheduler::initialize (void)
 
port::scheduler::state_t os::rtos::port::scheduler::lock (void)
 
port::scheduler::state_t os::rtos::port::scheduler::locked (port::scheduler::state_t state)
 
bool os::rtos::port::scheduler::locked (void)
 
bool os::rtos::port::scheduler::preemptive (bool)
 
bool os::rtos::port::scheduler::preemptive (void)
 
void os::rtos::port::this_thread::prepare_suspend (void)
 
void os::rtos::port::scheduler::reschedule (void)
 
void os::rtos::port::scheduler::start (void)
 
stack::element_t * os::rtos::port::scheduler::switch_stacks (stack::element_t *sp)
 
port::scheduler::state_t os::rtos::port::scheduler::unlock (void)
 
void os::rtos::port::this_thread::yield (void)
 

Macro Definition Documentation

◆ os_assert_err

#define os_assert_err (   __e,
  __er 
)    assert(__e)

Assert or return an error.

As required by the ANSI standards, if NDEBUG is defined, the assertion is disabled and if the condition is true, the given error code is returned.

Definition at line 1115 of file os-decls.h.

◆ os_assert_throw

#define os_assert_throw (   __e,
  __er 
)    assert(__e)

Assert or throw a system error exception.

As required by the ANSI standards, if NDEBUG is defined, the assertion is disabled and if the condition is true, a ssytem error exception is thrown (which is replaced by an abort() if exceptions are disabled).

Definition at line 1130 of file os-decls.h.

◆ OS_BOOL_RTOS_SCHEDULER_PREEMPTIVE

#define OS_BOOL_RTOS_SCHEDULER_PREEMPTIVE   (true)

Definition at line 1155 of file os-decls.h.

◆ OS_INTEGER_RTOS_IDLE_STACK_SIZE_BYTES

#define OS_INTEGER_RTOS_IDLE_STACK_SIZE_BYTES   (os::rtos::port::stack::default_size_bytes)

Definition at line 1151 of file os-decls.h.

◆ OS_INTEGER_RTOS_MAIN_STACK_SIZE_BYTES

#define OS_INTEGER_RTOS_MAIN_STACK_SIZE_BYTES   (os::rtos::port::stack::default_size_bytes)

Definition at line 1147 of file os-decls.h.

◆ OS_INTEGER_RTOS_REUSE_MAGIC

#define OS_INTEGER_RTOS_REUSE_MAGIC   (0xA55AAA55)

Definition at line 1159 of file os-decls.h.

◆ OS_INTEGER_SYSTICK_FREQUENCY_HZ

#define OS_INTEGER_SYSTICK_FREQUENCY_HZ   (1000)

Definition at line 1141 of file os-decls.h.