AVR to printer interfacing

Discussion in 'Embedded Systems and Microcontrollers' started by ne89, Jan 4, 2007.

  1. ne89

    Thread Starter New Member

    Sep 25, 2006
    9
    0
    hello,

    Does anybody knows how to interface ATmega16 to serial or parallel printer directly?
    Because my printer has 2 ports, which one is easier to make the code ?
    How can printer know the command from AVR that it's for font setting, margin setting, start/stop printing and etc ?
    Any information from you is helpfull to me.
    Thanks,

    ne89
     
  2. beenthere

    Retired Moderator

    Apr 20, 2004
    15,815
    282
    Hi,

    The manufacturer of the printer will have the information necessary to send data to it. There should be a complete description of the interface, including all control signals.

    I don't know how easy it will be to get this information. Printers get shipped with elaborate driver packages to let them function under Windows. You used to get all this information in the manual, but now all you get is instructions on how to unpack it. You will need specific information for any printer you are planning to use.

    I suspect you need to do some more work with your microprocessor in order to understand the concept of interfacing better. AVR has many guides and how-to's on line, which is a good source of information.
     
  3. hgmjr

    Moderator

    Jan 28, 2005
    9,030
    214
    Be aware the that some ATMEGA16 devices are shipped with the JTAG port (PORTC bit3, bit4, bit5, bit6) enabled. If you plan to use these bits from PORTC you may need to reset the internal fuse to disable JTAG feature.

    hgmjr
     
  4. mrmeval

    Distinguished Member

    Jun 30, 2006
    833
    2
    What brand and model printer? What sort of connection did you want to make?
     
  5. ne89

    Thread Starter New Member

    Sep 25, 2006
    9
    0
    hi,

    I want to use epson TM220D with serial communication.
    Which one is easier to interface serial or parallel?
    Thanks.

    ne89
     
  6. n9352527

    AAC Fanatic!

    Oct 14, 2005
    1,198
    4
    This is a commercial impact printer, and usually have their own codes and interfaces. You need to get hold of the printer manual. Go to Epson-pos website and you need to register to download the manual. TMU220 is the newer equivalent model.
    Then, it is just a matter of sending the appropriate codes to control the printer.

    I would go for serial, simply because it needs less pins to work.
     
Loading...