Ext_Sleep Power Consuption

⚠️
Hi there.. thanks for coming to the forums. Exciting news! we’re now in the process of moving to our new forum platform that will offer better functionality and is contained within the main Dialog website. All posts and accounts have been migrated. We’re now accepting traffic on the new forum only - please POST any new threads at//www.wsdof.com/support. We’ll be fixing bugs / optimising the searching and tagging over the coming days.
4 posts / 0 new
Last post
prasanth.velliy...
Offline
Last seen:1 year 11 months ago
加入:2016-02-18 12:18
Ext_Sleep Power Consuption

Hi Dialog
I am using DSPS slave project and implemented extended Sleep , it is working properly.
But the power consumption is not proper , i am Flashing the code in SPI Flash and checking the consumption
1 . IOT BOARD DA14583 - IOT software - Comsumption in Sleep 80ua
2。物联网董事会DA14583——需求方奴隶软件——消费意识mption 180ua in sleep
3. Murata DA14580 - P2ML3256 - DSPS Slave software- Consumption 160ua in sleep
4. Custom Board - DA14583 - DSPS Dlave software Consumption 220ua in sleep
5. IOT Board - Da14583 SDK 5.0.4 Proximity Reporter Consumption 180ua in sleep

All i checked via Multimeter (connect is CR2032 battery one end to Multimeter , multimeter other end to Board ,settings: ua ,current mode), why i am not seeing below 5ua in any of the boards , But earlier using UART booter mode i achieved 2ua consumption , What could be the issue ??

Device:
MT_dialog
Offline
Last seen:2 months 3 weeks ago
Staff
加入:2015-06-08 11:34
Hi prasanth,

Hi prasanth,

The 2uA power consuption is achieved when the device is in sleep mode with no activity at all, the IoT at some point goes in sleep mode if there is no movement for quite amount of time but it also has additional sensors consuming power so you wont be able to see this kind of low power. The DSPS example it doesn't fall in permanent sleep but keeps on waking up and goes to sleep depending on its advertising and connection interval, so again there is no way to see 2uA power consumption. Also, since you are using a flash on your board be aware that the flash is also consuming power, and quite a significant amount if its not power down (via the power down command of the flash- spi_flash_power_down()). So if you were seeing differences between UART and SPI booting the latter that is the most probable cause.

Thanks MT_dialog

prasanth.velliy...
Offline
Last seen:1 year 11 months ago
加入:2016-02-18 12:18
Hi Dialog

Hi Dialog

Thank you for your reply

I added spi_flash_power_down()
/*******************************************************************************************************************/
==>>>>>>>>>> in @file user_periph_setup.c

#ifdef DA14580_CUSTOM_BOARD

GPIO_ConfigurePin( SPI_GPIO_PORT, SPI_CS_PIN, OUTPUT, PID_SPI_EN, true );
GPIO_ConfigurePin( SPI_GPIO_PORT, SPI_CLK_PIN, OUTPUT, PID_SPI_CLK, false );
GPIO_ConfigurePin( SPI_GPIO_PORT, SPI_DO_PIN, OUTPUT, PID_SPI_DO, false );
GPIO_ConfigurePin( SPI_GPIO_PORT, SPI_DI_PIN, INPUT, PID_SPI_DI, false );
#endif

#ifdef DA14583_CUSTOM_BOARD

GPIO_ConfigurePin (DA14583_SPI_FLASH_EN_GPIO_PORT, DA14583_SPI_FLASH_EN_GPIO_PIN, OUTPUT, PID_SPI_EN, true );
GPIO_ConfigurePin (DA14583_SPI_FLASH_CLK_GPIO_PORT, DA14583_SPI_FLASH_CLK_GPIO_PIN, OUTPUT, PID_SPI_CLK, false );
GPIO_ConfigurePin (DA14583_SPI_FLASH_DO_GPIO_PORT, DA14583_SPI_FLASH_DO_GPIO_PIN, OUTPUT, PID_SPI_DO, false );
GPIO_ConfigurePin (DA14583_SPI_FLASH_DI_GPIO_PORT, DA14583_SPI_FLASH_DI_GPIO_PIN, INPUT, PID_SPI_DI, false );

#endif

