static void mfp_init(void) { mfp_set_vr(MFP_INTR); /* stop all interrupts */ mfp_set_iera(0); mfp_set_ierb(0); /* make MSCTRL 'High', XXX where should I do it? */ mfp_send_usart(0x41); /* Timer A settings */ mfp_set_tacr(MFP_TIMERA_RESET | MFP_TIMERA_STOP); /* Timer B settings: used for USART clock */ mfp_set_tbcr(MFP_TIMERB_RESET | MFP_TIMERB_STOP); /* Timer C/D settings */ mfp_set_tcdcr(0); }
void kbd_setLED(void) { mfp_send_usart(~kbdled | 0x80); }