PsoC 4100 is not properly waking from Hibernate with GPIO Interupt

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

cross mob
Anonymous
Not applicable

Problem: GPIO interrupt source is not initiating a software reset, as specified, from Hibernate. What are the possible reasons? EZ-BLE 4100

   

I have configured a GPIO the same as in the Hibernate_PSoc4_Example and do not see my device entering the Reset Vector when the input is switched to ground. Prior to entering Hibernation I stop all my other interrupt ISRs, disable resources and outputs driving loads. Next I perform the following sequence:

   

            isr_SW_Enable();
            SW_ClearInterrupt();
            isr_SW_ClearPending();
            isr_SW_StartEx(&ButtonPressInt);
            CySysPmHibernate();

   

The GPIO input (SW) is set as a digital input, initialized High with a pullup. Its interrupt is set to falling edge, transparent, dedicated and buffered. The isr_SW is configured to DERIVED.

   

In the debugger the code waits at (seen when I pause the debugger):

   

CyExitCriticalSection(interruptState); in void CySysPmHibernate(void) of cyPm.c

   

Resuming in the debugger and commutating SW to ground the code vectors to the ButtonPressInt instead of resetting to the top of main() as expected.

   

In standalone mode, the system just hangs. Any cause for not resetting that I'm overlooking?

   

Rick

0 Likes
3 Replies
lock attach
Attachments are accessible only for community members.
Anonymous
Not applicable

Can you test the attached project? This shows demonstration of wake-up from hibernate when a falling edge is given to P1.4 in the 022001 Module.

0 Likes
Anonymous
Not applicable

Unfortunately, this project did not compile:

   

Clean Temporary Files ...
The compile step is up to date, no work needs to be done.
arm-none-eabi-ar.exe -rs .\CortexM0\ARM_GCC_493\Debug\Test_Hibernate_Wake-Up.a
arm-none-eabi-ar.exe: creating .\CortexM0\ARM_GCC_493\Debug\Test_Hibernate_Wake-Up.a
arm-none-eabi-gcc.exe -Wl,--start-group -o .\CortexM0\ARM_GCC_493\Debug\Test_Hibernate_Wake-Up.elf .\CortexM0\ARM_GCC_493\Debug\Test_Hibernate_Wake-Up.a "C:\Program Files (x86)\Cypress\PSoC Creator\3.3\PSoC Creator\psoc\content\cycomponentlibrary\CyComponentLibrary.cylib\CortexM0\ARM_GCC_493\Debug\CyComponentLibrary.a" -mcpu=cortex-m0 -mthumb -g -ffunction-sections -O0 -ffat-lto-objects -L Generated_Source\PSoC4 -Wl,-Map,.\CortexM0\ARM_GCC_493\Debug/Test_Hibernate_Wake-Up.map -T Generated_Source\PSoC4\cm0gcc.ld -specs=nano.specs -Wl,--gc-sections -Wl,--end-group
Generated_Source\PSoC4\cm0gcc.ld:90: undefined symbol `RomVectors' referenced in expression
collect2.exe: error: ld returned 1 exit status
The command 'arm-none-eabi-gcc.exe' failed with exit code '1'.
--------------- Build Failed: 12/08/2016 09:45:42 ---------------

   

Rick

0 Likes
Anonymous
Not applicable

The project was created using PSoC Creator 4.0. Can you please update to the latest Creator (4.0)?

   

http://www.cypress.com/products/psoc-creator-integrated-design-environment-ide

0 Likes