The 18f2550 USB connection

Author
luisgerman
Super Member
  • Total Posts : 656
  • Reward points : 0
  • Joined: 2006/04/13 21:45:35
  • Location: Chía-COLOMBIA
  • Status: offline
2007/01/06 06:28:06 (permalink)
0

The 18f2550 USB connection


SENDING A BYTE TO PORTB (via a VB 6.0 app.) <Assembler>
LEDS on PORTB via 330 ohms resistor

 
The 18f2550 USB conecction
 
This work is based on the Assembler version of Jan Axelson's genhid firmware for PIC18F4455 based
on the Lab 2 firmware (Olin College) and macros created by Bradley A. Minch 9/2004 to facilitate
reasonably structured programming in PIC assembler.  These macros were inspired and informed  both
by Karl Lunt's PIC macros, described in an atricle in the July 1999 Nuts & Volts magazine, and by
Myke Predko's structured programming macros, which are described on pp. 542-546 of the second
edition of Programming and  Customizing PICmicro Microcontrollers.  These macros provide facilities
for for-next loops, repeat-until loops, select satatements, and if statements.
bmich (Brad Minch login in this forum) started an excellent thread:
http://forum.microchip.com/tm.aspx?m=89669&mpage=1&key
where he stated "At any rate, the firmware is available if anyone is interested in it"
Thanks to his work (Brad Minch´s), many people (including me) have used it in order to develope
different applications with USB PICs.
The (very simple) visual basic app. is based on mecanique´s EasyHID USBWizard found at:
http://www.mecanique.co.uk/products/usb/easyhid.html
As stated in their site "EasyHID Wizard is completely free"
However the VB6.0 app. included only needs the mcHID.dll in order to be able to run the app.
I´m uploading a zip file with the necessary tools for the 18F2550 device (20MHz xtal, full speed,
basic schematic>), in order to be later studied and modified.
The simple VB 6.0 program provides a way to send a number (0 to 255) to the device, and it is
returned to the HOST (through the PIC’s firmware) which in course it is shown on a list box.
The documents (The 18f2550 USB connection # xx) will be regulary posted with future task to be
achieved.

Luis German
#1

19 Replies Related Threads

    luisgerman
    Super Member
    • Total Posts : 656
    • Reward points : 0
    • Joined: 2006/04/13 21:45:35
    • Location: Chía-COLOMBIA
    • Status: offline
    RE: The 18f2550 USB connection 2007/01/06 06:30:51 (permalink)
    0
    The 18f2550 USB connection 000

    Luis German
    #2
    luisgerman
    Super Member
    • Total Posts : 656
    • Reward points : 0
    • Joined: 2006/04/13 21:45:35
    • Location: Chía-COLOMBIA
    • Status: offline
    RE: The 18f2550 USB connection 2007/01/06 06:31:40 (permalink)
    0
    The 18f2550 USB connection 001

    Luis German
    #3
    luisgerman
    Super Member
    • Total Posts : 656
    • Reward points : 0
    • Joined: 2006/04/13 21:45:35
    • Location: Chía-COLOMBIA
    • Status: offline
    RE: The 18f2550 USB connection 2007/01/06 06:32:42 (permalink)
    0
    The 18f2550 USB connection 002

    Luis German
    #4
    luisgerman
    Super Member
    • Total Posts : 656
    • Reward points : 0
    • Joined: 2006/04/13 21:45:35
    • Location: Chía-COLOMBIA
    • Status: offline
    RE: The 18f2550 USB connection 2007/01/06 06:33:47 (permalink)
    0
    The 18f2550 USB connection 003

    Luis German
    #5
    luisgerman
    Super Member
    • Total Posts : 656
    • Reward points : 0
    • Joined: 2006/04/13 21:45:35
    • Location: Chía-COLOMBIA
    • Status: offline
    RE: The 18f2550 USB connection 2007/01/06 06:34:52 (permalink)
    0
    The 18f2550 USB connection 004

    Luis German
    #6
    luisgerman
    Super Member
    • Total Posts : 656
    • Reward points : 0
    • Joined: 2006/04/13 21:45:35
    • Location: Chía-COLOMBIA
    • Status: offline
    RE: The 18f2550 USB connection 2007/01/06 06:35:54 (permalink)
    0
    The 18f2550 USB connection 005

    Luis German
    #7
    luisgerman
    Super Member
    • Total Posts : 656
    • Reward points : 0
    • Joined: 2006/04/13 21:45:35
    • Location: Chía-COLOMBIA
    • Status: offline
    RE: The 18f2550 USB connection 2007/01/06 06:37:08 (permalink)
    0
    The 18f2550 USB connection 006

    Luis German
    #8
    luisgerman
    Super Member
    • Total Posts : 656
    • Reward points : 0
    • Joined: 2006/04/13 21:45:35
    • Location: Chía-COLOMBIA
    • Status: offline
    RE: The 18f2550 USB connection 2007/01/07 08:46:59 (permalink)
    0
    The 18f2550 USB connection 007
     
    SEND DATA FROM PIC TO HOST
    SEND analog value read on AN0 (A/D converter) to HOST


    Luis German
    #9
    luisgerman
    Super Member
    • Total Posts : 656
    • Reward points : 0
    • Joined: 2006/04/13 21:45:35
    • Location: Chía-COLOMBIA
    • Status: offline
    RE: The 18f2550 USB connection 2007/01/08 15:33:36 (permalink)
    0
    The 18f2550 USB connection 008

    This new task requires some changes in the V.B 6.0 app.; the V.B 6.0 application is included. The task involves reading continuously AN0 (A/D input), and depending on a setpoint to be fixed, to send back (from HOST to PIC) a determined value (0x0F) to PORTB, when the input matches the setpoint.
    post edited by luisgerman - 2007/01/08 16:39:44

    Luis German
    #10
    luisgerman
    Super Member
    • Total Posts : 656
    • Reward points : 0
    • Joined: 2006/04/13 21:45:35
    • Location: Chía-COLOMBIA
    • Status: offline
    RE: The 18f2550 USB connection 2007/01/09 02:41:31 (permalink)
    0
    I forgot to upload the source code for V.B. 6.0 app. so that people
    who really know V.B, can modify it (My V.B. knowledge is limitted,
    and I´m sure these very simple apps. can certainly be improved).

     
    As I stated in post#1 The (very simple) visual basic app. is based
     on mecanique´s EasyHID USBWizard found at:
    http://www.mecanique.co.uk/products/usb/easyhid.html
    As stated in their site "EasyHID Wizard is completely free"
    The VB6.0 app. included only needs the mcHID.dll in order to be able to run the app.

    Luis German
    #11
    luisgerman
    Super Member
    • Total Posts : 656
    • Reward points : 0
    • Joined: 2006/04/13 21:45:35
    • Location: Chía-COLOMBIA
    • Status: offline
    RE: The 18f2550 USB connection 2007/01/16 15:06:33 (permalink)
    0
    The 18f2550 USB connection 009
     
    Sending data from a table (PIC)  to HOST (Introduction; bInterval and program behavior)
     
    Two V.B 6.0 apps. included to be used instead of former one.
     

    Luis German
    #12
    luisgerman
    Super Member
    • Total Posts : 656
    • Reward points : 0
    • Joined: 2006/04/13 21:45:35
    • Location: Chía-COLOMBIA
    • Status: offline
    RE: The 18f2550 USB connection 2007/01/17 19:53:21 (permalink)
    0
    The 18f2550 USB connection 010
     
    Send table data to HOST, or A/D value read on AN0.

    New V.B. app. included.

    Luis German
    #13
    luisgerman
    Super Member
    • Total Posts : 656
    • Reward points : 0
    • Joined: 2006/04/13 21:45:35
    • Location: Chía-COLOMBIA
    • Status: offline
    RE: The 18f2550 USB connection 2007/01/18 17:22:19 (permalink)
    0
    The 18f2550 USB connection 011

    PWM CONTROL (DUTY CYCLE) FROM HOST (Send table data to HOST, or A/D value read on AN0.)
    7Vdc, flashlight bulb DIMMER

    New V.B. app. included.
    post edited by luisgerman - 2007/01/18 23:22:19

    Luis German
    #14
    johnger
    New Member
    • Total Posts : 4
    • Reward points : 0
    • Joined: 2005/05/14 05:52:25
    • Status: offline
    RE: The 18f2550 USB connection 2007/10/31 17:22:30 (permalink)
    0
    sad No can to download the files , please get my e-mail johnger@tutopia.com
    #15
    binu.kr
    New Member
    • Total Posts : 6
    • Reward points : 0
    • Joined: 2008/07/17 21:11:44
    • Location: 0
    • Status: offline
    RE: The 18f2550 USB connection 2008/09/18 01:52:49 (permalink)
    0
    hello can u please help me to get easy hid usb wizard.becoz i cant find it in this site  http://www.mecanique.co.uk/products/usb/easyhid.html

    can u please send me the setup file ..its urgent pls help me if u can
    regards
    binu kr


    #16
    binu.kr
    New Member
    • Total Posts : 6
    • Reward points : 0
    • Joined: 2008/07/17 21:11:44
    • Location: 0
    • Status: offline
    RE: The 18f2550 USB connection 2008/09/18 01:54:46 (permalink)
    0
    this is my mail id kr.binu.kr@gmail.com...pls send me the setup of easy hid usb wizard
    #17
    xiaofan
    Super Member
    • Total Posts : 6247
    • Reward points : 0
    • Joined: 2005/04/14 07:05:25
    • Location: Singapore
    • Status: offline
    RE: The 18f2550 USB connection 2008/09/18 02:03:59 (permalink)
    0
    ORIGINAL: binu.kr
    hello can u please help me to get easy hid usb wizard.becoz i cant find it in this site  http://www.mecanique.co.uk/products/usb/easyhid.html
    can u please send me the setup file ..its urgent pls help me if u can

     
    I understand that it is really really urgent. grin
    http://www.mecanique.co.uk/code-studio/
     
      
    MicroCode Studio now includes EasyHID Wizard, a free code generation tool that enables a user to quickly implement bi-directional communication between an embedded PIC™ microcontroller and a PC.
     
    MicroCode Studio is completely free for non-commercial use. It is not time limited in any way and it does not have any nag screens. However, you can only use one ICD model with MicroCode Studio (please note, if you are using the PICBasic PRO demo version, you will not be able to use the ICD).


     
    I have never used it though so I am not so sure what does this means.

      USB_Links and libusb
    #18
    eagle
    New Member
    • Total Posts : 2
    • Reward points : 0
    • Joined: 2009/03/31 07:43:12
    • Location: 0
    • Status: offline
    RE: The 18f2550 USB connection 2009/03/31 22:57:39 (permalink)
    0
    I have downloaded all the files and try to compile the project in MPAsm.

    I get loads of errors, first on tge _Config statement, MPAsm tells me it should be config.... for the 18F series. And loads of errors on the ENGR2210.inc file.

    I assume these projects have been tested so can anybody please xplain how I get this errors and can get rid of them?
    #19
    eagle
    New Member
    • Total Posts : 2
    • Reward points : 0
    • Joined: 2009/03/31 07:43:12
    • Location: 0
    • Status: offline
    RE: The 18f2550 USB connection 2009/04/02 03:12:53 (permalink)
    0
    I have setup the project for gpasm in MPasm.
    Still get lots of errors.

    Can anybody please help me with the correct settings, so I am able to get this thing assembled?
    #20
    Jump to:
    © 2018 APG vNext Commercial Version 4.5