=>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> @file user_sps_device.c
void user_on_init(void)
{
user_scheduler_init();
default_app_on_init();
da14580_spi_flash_init();
da14580_spi_flash_deinit();
}
=>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
void da14580_spi_flash_init(void)
{
#ifdef DA14583_CUSTOM_BOARD

//Unregister old pin map of sensor spi network
GPIO_ConfigurePin (DA14583_SPI_FLASH_EN_GPIO_PORT, DA14583_SPI_FLASH_DO_GPIO_PIN, INPUT_PULLUP, PID_GPIO, true);
GPIO_ConfigurePin (DA14583_SPI_FLASH_DI_GPIO_PORT, DA14583_SPI_FLASH_DI_GPIO_PIN, INPUT_PULLUP, PID_GPIO, true);
GPIO_ConfigurePin (DA14583_SPI_FLASH_CLK_GPIO_PORT, DA14583_SPI_FLASH_CLK_GPIO_PIN , INPUT_PULLUP, PID_GPIO, true);
GPIO_ConfigurePin (DA14583_SPI_FLASH_EN_GPIO_PORT, DA14583_SPI_FLASH_EN_GPIO_PIN, OUTPUT, PID_SPI_CLK, false );

int8_t man_dev_id = 0;

spi_driver_cs_pad.port = GPIO_PORT_2;
spi_driver_cs_pad.pin = GPIO_PIN_3;

man_dev_id = spi_flash_enable(spi_driver_cs_pad.port, spi_driver_cs_pad.pin);

if (man_dev_id == SPI_FLASH_AUTO_DETECT_NOT_DETECTED)
{
spi_flash_init(DA14583_SPI_FLASH_SIZE, DA14583_SPI_FLASH_PAGE_SIZE);
}

// Power up flash
//spi_flash_release_from_power_down();

#endif

#ifdef DA14580_CUSTOM_BOARD

SPI_Pad_t cs_pad_param;
int8_t man_dev_id = 0;

cs_pad_param.port = SPI_EN_GPIO_PORT;
cs_pad_param.pin = SPI_EN_GPIO_PIN;

man_dev_id = spi_flash_enable(cs_pad_param.port, cs_pad_param.pin);

if (man_dev_id == SPI_FLASH_AUTO_DETECT_NOT_DETECTED)
{
//spi_init(&cs_pad_param, SPI_MODE_8BIT, SPI_ROLE_MASTER, SPI_CLK_IDLE_POL_LOW, SPI_PHA_MODE_0, SPI_MINT_DISABLE, SPI_XTAL_DIV_8);
spi_flash_init(SPI_FLASH_DEFAULT_SIZE, SPI_FLASH_DEFAULT_PAGE);
}
spi_flash_release_from_power_down();

#endif

}

void clr_flash_cs( void )
{
#ifdef DA14583_CUSTOM_BOARD

GPIO_SetInactive(DA14583_SPI_FLASH_EN_GPIO_PORT, DA14583_SPI_FLASH_EN_GPIO_PIN);

#endif
#ifdef DA14580_CUSTOM_BOARD

GPIO_SetInactive(SPI_EN_GPIO_PORT, SPI_EN_GPIO_PIN);

#endif

}

void set_flash_cs( void )
{
#ifdef DA14583_CUSTOM_BOARD

GPIO_SetActive(DA14583_SPI_FLASH_EN_GPIO_PORT, DA14583_SPI_FLASH_EN_GPIO_PIN);

#endif
#ifdef DA14580_CUSTOM_BOARD

GPIO_SetActive(SPI_EN_GPIO_PORT, SPI_EN_GPIO_PIN);

#endif
}

void da14580_spi_flash_deinit( void ) {

#ifdef DA14583_CUSTOM_BOARD
set_flash_cs();
spi_flash_power_down();
clr_flash_cs();

#endif

#ifdef DA14580_CUSTOM_BOARD

set_flash_cs();
spi_flash_power_down();
clr_flash_cs();

#endif

}

i have added this setup for DA14583 based board , i am not seeing any improvement , Please help..

Thank you

MT_dialog
Offline
Last seen:2 months 3 weeks ago
Staff
加入:2015-06-08 11:34
Hi prasanth,

Hi prasanth,

If you remove the flash or if you dont use the flash at all, do you see any improvements to the power consumption ? Also i 've mentioned above depends on the BLE activity that the device has, for example, what is the power consumption when the device goes in sleep (no sleep and wake up, the power consumption when the device is constantly in sleep mode). You will have to check exactly what is that draws that amount of power, is an external module ? is that the 580 doesn't go to sleep ? Is that you ve extra BLE activity that causes that ?

Thanks MT_dialog