Created simple interupt and reading bit funciton