/** * @brief Main program entry point * @return Nothing * @note This routine configures the hardware required by the application, * then enters a loop to run the application tasks in sequence. */ int main(void) { SetupHardware(); DEBUGOUT("Keyboard Host Demo running.\r\n"); for (;; ) { KeyboardHost_Task(); HID_Host_USBTask(&Keyboard_HID_Interface); USB_USBTask(Keyboard_HID_Interface.Config.PortNumber, USB_MODE_Host); } }
/** Main program entry point. This routine configures the hardware required by the application, then * enters a loop to run the application tasks in sequence. */ char keyboard(void) { char tecla; SetupHardwareKeyboard(); do { tecla = KeyboardHost_Task(); HID_Host_USBTask(&Keyboard_Host_HID_Interface); USB_USBTask(); } while (tecla != 'D'); return tecla; }
/** Main program entry point. This routine configures the hardware required by the application, then * enters a loop to run the application tasks in sequence. */ int main(void) { SetupHardware(); puts_P(PSTR(ESC_FG_CYAN "Keyboard HID Host Demo running.\r\n" ESC_FG_WHITE)); LEDs_SetAllLEDs(LEDMASK_USB_NOTREADY); GlobalInterruptEnable(); for (;;) { KeyboardHost_Task(); USB_USBTask(); } }
/** Main program entry point. This routine configures the hardware required by the application, then * enters a loop to run the application tasks in sequence. */ int main(void) { SetupHardware(); puts_P(PSTR(ESC_FG_CYAN "Keyboard Host Demo running.\r\n" ESC_FG_WHITE)); LEDs_SetAllLEDs(LEDMASK_USB_NOTREADY); sei(); for (;;) { KeyboardHost_Task(); HID_Host_USBTask(&Keyboard_HID_Interface); USB_USBTask(); } }