SPRADQ5 March 2025 AM2612 , AM2612-Q1 , AM2631 , AM2631-Q1 , AM2632 , AM2632-Q1 , AM2634 , AM2634-Q1 , AM263P2-Q1 , AM263P4 , AM263P4-Q1
The dedicated task manager is integrated for each PRU core of the PRU_ICSSG system used for efficient switching between tasks. Each task manager works independently from the others. The task manager has two modes of operation that are general purpose mode and RX_TX mode for Ethernet purpose.
In this application, general purpose mode is used to improve the firmware efficiency and performance. This feature enables software to get preempted to do another higher priority task. The task manager can issue the hardware preemption and respond to the relative instruction by saving off the current program counter and flags and providing a new program counter (PC) to start a new task. When the firmware completes this new task, the firmware can terminate this task by issuing a dedicated instruction. When the task manager sees this execution of this instruction, the task manager can return the state of the PRU from the last saved off task. This hardware context switching block diagram is shown on Figure 2-3. The firmware is responsible for saving and restoring any internal registers that the firmware can override during a task. The data RAM or shared RAM can be used to store the register value. The multi tasks can be mapped and triggered by source event such as IEP compare event, IEP capture event and interrupt controller (INTC) host event so that all the tasks timing is deterministic and pre-configured.