I want to use AT89C51 serial to communication a bar code reader, the bar code reader is Serial ASCII (RS-232), can I directly driven the reader output data to the microcontroller?
No, you can not.
You will need a RS-232 driver circuit such as MAX(AD, DS, ST,...)232, MAX202, or similar .. (how to connect this driver: **broken link removed**)
Thanks you for your help and suggest the solution.
Actually, I have finished the project, the bar code TX data pin is directly connect to the AT89C51 RXD pin, and the AT89C51 still can receive the correct bar code data.
why I have not add the RS232 Level converter, the AT89C51 still can receive the data???
The Max232 only converts the logic TTL levels of the received data to +10 and -10 volts to meet the RS232 serial port standard, so if u want for example to connect the Microcontroller to the PC serial port (which uses the RS232 standard) u had to use a level converter such as MAX232.
The answer to your question why you could connect the bar code reader directly to 89c51 is this: in the last years more and more equipment such as GPS receivers, POS, and in your case bar code readers, and several others, instead of using standard RS-232 levels use just simple 0-5V output level and in some cases it is already negated, and computer manufacturers facing this "problem" implemented serial ports that can read both: proper RS-232 and 0-5V levels..