i need to read a content from a usb (otg) in twrk70f120m
how can i do it?i also want to display it in the tft lcd display
please help
Hello,
Which USB stack are you using? For example, in BareMetal USB stack 4.1.1, there are some examples for USB OTG functionality and basically, after initializing the USB module and configure it as OTG, you can use Device or Host APIs to send/receive data by calling (depending on current mode):
(Sending data to Host)
USB_Class_HID_Send_Data(CONTROLLER_ID,HID_ENDPOINT,rpt_buf, KEYBOARD_BUFF_SIZE);
or
(Receiving data from Device)
_usb_host_recv_data(host_handle, pipe, &tr);
MQX Classic (MQX 4.2) does also have support for Host or Device and APIs are almost the same. You can consult examples on these stacks.
Hope this helps!
Regards,
Isaac