cancel
Showing results for 
Search instead for 
Did you mean: 

PSoC 4 MCU

RuHe_1008296
New Contributor II

Hey All

I have a problem with a project I am working on. I currently use a CYBLE-214009 it samples some data from a IMU via I2C, and transmit it via BLE. This works well if the system does not enter low power modes. BUT...

If i enter deepsleep, when the BLE or the I2C does not have any more work to do, and a GPIO interrupt from the IMU (10 Hz) is waking the processor the BLE gets stuck. When I look at the stack trace it is just haled here:

     0 CySysPmSleep() Generated_Source\PSoC4\cyPm.c 44 0x00001CCE (All)

     1 ll_wait_to_exit_dsm() ?????? ?????? 0x00014810 (All)

     2 ll_exit_low_power_mode() ?????? ?????? 0x00014090 (All)

     3 ll_task_handler() ?????? ?????? 0x00017B64 (All)

     4 llft_service_queue() ?????? ?????? 0x000185C6 (All)

     5 llf_task_start_routine() ?????? ?????? 0x0001851E (All)

0 Likes
1 Solution
Anonymous
Not applicable

According to the documentation in the PSoC Creator:

*    <td>CYBLE_BLESS_STATE_ECO_ON</td>

*    <td>BLE Sub System is in process of wakeup from Deep Sleep Mode and ECO(XTAL) is turned on.

*        CPU can be put in Deep Sleep Mode.</td>

Thus, I would remove the || blePower == CYBLE_BLESS_STATE_ECO_ON part of the check code, as you would be saying the unit is in deepsleep when it is just waking up from deepsleep and is awake now.

View solution in original post

0 Likes
3 Replies
Anonymous
Not applicable

Did you correctly put the BLE stack into low power before putting the CPU into low power mode?

Also, clock sources being turned off might be a cause too?

0 Likes
RuHe_1008296
New Contributor II

The system is set up with the IMO at 48MHz. So the ECO should only be used for the BLE.

If my application are ready to go to sleep, i am checking the BLE Module the following way:

blePower = CyBle_GetBleSsState();

if(ble_lpmode == CYBLE_BLESS_DEEPSLEEP &&

    (blePower == CYBLE_BLESS_STATE_DEEPSLEEP || blePower == CYBLE_BLESS_STATE_ECO_ON))

        return deepSleep;

  if(blePower != CYBLE_BLESS_STATE_EVENT_CLOSE)

        return sleep;

  return awake;

(where ble_lpmode is the response from the last time the CyBle_EnterLPM(CYBLE_BLESS_DEEPSLEEP) function was called).

0 Likes
Anonymous
Not applicable

According to the documentation in the PSoC Creator:

*    <td>CYBLE_BLESS_STATE_ECO_ON</td>

*    <td>BLE Sub System is in process of wakeup from Deep Sleep Mode and ECO(XTAL) is turned on.

*        CPU can be put in Deep Sleep Mode.</td>

Thus, I would remove the || blePower == CYBLE_BLESS_STATE_ECO_ON part of the check code, as you would be saying the unit is in deepsleep when it is just waking up from deepsleep and is awake now.

View solution in original post

0 Likes