SPRUJ79 November 2024 F29H850TU , F29H859TU-Q1
This section details the software initialization sequence when configuring CPU1 or CPU2 as ESC owner. The CPU2 sequence includes details on allocating ownership of the ESC peripheral.
| Step | Action |
|---|---|
| 1 | General device initialization (configure clock, enable PLL, enable peripheral clocks except EtherCAT) |
| 2 | Configure Aux Clock for EtherCAT (if using Aux clock as source) |
| 3 | Configure GPIOs for EtherCAT (set pin configurations, set GPIO qualification mode, set pad configuration) |
| 4 | Initialize interrupts and register ISR handlers |
| 5 | Set EtherCAT clock source and divider. Then configure if EtherCAT PHY is clocked from device or external PHY clock. |
| 6 | Configure the EEPROM size |
| 7 | Bring ESC out of reset using system control register |
| 8 | Perform EtherCAT memory initialization and wait until memory initialization is complete |
| 9 | (Optional) Enable debug access to the EtherCAT registers |
| 10 | (Optional) Check that EEPROM loaded successfully |
| 11 | EtherCAT subsystem configurations for interrupt masking, SYNCx connections, and so on(1) |
| Step | Core | Action |
|---|---|---|
| 1 | CPU1 | General device initialization (configure clock, enable PLL, enable peripheral clocks except EtherCAT) |
| 2 | CPU1 | Assign RAMs and Flash Banks to CPU2/CPU3 |
| 3 | CPU1 | Bring CPU2 out of reset using system control register |
| 4 | CPU1 | Configure GPIOs for EtherCAT (set pin configurations, set GPIO qualification mode, set pad configuration) |
| 5 | CPU1 | Configure Aux Clock for EtherCAT (if using Aux clock as source) |
| 6 | CPU1 | Set EtherCAT source and clock divider. Then configure if EtherCAT PHY is clocked from device or external PHY clock |
| 7 | CPU1 | Reset ESC using system control register |
| 8 | CPU1 | Bring ESC out of reset using system control register |
| 9 | CPU1 | Configure EtherCAT EEPROM Size |
| 10 | CPU1 | Reset ESC using system control register |
| 11 | CPU1 | Allocate ESC to CPU2/CPU3 |
| 12 | CPU2/CPU3 | Initialize Interrupts and Register ISR Handlers |
| 13 | CPU2/CPU3 | Perform EtherCAT memory initialization and wait until memory initialization is complete |
| 14 | CPU2/CPU3 | (Optional) Enable debug access to the EtherCAT registers |
| 15 | CPU2/CPU3 | (Optional) Check that EEPROM Loaded successfully |
| 16 | CPU2/CPU3 | EtherCAT subsytem configurations for interrupt masking, SYNCx connections and so on(1) |