changed names
updated for arduino, slightly dodgey interrupt code