how to respond to EP1 interrupt requsts?


Closed Thread
Results 1 to 7 of 7
  1. #1
    Join Date
    Dec 2005
    Location
    So Cal and loving it
    Posts
    40

    Default how to respond to EP1 interrupt requsts?

    OK, I give up..... has anyone got any experiance of handling interrupt transfers using the microchip USB framework code, USB18.asm etc.

    I have been reading through the files (on and off for 2 weeks), trying to break them down, but the framework seems to be geared only for EP0 std requests, HID and CDC stuff but not interrupt transfers.

    My device enumerates fine and I was able to re-write some of the assembler to reply to a specific class request, but this last part is killing me.
    All I have left is to be able to detect an EP1_IN interrupt request and send 7 bytes back to the host via EP1_IN.

    I am interfacing to existing software (process monitorring) so have no control over the host side of things.

    Some pointers in the right direction, thoughts, ideas or a link to another framework that can handle interrupt transfers would be great.

    Thanks Paul
    +-------------------------------------------------------------------+
    | PBP 2.47/2.50 | MCS+ 3.0.0.5 | U2 Prog | Vista x64 | NO SLEEP!!!!!!! |
    +-------------------------------------------------------------------+

  2. #2
    skimask's Avatar
    skimask Guest

  3. #3
    Join Date
    Jul 2003
    Location
    Colorado Springs
    Posts
    4,959

    Default

    Nope,

    I'm pretty sure there's nothing in mister-e's USBdemo that'll help with EP1_IN interrupt requests.

    And I have no better answers.

    DT

  4. #4
    Join Date
    Dec 2005
    Location
    So Cal and loving it
    Posts
    40

    Default

    Thanks Skimask, the demo was fantastic - I used it as my jump point to get in to USB but as DT says, there is nothing for interrupt transfers.

    Thanks for the replies guys, it looks like I may be beat by this one. If I find a way, I will post here but its not looking good.

    Paul
    +-------------------------------------------------------------------+
    | PBP 2.47/2.50 | MCS+ 3.0.0.5 | U2 Prog | Vista x64 | NO SLEEP!!!!!!! |
    +-------------------------------------------------------------------+

  5. #5
    skimask's Avatar
    skimask Guest

    Default

    Quote Originally Posted by locko View Post
    Thanks Skimask, the demo was fantastic - I used it as my jump point to get in to USB but as DT says, there is nothing for interrupt transfers.
    Ya, I know, but didn't know if you had seen that thread or not. It's what got me started with the USB.

  6. #6
    Join Date
    Mar 2008
    Location
    Gerogetown, Texas
    Posts
    94

    Default

    Paul

    Up to now I have only used one endpoint. I believe you set up your device in the descriptor file. You tell it the number of interfaces you want, the number of endpoints, in the endpoint descriptor you tell the type of transfer and so on.

    Then in the report descriptor you would set the packet size type of data and so on.

    In PBP you would listen for that endpoint "USBIN X,buffer,cnt, goto label" (X being the endpoint number 1,2 etc). The PC sends endpoint "0" PBP endpoint is 1

    Check out the USB18.inc file

    I am not an expert but have made many USB devices and written custom descriptors.


    Dave

  7. #7
    Join Date
    Dec 2005
    Location
    So Cal and loving it
    Posts
    40

    Default

    Hi Dave,
    Thanks for the reply.

    Quote Originally Posted by DaveC3 View Post
    Paul

    Up to now I have only used one endpoint. I believe you set up your device in the descriptor file. You tell it the number of interfaces you want, the number of endpoints, in the endpoint descriptor you tell the type of transfer and so on.
    Got that far. My descriptor is set for 1 interface and endpoint1in is set for 8 byte buffer length and interrupt.

    Then in the report descriptor you would set the packet size type of data and so on.
    Not sure about this one. I have no report descriptor. I have made other HID projects and see that endpoint 1 has a report descriptor, but I thought that was due to the 'get_report' is a control transfer that comes in via the setup packet and not as in interrupt request on the USTAT. Do you have any further details on this?

    In PBP you would listen for that endpoint "USBIN X,buffer,cnt, goto label" (X being the endpoint number 1,2 etc). The PC sends endpoint "0" PBP endpoint is 1

    Check out the USB18.inc file

    I am not an expert but have made many USB devices and written custom descriptors.


    Dave
    Got to love the USB18 file..... I have been reading it over and over for a few weeks now and none of the functions deal with interrupt requests.
    I will try to use PBP to setup and initialize the endpoint buffer descriptor in memory and then read the USTAT for an ep01_in request and then set uown back to the sie etc.

    Should be able to get some time this weekend to try a few things.

    Thank again,

    Paul
    +-------------------------------------------------------------------+
    | PBP 2.47/2.50 | MCS+ 3.0.0.5 | U2 Prog | Vista x64 | NO SLEEP!!!!!!! |
    +-------------------------------------------------------------------+

Similar Threads

  1. Won't go back to SLEEP after 1st Interrupt
    By jellis00 in forum mel PIC BASIC Pro
    Replies: 32
    Last Post: - 29th June 2009, 09:00
  2. Can't ID interrupt source with this IntHandler??
    By jellis00 in forum mel PIC BASIC Pro
    Replies: 7
    Last Post: - 3rd June 2009, 02:35
  3. Help with Analog Interrupt
    By brid0030 in forum mel PIC BASIC Pro
    Replies: 7
    Last Post: - 13th February 2008, 18:14
  4. NEWBIE: Some basic questions using interrupts
    By JackPollack in forum mel PIC BASIC Pro
    Replies: 5
    Last Post: - 8th March 2006, 02:59
  5. USART interrupt not interrupting right
    By Morpheus in forum mel PIC BASIC Pro
    Replies: 12
    Last Post: - 6th March 2005, 01:07

Members who have read this thread : 1

You do not have permission to view the list of names.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts