• AVR Freaks

USB Laser Printer Class Code with PIC24F or PIC32F

Author
bharat.gopani
New Member
  • Total Posts : 5
  • Reward points : 0
  • Joined: 2011/03/12 02:47:53
  • Location: 0
  • Status: offline
2011/03/22 05:48:13 (permalink)
0

USB Laser Printer Class Code with PIC24F or PIC32F

 
Hello ,
 
I want to interface USB Laser Printer with PIC24F or PIC32F .
 
If  anyone has USB Laser Printer Class Code with PIC24F or PIC32F , then let me know .
 
 
 
 
 
 
  
#1

4 Replies Related Threads

    chinzei
    Super Member
    • Total Posts : 2250
    • Reward points : 0
    • Joined: 2003/11/07 12:39:02
    • Location: Tokyo, Japan
    • Status: offline
    Re:USB Laser Printer Class Code with PIC24F or PIC32F 2011/03/22 11:43:34 (permalink)
    0
    Microchip Application Library provides a couple of USB host - printer demo.
    These examples give you a starting point.
    http://www.microchip.com/...&dDocName=en547784

    The problem lies in the supported PDL (Page Description Language) of the printer. If the printer would support well-documented PDL, like ESC/P, PCL5 or PostScript, your PIC may make print pages using these PDLs. But recent low-cost laser printers render pages on PC device driver, and they receive just compressed page images over USB. For these printers, the documents for the page format are not open. So, it's hard to render pages on a PIC.

    By monitoring USB traffic of the printer enumeration on a PC, you'll know supported PDLs by the printer. It appears in the string responding to GET_DEVICE_ID, following "CMD:" tag

    Here is an excerption from enumeration sequence of an old laser printer (Epson LP-2400) on my desk.
     
    ...
    ...
    - Set_Configuration
    - Get_Descriptor( Device )
    - Get_Device_ID (A1 00 00 00 00 00 F1 03) - printer class-specific request
    - IN
    00 6B 4D 46 47 3A 45 50 53 4F 4E 3B 43 4D 44 3A   .kMFG:EPSON;CMD:
    45 4A 4C 2C 45 53 43 50 32 34 4A 2D 38 34 2C 45   EJL,ESCP24J-84,E
    53 43 50 41 47 45 4A 2D 30 34 2C 45 53 43 50 53   SCPAGEJ-04,ESCPS
    55 50 45 52 2D 30 30 2C 50 52 32 30 31 2D 30 30   UPER-00,PR201-00
    3B 4D 44 4C 3A 4C 50 2D 32 34 30 30 3B 43 4C 53   ;MDL:LP-2400;CLS
    3A 50 52 49 4E 54 45 52 3B 44 45 53 3A 45 50 53   :PRINTER;DES:EPS
    4F 4E 20 4C 50 2D 32 34 30 30 3B                  ON LP-2400;

    This printer supports ESC/P 24-J84 (ESCP24J-84, Dot printer emulation) and PR201 emulation (PR201-00). These are easy PDLs for MCU.

    You'll get the DEVICE_ID string on software sniffers, which supports capture of enumeration at device plug-in, like
    USBlyzer  http://www.usblyzer.com/
    USBTrace  http://www.sysnucleus.com/

    Download a trial and "evaluate" it Smile

    This page is helpful to interpret the Device ID string

    IEEE 1284 Device ID
    http://www.undocprint.org...on_protocols/ieee_1284

    Tsuneo
    post edited by chinzei - 2011/03/22 12:11:24
    #2
    fusebox
    New Member
    • Total Posts : 8
    • Reward points : 0
    • Joined: 2011/08/28 14:22:57
    • Location: 0
    • Status: offline
    Re:USB Laser Printer Class Code with PIC24F or PIC32F 2011/09/02 16:03:54 (permalink)
    0
    Hello folks.
    I'm planning on working on a similar project and was wondering whether a USB capable PIC18, say the PIC18F4550, would serve the purpose. Any advice?
    #3
    DarioG
    Allmächtig.
    • Total Posts : 54081
    • Reward points : 0
    • Joined: 2006/02/25 08:58:22
    • Location: Oesterreich
    • Status: offline
    Re:USB Laser Printer Class Code with PIC24F or PIC32F 2011/09/03 02:05:55 (permalink)
    0
    PIC18 can't act as USB hosts...

    GENOVA :D :D ! GODO
    #4
    fusebox
    New Member
    • Total Posts : 8
    • Reward points : 0
    • Joined: 2011/08/28 14:22:57
    • Location: 0
    • Status: offline
    Re:USB Laser Printer Class Code with PIC24F or PIC32F 2011/09/03 06:32:16 (permalink)
    0
    Thank you
    #5
    Jump to:
    © 2019 APG vNext Commercial Version 4.5