How to measure power consumption for Nucleo-144 board?
I am trying to measure the power consumption for Nucleo-144 board.
Here is my config
- External power supply 8V
- JP6 to VIN
- Connect Fluke multimeter to power supply
- Connect multimeter to CN8 pin 15
- Connect ST-Link
- Call HAL_PWR_EnterSTANDBYMode() or LL_PWR_SetPowerMode(LL_PWR_MODE_SHUTDOWN) force system going standby/shutdown mode.
Is the config correct? I am trying to disable most of the buses before standby. The system doesn't seems go to standby mode since after the call, I am still able to run from IDE.
Is there anything I am missing here?
Thx
HAL_ADCEx_DisableVoltageRegulator(&hadc1);
// HAL_CAN_RequestSleep(&hcan1);
HAL_CAN_Stop(&hcan1);
LL_SPI_Disable(hspi1.Instance);
LL_SPI_Disable(hspi2.Instance);
LL_USART_Disable(huart1.Instance);
LL_USART_Disable(huart2.Instance);
LL_USART_Disable(huart4.Instance);
__HAL_RCC_SPI1_CLK_DISABLE();
__HAL_RCC_SPI2_CLK_DISABLE();
__HAL_RCC_CAN1_CLK_DISABLE();
__HAL_RCC_USART1_CLK_DISABLE();
__HAL_RCC_USART2_CLK_DISABLE();
__HAL_RCC_UART4_CLK_DISABLE();
__HAL_RCC_I2C1_CLK_DISABLE();
__HAL_RCC_I2C2_CLK_DISABLE();
__HAL_RCC_RTCAPB_CLK_DISABLE();
// Disable all used wakeup sources: WKUP pin
HAL_PWR_DisableWakeUpPin(PWR_WAKEUP_PIN2);
HAL_PWR_DisableWakeUpPin(PWR_WAKEUP_PIN3);
// Clear all related wakeup flags
/* Clear PWR wake up Flag */
__HAL_PWR_CLEAR_FLAG(PWR_FLAG_WU);
__GPIOA_CLK_DISABLE();
__GPIOB_CLK_DISABLE();
__GPIOC_CLK_DISABLE();
__GPIOD_CLK_DISABLE();
__GPIOE_CLK_DISABLE();
__PWR_CLK_DISABLE();
SysTick->CTRL=0x00;
// HAL_PWR_EnableWakeUpPin(PWR_WAKEUP_PIN2);
// HAL_PWR_EnableWakeUpPin(PWR_WAKEUP_PIN3);
__HAL_PWR_CLEAR_FLAG(PWR_FLAG_WU);
HAL_PWR_EnterSTANDBYMode();
