HID USB on 18F87J50


Closed Thread
Results 1 to 40 of 57

Hybrid View

  1. #1
    Join Date
    Sep 2009
    Posts
    755

    Default Re: HID USB on 18F87J50

    I try similar thing, but same result.
    So is it possible there are some bug in PBP for this PIC family?

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

    Default Re: HID USB on 18F87J50

    I'm looking into it too.
    Trying to build a board.

    But first I have to ask ...
    Do you have VDD (3.3V) tied to VUSB?
    There's no internal regulator on those chips.
    DT

  3. #3
    Join Date
    Aug 2010
    Location
    Maryland, USA
    Posts
    869

    Default Re: HID USB on 18F87J50

    I can't speak for Pedja's board, But I am pretty sure Walter is using the PIC_LCD3310. If so that DOES show Vusb tied to 3.3V on the schamatic.
    -Bert

    The glass is not half full or half empty, Its twice as big as needed for the job!

    http://foamcasualty.com/ - Warbird R/C scratch building with foam!

  4. #4
    Join Date
    Feb 2006
    Location
    Gilroy, CA
    Posts
    1,530

    Default Re: HID USB on 18F87J50

    Thanks Darrel. I had some weird behavior in my computer. PBP3 kept defaulting to MPASMX, no mater how I set it, I'd check back, and it was set to MPASMX. So after removing the Microchip directory, and re-installing MPLAB 8.76, I was able to get PBP to settle on C:\Program Files\Microchip\MPASM Suite . Now CDC and HID work for the 18F67J50 with PBP3.0! Thanks for routing that out for us!
    Last edited by ScaleRobotics; - 24th August 2011 at 03:46.

  5. #5
    Join Date
    Sep 2004
    Location
    montreal, canada
    Posts
    6,898

    Default Re: HID USB on 18F87J50

    I have to say I'm glad for Melabs it's not another Microchip twist who had to implement another .HWLIB thing.

    Finger crossed for the next USB pic though... BTW, it's about time Microchip release USB3 AND/OR Thunderbolt.
    Steve

    It's not a bug, it's a random feature.
    There's no problem, only learning opportunities.

  6. #6
    Join Date
    Sep 2009
    Posts
    755

    Default Re: HID USB on 18F87J50

    Darrel,
    I try your DT_HID260, and it work on first attempt. It's very simple to use.
    But I have question.
    If I want to use 64 byte, #define USB_EP0_BUFF_SIZE should be 64, is that correct?
    Thanks

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

    Default Re: HID USB on 18F87J50

    No, endpoint 0 is for setup and control transfers. You should not change that.
    And you should not change anything inside the DT_HID260.pbp file.

    Set the report sizes with the defines...

    Code:
    ;--- Setup USB -------------------------------------------------------------
    INCLUDE "DT_HID260.pbp"
    DEFINE USB_VENDORID    6017
    DEFINE USB_PRODUCTID   2000
    DEFINE USB_VERSION     1
    DEFINE USB_VENDORNAME  "Darrel Taylor"
    DEFINE USB_PRODUCTNAME "DT_HID"
    DEFINE USB_SERIAL      "001"
    DEFINE USB_INSIZE      64   ;  IN report is PIC to PC (8,16,32,64)
    DEFINE USB_OUTSIZE     16   ; OUT report is PC to PIC
    DEFINE USB_POLLIN      10   ; Polling times in mS, MIN=1 MAX=10
    DEFINE USB_POLLOUT     10
    DT

  8. #8
    Join Date
    Feb 2006
    Location
    Gilroy, CA
    Posts
    1,530

    Default Re: HID USB on 18F87J50

    I have installed MPLAB8,76. Now I get CDC to work on 2.60C, but I don't get the same file to work with PBP3.

    But I am wondering where PBP3 is looking for MPLAB or MPASM? 2.60 allowed you to select the location for PBP, and it also allowed you to show it where the assembler was located. In PBP3 I get this option:

    Name:  pbp3.PNG
Views: 1445
Size:  28.8 KB

    How am I supposed to enter them both? Or are they really supposed to be in the same place??

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

    Default Re: HID USB on 18F87J50

    In the Start menu, go to All Programs > PBP3 from melabs > MPASM-MPLAB setup.
    It allows you to set the path to MPASM.
    DT

Members who have read this thread : 0

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