Sample code to show how use GPIO and External Interrupts