Advertisement
Guest User

Untitled

a guest
Mar 27th, 2017
45
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.38 KB | None | 0 0
  1. if(P4IN & GPIO_PIN1?0:1){
  2. if (state==1){
  3. state = 0;
  4. //Wait for this state to pass -- ends up saving the current state on button press.
  5. while (counter < 10000){
  6. counter++;
  7. }
  8. }
  9. else{
  10. state = 1;
  11. while (counter < 10000){
  12. counter++;
  13. }
  14. }
  15. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement