This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Deep Sleep mode for CC2650STK

Hi TI Experts,

We are using following code to create duty cycle in which it advertises Temperature data. In the following code, we are using CPUDelay(200e6) for delay which creates duty cycle but its is consuming lot of power. Power snapshot also attached. We tried using Task_sleep((UInt) 20000), but the task does not block or stop for the time specified, instead it sends data continuously without waiting for 20 seconds in Task_sleep(). 

We want to make power consumption very less in this wait time. How should we implement delay so that current consumption will be least in wait time (delay) (0.05 to 0.1mA)

			/*Following code running continuously*/

				Data_t data;

				// Read data
				SensorTmp007_enable(true);
				DELAY_MS(TEMP_MEAS_DELAY);
				SensorTmp007_read(&data.v.tempLocal, &data.v.tempTarget);
				SensorTmp007_enable(false);

				System_printf("Temperature Reported\n");

				// Update GATT
				IRTemp_setParameter(SENSOR_DATA, SENSOR_DATA_LEN, data.a);

				CPUdelay(200e6);
				//Task_sleep((UInt)20000);

				// Next cycle
				DELAY_MS(sensorPeriod - TEMP_MEAS_DELAY);

  • I do not understand what you are trying to do. What is the purpose of this delay?

    In general, power management is handled by the stack. See section 3.7 of the SDG for more information: www.ti.com/.../swru393
  • If what you are trying to achieve is for the CPU to enter sleep between gatt database updates to reduce power consumption, you probably want to use the task sleep rather than a delay.

    // sleep the task for 1000ms (1sec) to allow CPU to enter standby
    Task_sleep(1000 * (1000 / Clock_tickPeriod));

  • So,

    My question is how should we delay execution of code so that power consumption will be least in that delay ?
    In our case it is consuming lot of power. We want delay between two recordings of temperature in that code.
    Reducing power consumption is our ultimate aim as we are going to power sensor-tag using energy harvester circuit.

    In delay, it should consume 0.1 to 0.15 mA which I think should be possible with sensor-tag.

    Please let us know what should be current consumption according to TI experts,

    Recording Temperature data--> ?

    Delay --> ?

    Please try to help us as our project has been stuck because of this. 

  • Hello again Jayesh,

    It looks like you never responded to our previous thread.

    Have you tried my latest suggestion? The quoted power specification is 10uA  average current using a 1s connection interval. This requires that the device (and all other devices on the board) are put in to the deepest sleep mode possible.

  • Hi Sean,

    I have defined POWER_SAVING in predefined symbols. So, it should take power management automatically.
    But still we are not getting 10uA average current that you are quoting and for your kind information, we are making changes in sensortag example which has Bluetooth Low energy stack installed on it.

    Just a thing that we are using default pin configuartion. Any suggestions over this ?

    const PIN_Config BoardGpioInitTable[] = {

    Board_STK_LED1 | PIN_GPIO_OUTPUT_EN | PIN_GPIO_LOW | PIN_PUSHPULL | PIN_DRVSTR_MAX, /* LED initially off */
    Board_STK_LED2 | PIN_GPIO_OUTPUT_EN | PIN_GPIO_LOW | PIN_PUSHPULL | PIN_DRVSTR_MAX, /* LED initially off */
    Board_KEY_LEFT | PIN_INPUT_EN | PIN_PULLUP | PIN_IRQ_BOTHEDGES | PIN_HYSTERESIS, /* Button is active low */
    Board_KEY_RIGHT | PIN_INPUT_EN | PIN_PULLUP | PIN_IRQ_BOTHEDGES | PIN_HYSTERESIS, /* Button is active low */
    Board_RELAY | PIN_INPUT_EN | PIN_PULLDOWN | PIN_IRQ_BOTHEDGES | PIN_HYSTERESIS, /* Relay is active high */
    Board_MPU_INT | PIN_INPUT_EN | PIN_PULLDOWN | PIN_IRQ_NEGEDGE | PIN_HYSTERESIS, /* MPU_INT is active low */
    Board_TMP_RDY | PIN_INPUT_EN | PIN_PULLUP | PIN_HYSTERESIS, /* TMP_RDY is active high */
    Board_BUZZER | PIN_GPIO_OUTPUT_EN | PIN_GPIO_LOW | PIN_PUSHPULL | PIN_DRVSTR_MAX, /* Buzzer initially off */
    Board_MPU_POWER | PIN_GPIO_OUTPUT_EN | PIN_GPIO_HIGH | PIN_PUSHPULL | PIN_DRVSTR_MAX, /* MPU initially on */
    Board_MIC_POWER | PIN_GPIO_OUTPUT_EN | PIN_GPIO_LOW | PIN_PUSHPULL | PIN_DRVSTR_MIN, /* MIC initially off */
    Board_SPI_FLASH_CS | PIN_GPIO_OUTPUT_EN | PIN_GPIO_HIGH | PIN_PUSHPULL | PIN_DRVSTR_MIN, /* External flash chip select */
    Board_SPI_DEVPK_CS | PIN_GPIO_OUTPUT_EN | PIN_GPIO_LOW | PIN_PUSHPULL | PIN_DRVSTR_MIN, /* DevPack chip select */
    Board_AUDIO_DI | PIN_INPUT_EN | PIN_PULLDOWN, /* Audio DI */
    Board_AUDIODO | PIN_GPIO_OUTPUT_EN | PIN_GPIO_HIGH | PIN_PUSHPULL | PIN_DRVSTR_MIN, /* Audio data out */
    Board_AUDIO_CLK | PIN_INPUT_EN | PIN_PULLDOWN, /* DevPack */
    Board_DP2 | PIN_INPUT_EN | PIN_PULLDOWN, /* DevPack */
    Board_DP1 | PIN_INPUT_EN | PIN_PULLDOWN, /* DevPack */
    Board_DP0 | PIN_INPUT_EN | PIN_PULLDOWN, /* DevPack */
    Board_DP3 | PIN_INPUT_EN | PIN_PULLDOWN, /* DevPack */
    Board_UART_RX | PIN_INPUT_EN | PIN_PULLDOWN, /* DevPack */
    Board_UART_TX | PIN_GPIO_OUTPUT_EN | PIN_GPIO_HIGH | PIN_PUSHPULL, /* DevPack */
    Board_DEVPK_ID | PIN_INPUT_EN | PIN_NOPULL, /* Device pack ID - external PU */
    Board_SPI0_MOSI | PIN_INPUT_EN | PIN_PULLDOWN, /* SPI master out - slave in */
    Board_SPI0_MISO | PIN_INPUT_EN | PIN_PULLDOWN, /* SPI master in - slave out */
    Board_SPI0_CLK | PIN_INPUT_EN | PIN_PULLDOWN, /* SPI clock */

    PIN_TERMINATE
    };
  • Jayesh,

    Do you have any of the other sensor tasks running? You can disable them using SensorTag_resetAllSensors();

    Additionally, looking at the PIN table you would want to disable the MPU
    Board_MPU_POWER | PIN_GPIO_OUTPUT_EN | PIN_GPIO_HIGH | PIN_PUSHPULL | PIN_DRVSTR_MAX, /* MPU initially on */

    Going through each sensor's datasheet and ensuring the PIN table is configuring the sensor to the lowest power state is a good idea for getting the most accurate power measurements.

    Additionally the average current is only valid for a 1s connection interval, for other use cases you can find the predicted power consumption using www.ti.com/ble-power-calculator.