1 Reply Latest reply on Mar 18, 2015 2:09 AM by content.librarian

    [FX2] Isochronous IN not working

    content.librarian

      Hello

         

      I try to setup an isochronous endpoint to read data from an external application. As it did not work out, I setup the following minimal example which does not work either. The example should simply feed the computer with data.

         

       

         
      WORD i;  REVCTL = (1 << 1) | (1 << 0); // DYN_OUT, ENH_PKT SYNCDELAY;  CPUCS = (2 << 3) | (1 << 1); // 48MHz CPU clock, CLKOUT enable SYNCDELAY;  IFCONFIG = (1 << 7) | (1 << 6) | (1 << 3) | (3 << 0); // internal 48MHz FIFO clock, asynchronous I/O, slave FIFO SYNCDELAY;  EP2CFG = 0; // EP2: off SYNCDELAY; EP4CFG = 0; // EP4: off SYNCDELAY; EP6CFG = (1 << 7) | (1 << 6) | (1 << 4) | (2 << 0); // EP6: valid, in, isochronous, 512B, double buf SYNCDELAY; EP8CFG = 0; // EP8: off SYNCDELAY;  RESETFIFOS();  EP2FIFOCFG = 0; // EP2: off SYNCDELAY;  EP4FIFOCFG = 0; // EP4: off SYNCDELAY;  EP6FIFOCFG = (1 << 0); // EP6: 16bit //EP6FIFOCFG = (1 << 3) | (1 << 0); // EP6: AUTOIN, 16bit SYNCDELAY;  EP8FIFOCFG = 0; // EP8: off SYNCDELAY;  PORTACFG = 0; SYNCDELAY;  FIFOPINPOLAR = 0; // all FIFO control pins low-active SYNCDELAY;  USE_USB_INTS();  ENABLE_SUDAV(); ENABLE_USBRESET(); ENABLE_HISPEED();  EA = 1;  RENUMERATE_UNCOND();  while(TRUE) {     for(i=0;i<512;i++){         EP6FIFOBUF[i] = 0xee;     }     EP6BCH = 0x02;     SYNCDELAY;     EP6BCL = 0x00;     SYNCDELAY; }
         

       

         

      Whenever I try to read data from the endpoint, the FX2 always reports that there is no data available. How to fix this problem?

         

      Thank you for your support!

         

       

         

      Kind regards,
      Peter