13#pragma clang diagnostic ignored "-Wempty-translation-unit"
18#if defined(__ARM_EABI__)
24#if defined(OS_USE_OS_APP_CONFIG_H)
25#include <cmsis-plus/os-app-config.h>
28#if defined(OS_USE_TRACE_ITM)
34#include <cmsis_device.h>
53#if defined(__ARM_ARCH_7M__) || defined(__ARM_ARCH_7EM__)
64#if !defined(OS_INTEGER_TRACE_ITM_STIMULUS_PORT)
65#define OS_INTEGER_TRACE_ITM_STIMULUS_PORT (0)
69 write (
const void* buf, std::size_t nbyte)
71 if (buf ==
nullptr || nbyte == 0)
76 const char* cbuf = (
const char*)buf;
78 for (
size_t i = 0; i < nbyte; i++)
81 if (((ITM->TCR & ITM_TCR_ITMENA_Msk) == 0)
98 return (ssize_t)nbyte;
103#error "ITM available only on ARCH 7M"
#define OS_INTEGER_TRACE_ITM_STIMULUS_PORT
Define the ITM stimulus port used for the trace messages.
ssize_t write(const void *buf, std::size_t nbyte)
Write the given number of bytes to the trace output channel.