3 Replies Latest reply on Apr 11, 2016 11:23 PM by nishanta_46

    Correct practice when implementing a command protocol using bulk endpoints



      We are in the process of upgrading the FX2 chip of our devices to FX3. We are implementing our custom command reply protocol using Bulk endpoints.


      Bulk OUT endpoint is for command and Bulk IN endpoint is for command reply.


      I have started implementation using BulkSrcSink example project.


      Following is the way that I have implemented command handling.

      1. In the DMA Producer callback I am copying the DMA buffer to a global buffer.
      3. Then I fire an event to my command handler thread
      5. That thread takes the command from the global buffer and process it
      7. Then it commits the reply to the BulkSource channel.

      Is this the correct approach? Or is there a better and an efficient approach?


      Thank you.