??? 06/27/09 22:32 Read: times |
#166533 - Not necessarily! Responding to: ???'s previous message |
David Prentice said:
The RS232 line has +-12V signals. This is not entirely correct. All RS232 requires is that the two signals have a dead-band of 3 volts on either side of GND at the receiver, and the transmitter must ensure that the remote receiver "sees" a voltage above 3 volts or below -3 volts for RS232 to operate properly. How you get there is quite arbitrary. While the MAX232 is a common and generally convenient way of doing this, there are other devices equally capable of creating satisfactory levels, e.g. MC1488, MC1489, etc. Note that MAX232 doesn't generate bipolar 12 volts. You must use a driver The term you want is level-translator. The logic is inverted and the voltage is shifted to avoid that dead-band. chip between the 8051 and the PC. The driver chip automatically inverts the TTL levels to/from the 8051 to/from the RS232 line.
So you have possibly destroyed your AT89S52 chip. Try programming and verifying and running some simple programs. Perhaps flashing an LED on the RXD and TXD pins of the chip to check they have not been damaged. One safe way to avoid damaging TxQ and RxD is to clamp TxD to the rails with diodes, having inserted a series resistor of, say, 510 ohms between the off-board signal source and the clamping diodes. The same should be practiced with RxD, i.e. RxD should be received through R510 and clamped to the rails before reaching the MCU. Then install the MAX232 and try a simple "hello World" to the PC.
David. There are lots of ways to skin this "cat," though the MAX232A provides an easy solution if it's available. There's also the DS275, from Dallas Semiconductor ... RE |