The FPU can be enabled and disabled by calling the appropriate HAL functions. It may save a tiny bit of power to disable it, but I'm guessing that it is hardly worth the trouble. In any case, here are the HAL calls:
Code: Select all//*****************************************************************************
//
//! @brief Enable the floating point module.
//!
//! Call this function to enable the ARM hardware floating point module.
//!
//! @return None.
//
//*****************************************************************************
void
am_hal_sysctrl_fpu_enable(void)
{
//
// Enable access to the FPU in both privileged and user modes.
// NOTE: Write 0s to all reserved fields in this register.
//
SCB->CPACR = _VAL2FLD(SCB_CPACR_CP11, 0x3) |
_VAL2FLD(SCB_CPACR_CP10, 0x3);
}
//*****************************************************************************
//
//! @brief Disable the floating point module.
//!
//! Call this function to disable the ARM hardware floating point module.
//!
//! @return None.
//
//*****************************************************************************
void
am_hal_sysctrl_fpu_disable(void)
{
//
// Disable access to the FPU in both privileged and user modes.
// NOTE: Write 0s to all reserved fields in this register.
//
SCB->CPACR = 0x00000000 &
~(_VAL2FLD(SCB_CPACR_CP11, 0x3) |
_VAL2FLD(SCB_CPACR_CP10, 0x3));
}