About the HIDRxHandleBusy function in USB communication

Discussion in 'Embedded Systems and Microcontrollers' started by ahgan84, Jul 1, 2014.

  1. ahgan84

    Thread Starter Member

    Dec 19, 2011
    55
    0
    Hi guys,

    I'm using PIC18F25K50 for my project here. And I'm using the HIDRxHandleBusy to receive data from a host.

    When there data is received: HIDRxHandleBusy(USBOutHandle)=0;
    When data is cleared: HIDRxHandleBusy(USBOutHandle)=1;

    Is this a correct assumption?

    Just want to know in what condition, my PIC won't received any data even though the host indicate that it had sent the data?
    I'm using "if(!HIDRxHandleBusy(USBOutHandle))" to check but there's no data coming in.
     
  2. ahgan84

    Thread Starter Member

    Dec 19, 2011
    55
    0
    I have tested again... now the Problem is.. Sometimes I can't received any data from the host especially after idle for 10 seconds.. If every 2-5 seconds the host send data, I can receive it. But if idle for 10 seconds, it can't already...
     
Loading...