Author Topic: LCD  (Read 1366 times)

0 Members and 1 Guest are viewing this topic.

Offline cataTopic starter

  • Jr. Member
  • **
  • Posts: 14
  • Helpful? 0
LCD
« on: January 16, 2011, 11:44:00 AM »
I want to do a project with LCD
The control on the LCD will do with Atmel micro controller
This port is only input port it meaning that the receive value pass throw the RS232 or with Infra Red.
What I need to do is connect the LTX from CN2 to the RXD pin in the micro controller and every time I need to check if I receive an pressing on the LCD ?  
« Last Edit: January 27, 2011, 06:13:10 PM by cata »

Offline cataTopic starter

  • Jr. Member
  • **
  • Posts: 14
  • Helpful? 0
Re: LCD
« Reply #1 on: January 20, 2011, 02:39:57 PM »
anyone ???

Offline waltr

  • Supreme Robot
  • *****
  • Posts: 1,944
  • Helpful? 99
Re: LCD
« Reply #2 on: January 20, 2011, 04:55:00 PM »
I would give you an answer if I know what you were talking about.

Can you explain the problem in clear steps?

Quote
micro controller 8952
Do you have a link to this?

Offline cataTopic starter

  • Jr. Member
  • **
  • Posts: 14
  • Helpful? 0
Re: LCD
« Reply #3 on: January 22, 2011, 06:58:27 AM »
Thanks waltr
The datasheet for the microcontroller
the microcontroller is AT89C52
« Last Edit: January 27, 2011, 06:12:38 PM by cata »

Offline waltr

  • Supreme Robot
  • *****
  • Posts: 1,944
  • Helpful? 99
Re: LCD
« Reply #4 on: January 22, 2011, 09:26:54 AM »
From what I read on the LCD data sheet the LTX pin is the "logic level" serial output (see page 6 of the Manual). The levels are 3 and 0V. They call the RS232 but that is incorrect, it is logic level Asynchronous and can be directly connected to a pin on a u-controller. This is shown in Figure 7 and in the Operational text under figure 7 (section 2.3.4).
The touch screen is described in section 2.3.7 and sends out (LTX) a data byte as per figure 10 on "Pen Down".

RXD (P3.0) is the serial input pin on the AT89S52 u-controller, see Port 3 description on page 4. The UART description is on page 9 which refers to the manual for the AT89C51 and AT89C52 processors, so go download that data sheet.

Now there is one more issue with interfacing the LCD to the AT89S52. This is the voltages and logic level of the two devices.
The AT89S52 is a 5V device with a logic high greater than 2.4V (see the DC Characteristics on page 23) BUT the LCD is a 3.3V device with a logic high of 2 to 3V. Therefore, if the LCD's output is only 2V the AT89S52 will NOT see that as a logic high.
It is possible that the LCDs output will be greater tan 2.4V but that is not guaranteed so this may or may not work. What is required is a logic level shifter to ensure the logic levels into the AT89S52 are within spec. One such level shifter is this:
http://www.sparkfun.com/products/8745
The schematic is on that page so you could build one.

Once you have the LCD  connected to the AT89S52 through the level shifter, write the code for the AT89S52 to receive a character from the UART when the LCD sends the Touch Screen data.

 


data_list