cancel
Showing results for 
Search instead for 
Did you mean: 

PSoC 5, 3 & 1

Anonymous
Not applicable

I am making an project where I would implement a start button.

My plan was to initialize everything and the enter a while loop waiting until the button was press with code like this:

bool START=false;

main()

{

Init all

while(!START)

{ }


Program

}

And then having a interrupt changing START=true; 

The problem is I can see the interrupt routine is called, but the program doesn't leave the while loop.
I have tried to turn on a LED in the interrupt routine and the read the output pin afterward but that doesn't work either.

I have isolated the problem to this archive, where i have placed an LED in port 1[7] to GND and uses Port 15[5] as button by pulling it low.

pressing the button should turn on the LED.

Any working solution for a button will be appriciated, but a fix or reason to the problem would be nice too

0 Likes
1 Solution
Bob_Marlowe
Expert II

I changed your program to

using your own interrupt handler

set drive mode to resistive pull up

adapted to CY8CKIT-059 using switch and blue LED

Bob

View solution in original post

1 Reply
Bob_Marlowe
Expert II

I changed your program to

using your own interrupt handler

set drive mode to resistive pull up

adapted to CY8CKIT-059 using switch and blue LED

Bob

View solution in original post