Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

PSoC™ 4 Forum Discussions

GaryLim
Employee
10 questions asked First like received 10 replies posted
Employee

Hi, 

As I am not able to post on the previous posting,  please refer to the following link for the project source code

https://community.infineon.com/t5/PSoC-4/PSoC4-Power-Mode/m-p/362805#M43041

Since I have only 1 PSoC4 CY8CKIT-149 board and unable to order more, I would like to know when executing the sleep and deep sleep mode using the attached project, what is the current value measured across J3 at your side. 

Please help to provide your measured result.

Thanks.

0 Likes
1 Solution
GaryLim
Employee
10 questions asked First like received 10 replies posted
Employee

Hi Rakesh,

Small contribution from my findings to the Community. Below are my steps of achieving the deep sleep power mode on PSoC4 CY8KIT-149 as stated in the AN86233 application notes. You can help to verify if they are correct.

1. The Project needs to disable the Debug resource under the System tab. The Pin tab with CYBSP_SWDIO and CYBSP_SWDCK should be set to unassigned and drive mode set to Analog High-Z. This will disable the on-chip debugging and ensure that debugging pins are not active even if connected to the debugger.

2. The Project is then built in Release mode instead of Debug mode. Modify the project Makefile to set the CONFIG=Release. 

3. Build the project and checks that Release build folder is generated.

4. Flash the Release image using a flash programmer such as Cypress Programmer. The reason for using the flash programmer is because the MTB by default gets the image from the Debug folder using the launches options. 

5. Check the current consumption using the Ammeter connected over J3 with R53 removed on the CY8KIT-149 EVK board. In active mode, it draws 4.52mA. Briefly click on SW1 to trigger Sleep mode, it draws about 1.92mA. Holding down SW1 for more than 2 seconds on the SW1 will cause the PSoC4 to enter deep sleep mode which draws about 2 uA of current.

 

Feedbacks:

1. Remove the distraction of PWM and LED flashing code from the sample codes so that user can focus on the MCU power modes.

2. Highlight in the README.md that within debug mode, current measurement will be skewed. This is due to the debug agent and on-chip debugging capability. Recommend user to switch to Release mode for proper evaluation.

3. Add the ability to flash release build code directly from MTB rather than using external programmer.

 

Regards,

Gary

 

View solution in original post

6 Replies
Rakesh_Patrudu
Moderator
Moderator 25 replies posted 10 solutions authored First like given
Moderator

Hi @GaryLim ,

I have recreated the project from the attached attachment in accordance with your earlier thread and measured the current values across J3. The readings are like 3.17 mA in the Sleep Mode, 5.78 mA in the Active Mode and 1.38 mA in the Deep Sleep Mode.

Best Regards,
Rakesh

0 Likes
GaryLim
Employee
10 questions asked First like received 10 replies posted
Employee

Hi Rakesh,

Many thanks for capturing the readings. Is it possible for you to upload your project so that I can cross-check the software on my system?

Thanks.

0 Likes
Rakesh_Patrudu
Moderator
Moderator 25 replies posted 10 solutions authored First like given
Moderator

Hi @GaryLim ,

I have used the same project that you have mentioned in the previous thread and please find the attachment of the project here.

Best Regards,
Rakesh

GaryLim
Employee
10 questions asked First like received 10 replies posted
Employee

Hi Rakesh,

The PSoC4 MCU low-power modes AN86233 application note power mode specs, shows that power consumption range for Deep Sleep mode is within 1.3 to 15uA range. What's the reason for your PSoC4 reading to be be 1.38mA which is about 92x to 1061x higher? Thanks!

GaryLim_0-1664426822934.png

0 Likes
GaryLim
Employee
10 questions asked First like received 10 replies posted
Employee

Hi Rakesh,

Small contribution from my findings to the Community. Below are my steps of achieving the deep sleep power mode on PSoC4 CY8KIT-149 as stated in the AN86233 application notes. You can help to verify if they are correct.

1. The Project needs to disable the Debug resource under the System tab. The Pin tab with CYBSP_SWDIO and CYBSP_SWDCK should be set to unassigned and drive mode set to Analog High-Z. This will disable the on-chip debugging and ensure that debugging pins are not active even if connected to the debugger.

2. The Project is then built in Release mode instead of Debug mode. Modify the project Makefile to set the CONFIG=Release. 

3. Build the project and checks that Release build folder is generated.

4. Flash the Release image using a flash programmer such as Cypress Programmer. The reason for using the flash programmer is because the MTB by default gets the image from the Debug folder using the launches options. 

5. Check the current consumption using the Ammeter connected over J3 with R53 removed on the CY8KIT-149 EVK board. In active mode, it draws 4.52mA. Briefly click on SW1 to trigger Sleep mode, it draws about 1.92mA. Holding down SW1 for more than 2 seconds on the SW1 will cause the PSoC4 to enter deep sleep mode which draws about 2 uA of current.

 

Feedbacks:

1. Remove the distraction of PWM and LED flashing code from the sample codes so that user can focus on the MCU power modes.

2. Highlight in the README.md that within debug mode, current measurement will be skewed. This is due to the debug agent and on-chip debugging capability. Recommend user to switch to Release mode for proper evaluation.

3. Add the ability to flash release build code directly from MTB rather than using external programmer.

 

Regards,

Gary

 

GaryLim
Employee
10 questions asked First like received 10 replies posted
Employee

I have realized that the launch configurations has to be regenerated for the Release config so that the Release image can be flashed by MTB without using external flash programmer.

0 Likes