Hello,
I want to enable usb interrupt for attached project.
So I made some changes on it but could't enable it.
Could you help me to find the what I'm missing?
Kind regards,
usb_hmsc_baremetal_ek_ra4m2_ep.rar
The USB interrupts are already enabled:
When I connect a USB device, it doesn't call the callback function as I defined as; (I added some lines to see on debug scrren)
void free_rtos_fat_callback(rm_freertos_plus_fat_callback_args_t *p_args)
{
if (p_args->event & RM_FREERTOS_PLUS_FAT_EVENT_MEDIA_INSERTED)
g_rm_freertos_plus_fat_insertion_events = true;
APP_ERR_PRINT ("\r\n USB Media Inserted! \r\n");
}
if (p_args->event & RM_FREERTOS_PLUS_FAT_EVENT_MEDIA_REMOVED)
g_rm_freertos_plus_fat_insertion_events = false;
Are you trying to run the example from Github ?
Make sure you follow the instructions on EK-RA4M2:
USB PCDC (Full Speed): 1. Connect the micro USB end of the micro USB device cable to micro-AB USB Full Speed port (J11) of the board. Connect the other end of this cable to USB port of the host PC. 2. Jumper J12 placement is pins 2-3 3. Connect jumper J15 pins UART: 1. p602 (TXD) to RX pin of external UART device 2. p601 (RXD) to TX pin of external UART device 3. When using flow control from TeraTerm, the CTS (P603) should be connected to GND. For instructions on how to enable and disable flow control, refer the the FSP User's manual.
github.com/.../usb_pcdc_with_freertos_ek_ra4m2_ep
I'm so sorry for the late reply. Yes, I'm running the example from Github.
I also have the same interrupt problem with CAN example for EK-RA4M2.
I use MCP2551 and USB-CAN Analyzer to receive CAN message from USBCAN desktop application.
I can see on RX line datas are going but it doesn't trigger interrupt signal and doesn2t call callback function.
These are the screenshots for my CAN example running.
I fixed my issue with CAN Interrupt problem. It seemed that I didn't configure the pins properly.
I created a small project for USB HMSC. When I inserted a FAT32 formatted 4GB device, it cann't pass the RM_FREERTOS_PLUS_FAT_MediaInit function. I atteched the project. Could you help me to run the project properly?
USB_Test.rar
Glad you solved the issue. As this is a different issue please create a new post and give some more details, for examle the return value of RM_FREERTOS_PLUS_FAT_MediaInit.