Configure ITM for passthrough of DWT messages and user-defined output through stimulus ports.
More...
|
enum | ITMGlobalTimestampFrequency { ITMGlobalTimestampFrequencyDisabled = 0
, ITMGlobalTimestampFrequencyPosition7 = 1
, ITMGlobalTimestampFrequencyPosition13 = 2
, ITMGlobalTimestampFrequencyIfOutputFIFOEmpty = 3
} |
| Global timestamp frequency. More...
|
|
enum | ITMLocalTimestampPrescaler { ITMLocalTimestampPrescalerNoPrescaling = 0
, ITMLocalTimestampPrescalerDivideBy4 = 1
, ITMLocalTimestampPrescalerDivideBy10 = 2
, ITMLocalTimestampPrescalerDivideBy64 = 3
} |
| Local timestamp frequency. More...
|
|
Configure ITM for passthrough of DWT messages and user-defined output through stimulus ports.
Instrumentation Trace Macrocell provides following capabilites:
Reference: ARMv7-M Architecture Reference Manual, chapter C1.7 The Instrumentation Trace Macrocell
◆ ITM_ENABLE_STIMULUS_PORTS_ALL
#define ITM_ENABLE_STIMULUS_PORTS_ALL 0xFFFFFFFF |
◆ ITMGlobalTimestampFrequency
◆ ITMLocalTimestampPrescaler
◆ ITMSetup()
Configures ITM as requested.
Note that there is no validation if specified configuration is valid (e.g. timestamp prescaler values) and there are no checks to verify MCU capabilities (enabling timestamp when it is not implemented).
- Parameters
-
◆ ITMIsPortEnabled()
bool ITMIsPortEnabled |
( |
uint8_t |
port | ) |
|
|
inlinestatic |
Checks if stimulus port is enabled.
- Parameters
-
- Returns
- true Port is enabled
-
false Port is disabled (or not available)
◆ ITMWrite8()
void ITMWrite8 |
( |
uint8_t |
port, |
|
|
uint8_t |
c |
|
) |
| |
|
inlinestatic |
Writes 8-bit value to stimulus port.
- Parameters
-
port | Port |
c | Value to be written |
◆ ITMWrite16()
void ITMWrite16 |
( |
uint8_t |
port, |
|
|
uint16_t |
value |
|
) |
| |
|
inlinestatic |
Writes 16-bit value to stimulus port.
- Parameters
-
port | Port |
value | Value to be written |
◆ ITMWrite32()
void ITMWrite32 |
( |
uint8_t |
port, |
|
|
uint32_t |
value |
|
) |
| |
|
inlinestatic |
Writes 32-bit value to stimulus port.
- Parameters
-
port | Port |
value | Value to be written |
◆ ITMWriteBuffer()
void ITMWriteBuffer |
( |
uint8_t |
port, |
|
|
const void * |
buffer, |
|
|
size_t |
size |
|
) |
| |
|
inlinestatic |
Writes buffer to stimulus port.
Writes buffer to stimulus port using largest packet size possible - starts with 32-bit writes, followed by 16-bit writes and 8-bit write.
Data from buffer are memcpy'ied which is subject to compiler optimization and might result in unaligned memory access if compiler decides it is valid (e.g. on ARMv7-M platform).
- Parameters
-
port | Port |
buffer | Buffer to be written (must not be NULL) |
size | Size of buffer to be written |