complete refactor to directly pass reports and interfaces
This commit is contained in:
@@ -0,0 +1,24 @@
|
||||
#include "pico/stdlib.h"
|
||||
#include "pico/multicore.h"
|
||||
#include "pico/bootrom.h"
|
||||
#include "hardware/clocks.h"
|
||||
|
||||
#include "usb_device.h"
|
||||
#include "usb_host.h"
|
||||
|
||||
// main loop
|
||||
int main(void) {
|
||||
// default 125MHz is not appropreate. Sysclock should be multiple of 12MHz.
|
||||
set_sys_clock_khz(144000, true);
|
||||
|
||||
sleep_ms(10);
|
||||
|
||||
// run usb host on core 1
|
||||
multicore_reset_core1();
|
||||
multicore_launch_core1(usb_host_main);
|
||||
|
||||
// run usb device on core 0
|
||||
usb_device_main();
|
||||
|
||||
return 0;
|
||||
}
|
||||
Reference in New Issue
Block a user