setup interrupt routines (not tested)