Here is RS232 to RS485 converter circuit using MAX487, RS-232 system connection faster and easier, But distance is not far. so to change to use the system RS-485 with this RS-232 to RS-485 converter projects. It is highly effective. And savings.
The communication between computers together. or computer and external devices. We can be connected in many ways, such as serial ports, parallel port, LAN, or wireless. But the easiest way is to send serial data (RS-232) is preliminary connection. But has featured is that the speed of the data transfer rate up to 115200 bps. But it There are problem. The maximum transmission distance of up to 15 meters. And the connection between the source and destination devices only. Can not be connected to in the system. Therefore, we must use the RS-485 communication standard, which can have far more information.
The standard RS-485 connections are detailed below.
– Maximum distance of 1,200 meters.
– Communication are Half-Duplex.
– Devices can be connected to the system bus of up is at 255 characters (0-255) on the same bus line. (Depending on the number of the IC used).
– Use the cable to connect the two lines only.
– Level of logic or data is in the current mode.(RS-232 are form voltage mode.)
After we know the details of RS-485 is roughly. then to view the operation of this circuit.
The working of circuit
The power supply of all this circuit will get from port USB of the computer , by there is a diode D5(1N4004) to protection when we connect not correct a polarity our Circuit is safe. The electrical current from port USB will have capacitor C6(470uF) and C7(0.1uF) connected to To prevent power surges when the computer restarts. Or not smooth power.
Next We see the conversion signal. First we use the MAX232-IC to changed the voltage level of computer to the TTL signal. To can communicate with external devices. By the RX signal from at computer at pin 2 to pin 7 of IC1, And the TX, from computers to pin 3 at pin 8 of IC1(MAX232).
At pin 7 of computer will be pin signal RTS. Which will use to select that to send or receive data. (RS-485 Operation Half-Duplex form) Or set to an automatic transmission. The TX and RX signals are output at pin 9 and pin 10 of IC1. Then will into pin 1 of IC2(MAX487) and pin 4 of IC2 which we use IC number MAX487 which can peripheral devices on the bus up to 128 characters.
Details of IC MAX487.
– RO (Receiver Output)
– RE (Receiver Output Enable) working the logic “low” shown that, ready to receive data. But if are the logic High, indicates that not ready to receive data.
– DE (Driver Output Enable) are pin that determined will send data or not. If are the logic high Is ready for to send data. But if are the logic Low indicates that not is ready to send out.
– DI (Driver Input) Pin are used to transmit data, are signal input pin.
– GND pin ground.
-A is pin use to receive or send data to form non inverting.
-B is pin use to receive or send data inverting.
-VCC power supply voltage (4.75 volts – 5.25 volts)
After we do the leg work roughly, then, we see the Circuit again. We will use pin 10 of IC1 connected to pin 1 of IC2 to that use to receiver the data. By have LED1 is show the working that now receiving data (RX). The pin 9 will connect to pin 4 by have LED2 is indicate working that now transmitting the data (TX)
This section There are IC3(74HC04), attached to are buffer. And To difference in voltage, the LED will make illuminate fully. By resistors R6, R7 limits the current to both the LED. Transistor Q1(BC557), controls IC2 to send or receive data. By the normal state, then pin 2, 3 of IC2 will become logic “Low” will make IC2 is ready to receive data. The transistor Q1 to conduct.
But whenever that send the data or the program send a signal to at pin RTS, transistor Q1 conduct, will makes there are resulting pin 2 ,3 are in a the logic “High”. Makes ready to send data. Both sending and receiving is out of pin 6 and pin 7 of IC2 Both legs can either send or receive data. But difference that will has back signals. Or not back the signal only.
In parts of R4 and R5 acts as pull up and pull down. To the stability of the signals. By R8 straddling between the legs 6, 7 of IC2. Or is RT there. In case of the protection circuit uses the input and output diode D4-D7. Act as shields against voltage overload, both inbound and outbound. And the lightning protection may be incurred. To prevent damage from happening to the computer. And the device is attached in the system there. The output signal will have 3 signal are 485 +, 485 -, GND.
Note : If you can not buy MAX487 or too expensive. May be a number SN75176, But performance may be lower than 400 meters and is connected to the bus 32 characters.
GET UPDATE VIA EMAIL
I always try to make Electronics Learning Easy.
Up to $20 shipping discount on first order now: https://jlcpcb.com/quote