SPRUI33H November 2015 – June 2024 TMS320F280040-Q1 , TMS320F280040C-Q1 , TMS320F280041 , TMS320F280041-Q1 , TMS320F280041C , TMS320F280041C-Q1 , TMS320F280045 , TMS320F280048-Q1 , TMS320F280048C-Q1 , TMS320F280049 , TMS320F280049-Q1 , TMS320F280049C , TMS320F280049C-Q1
The Flash module on this device can be powered down at any time during an application. There are some considerations that must be made when powering down the Flash.
When the application software powers down the Flash, the application must make sure that the function that puts the Flash to sleep is executed from RAM. Note that there can not be any access to Flash after the Flash is put to sleep to realize the power savings. If there is an access to Flash, the Flash wakeup process (wakeup time depends on PSLEEP and RWAIT as mentioned in Section 3.12.6.1) gets initialized and the application does not realize Flash power savings. For example, if the application has to execute any code after putting the Flash to sleep and before putting the device in to low-power mode, the application must execute that code from RAM and not from Flash.
As mentioned in Section 3.12.6.1, PSLEEP and RWAIT can be optimized to reduce the Flash wakeup time for a given SYSCLK frequency. BootROM configures the best possible PSLEEP value for the 100MHz operation. However, the application software can decrease the PSLEEP value to reduce the Flash wakeup time if the application SYSCLK is less than 100MHz. This is applicable in the context of an application entering the Halt mode since PLL must be disabled before entering the Halt mode. In this case, the PSLEEP value can be decreased to get a faster Flash wakeup upon exit from LPM.
If the Wake ISR is in Flash, optimize the PSLEEP and RWAIT values before entering the LPM, and after the Flash is in sleep, since the application does not get a chance to modify these before Flash is awake after exiting from LPM. However, after the LPM exit and once the Flash is awake, the application must branch to RAM to restore RWAIT and PSLEEP (as per the application SYSCLK to which PLL is locked for) and then proceed with Flash execution to lock the PLL.
If the Wake ISR is in RAM, application can optimize the PSLEEP and RWAIT values in the Wake ISR and then do a dummy Flash access to initiate the Flash wakeup process. While the Flash is waking up, application can initialize the PLL lock process. Once the Flash is awake, application can put the PLL in clock path. If the user does not want to lock the PLL from RAM, PLL can be locked from Flash (this means Flash wakeup and PLL lock are not done in parallel), but in any case make sure to restore the RWAIT and PSLEEP (as per the application SYSCLK to which PLL is locked for) in Wake ISR before proceeding to Flash execution.
The Flash fallback mode is not automatically configured as active mode upon Flash wakeup in F28004x and instead the device stays as configured before entering the Flash low-power mode. Hence, the BootROM code and the Flash initialization routine in C2000Ware configure the Flash fallback mode to active mode to avoid Flash falling back to low-power mode after the grace period expiration. Similarly, in the context of the device LPM, the application software must change the Flash Fallback mode to the Active state in the Wake ISR if required. If not, Flash enters the configured fallback power mode when the grace period expires as mentioned in Section 3.12.6.1. This applies to all low-power modes on this device.