SPRACN0F October 2021 – March 2023 F29H850TU , F29H859TU-Q1 , TMS320F280021 , TMS320F280021-Q1 , TMS320F280023 , TMS320F280023-Q1 , TMS320F280023C , TMS320F280025 , TMS320F280025-Q1 , TMS320F280025C , TMS320F280025C-Q1 , TMS320F280033 , TMS320F280034 , TMS320F280034-Q1 , TMS320F280036-Q1 , TMS320F280036C-Q1 , TMS320F280037 , TMS320F280037-Q1 , TMS320F280037C , TMS320F280037C-Q1 , TMS320F280038-Q1 , TMS320F280038C-Q1 , TMS320F280039 , TMS320F280039-Q1 , TMS320F280039C , TMS320F280039C-Q1 , TMS320F280040-Q1 , TMS320F280040C-Q1 , TMS320F280041 , TMS320F280041-Q1 , TMS320F280041C , TMS320F280041C-Q1 , TMS320F280045 , TMS320F280048-Q1 , TMS320F280048C-Q1 , TMS320F280049 , TMS320F280049-Q1 , TMS320F280049C , TMS320F280049C-Q1 , TMS320F28374D , TMS320F28374S , TMS320F28375D , TMS320F28375S , TMS320F28375S-Q1 , TMS320F28376D , TMS320F28376S , TMS320F28377S , TMS320F28377S-Q1 , TMS320F28378D , TMS320F28378S , TMS320F28379D , TMS320F28379D-Q1 , TMS320F28379S , TMS320F28384D , TMS320F28384S , TMS320F28386D , TMS320F28386S , TMS320F28388D , TMS320F28388S , TMS320F28P650DH , TMS320F28P650DK , TMS320F28P650SH , TMS320F28P650SK , TMS320F28P659DH-Q1 , TMS320F28P659DK-Q1 , TMS320F28P659SH-Q1
ERAD is a hardware module with enhanced bus comparators and system event counters that sits within the MCU bus architecture as shown in #GUID-415E5E0E-C32B-4284-B016-78A49D42D806. ERAD on its own can generate system level interrupts and flags and can also feed into other peripherals such as the CLB for further enhancing the capabilities. For complete understanding of the relationship between these two modules, see the CLB documentation.
Enhanced bus comparator monitors some of the critical CPU internal buses and signals that convey information about the CPU code execution and pipeline. Most of the critical CPU interfaces are monitored by EBC units, which can be configured to match any address/data/instruction patterns that appear on the CPU interface and generate events based on this. A simple example would be to generate an event when an address of interest is accessed for a read or write. Additionally these events can be exported to CLB to define state machines to keep track of sequences of these events.
On the other hand, system event counters monitor various events in the system like interrupts and peripheral activity which is another important requirement for any real-time system to monitor and profile. All the key system events like interrupts, DMA triggers and important peripheral events (via interrupts, CLA events, and so forth) are available for profiling inside of the ERAD. Hence, these can be time-stamped, counted and measured with relation to the CPU activity. Enhanced counter block allows the system events as well as CPU activity to be measured and analyzed with reference to other events too.
Example: Stack Overflow Detection
A frequently encountered issue with embedded code development is detecting an overflowing stack. ERAD can simply use a single enhanced bus-comparator unit and then map the stack end address with a small margin to generate an interrupt when there is a write that is attempted. With the below example (#FIG_WSG_B1H_5MB), just use a comparator with address 0x99FF0 and mask the last 4-bits for comparison, so any write access between addresses 0x99FF0 to 0x99FFF would generate an event/interrupt, which can then be handled appropriately based on kind of the application.