Anda di halaman 1dari 10

RS232 - RS485 Converter with Automatic RX - TX Control | EEWeb

Join Our Community: Sign-Up

or

Login

Toolbox

App Note Search

Calculator

Part Number / Keyword...

Home

Tools

News
RF Design

Forum

Community

Articles

Projects
Test & Measure

Events

Jobs

Comic
PCB Design

Analog Design

Power Management

Embedded Design

Components

ACTIVITY

BLOG

PROJECTS
Return to Projects

RESUME

FOLLOWING

CONTACT

CIRCUIT'S PROJECTS :

RS232 - RS485 Converter with Automatic RX - TX Control


Posted Jan 10, 2012 at 9:47 am

FEATURED PRODUCTS

Circuit Projects
BLOGGER

PROJECT SUMMARY

EEWEB STATS
Karma: 0 Followers: 22 Following: 0

Today, although the wireless technology grows very fast, the long distance funicular communication still keeps its popularity. The reason is obvious that cost and complexity is high at the wireless communication. Intersil ISL28134 Op Amp
PROJECT DESCRIPTION 5V zero drift rail-to-rail precision op amp features low power consumption with half the noise of similar amps

RS232 is one of the most used, easy to develop and easy to apply communication protocol. We generally encounter to this standard at the MCU applications. But it has some restrictions. It allows us to use maximum 15 meters cable. Good wiring, low baud rates and less noisy mediums may allow us to exceed this limit a little more. The main problem here , when the distance increases, the noise at the common ground line also increases. Another issue, RS232 allows only two devices to communicate reciprocally. More than two devices can not communicate at this line and we need another solution for this situation. RS485 is the standard that solves this problems. The main difference is, RS485 transfers the data depending on the potential difference between the two communication wires. The polarity defines the logic state of the signal. You can transfer data up to 1220 meters far away and with a rate up to 10 Mbs. 32 devices can join the RS485 network. While transferring the data, MAX232 converts the signal coming from the DB9 connector to TTL/CMOS level. Then MAX485 transfers the input signal coming from the MAX232 to the RS485 line as a voltage difference. While receiving the data, MAX485 detects the data at the RS485 line and transfers it to MAX232 then output can be taken from the DB9 connector. Converter controls the Receive and Transmit modes automatically. R1, R2 : 1K 1/4W Resistor R3, R4, R5, R11 : 2.2K 1/4W Resistor R6, R7 : 560 Ohm 1/4W Resistor R8, R9 : 47 Ohm 1/4W Resistor R10 : 120 Ohm Resistor C1 : 10uF 50V Electrolytic Capacitor C2, C4 : 100n Polyester Capacitor C3 : 10uF 16V Electrolytic Capacitor C5, C6, C7, C8 : 1uF 16V Electrolytic Capacitor D1 : 1N4007 Diode L1, L2 : Red and Green LEDs Q1 : BC327 PNP Transistor U1 : MAX232N U2 : MAX485CPA U3 : LM7805

Bourns RS-485 Eval Boards


Evaluation boards that streamline evaluating circuit protection on RS485 serial device ports

TechXchange General Community


Technical questions? Find your answers here! Digi-Key experts available 24-7!

http://www.eeweb.com/project/circuit_projects/rs232-rs485-converter-with-automatic-rx-tx-control[4/11/12 1:05:04 PM]

RS232 - RS485 Converter with Automatic RX - TX Control | EEWeb

J1 : DB9 PC Mount Female Connector U4, U5 : 2 Terminal PCB Terminal Block The PCB file is provided in pdf format. You can apply it to the board by using the ironing method.

Figure 1

Red LED indicates the transmitting and green one indicates the receiving process. When there is no data transfer, to keep the data line at a constant voltage leve , two 560 Ohm resistors are connected to the line. One of them is powered and the other one is grounded.

Figure 2

The main advantage of this converter is, it can detect the incoming/outgoing data and switch the TX and RX modes of MAX485. It controls the DE and RE enable bits automatically. The RS485 lines A and B are taken from the screw terminal block. The connections are shown in the layout that is inside the downloadable zip package.

PROJECT FILES
File Name PCB Layouts and Schematic File Size 232.12 KB

http://www.eeweb.com/project/circuit_projects/rs232-rs485-converter-with-automatic-rx-tx-control[4/11/12 1:05:04 PM]

RS232 - RS485 Converter with Automatic RX - TX Control | EEWeb


Tags: RS232, converter

Comments on this Project:


By Sergio Rodrguez Score: 0 3 years ago: Estimados Seores, he estado tratando de descargar el archivo que contiene PCB layouts and the schematic y siempre baja roto y luego no puedo abrirlo. Le agradecera si pueden verificar el estado de ese archivo para poder descargarlo. Muchas Gracias Sergio

By Sergio Rodrguez Score: 0 3 years ago: Hello Sirs, I have tried to download the file with PCB layouts and the schematic and all the times is broken. I hope that you can verify that file to make a satisfactory download. Thanks and Regards. Sergio

By jack Score: 0 3 years ago: Hi Sergio, I just downloaded the file and no problem occured. Please try again and if you still have problems please write with more detailed description. Regards.

By Sergio Rodrguez Score: 0 3 years ago: Thanks Jack, I have tried again and file has downloaded fine now. Best Regards. Sergio.

By Sergio Rodrguez 3 years ago: Congratulations Sirs. It is a very goog and useful project. Regards. Sergio

Score: 0

By Sergio Rodrguez Score: 0 3 years ago: Hello Sirs. I am here again. I have assembled this circuit and have a problem. When I try to send data, pin 3 of MAX485 (I have used SN76175) stay in low state (0.28 volt) and MAX485 dont work. I hope that you have any solution. Thanks and Best Regards. Sergio

By bigmac Score: 0 3 years ago: Hi, are you sure that SN76175 is the equivalent of MAX485? I couldn't find any datasheets for SN76175.

By Sergio Rodrguez 3 years ago: Sorry I have done a mistake. I beg your pardon. I have used SN75176 , not SN76175. Thanks again. Sergio

Score: 0

By jack Score: 0 3 years ago: Hi Sergio, I just checked the assembled circuit. When there is no transmit, the pin 3 keeps its high state (6.5V), when I transmit data it goes to low (2.3V). So it works properly. SN75176 can be used instead of MAX485 as you know. But are there any other difference in your circuit?

By Sergio Rodrguez Score: 0 3 years ago: The only diference I have is SN75176 and my LM7805 give me 5v like the most high tension. How do you have 6.5 volt. The BC327 never change his state and pin 3 from SN75176 is ever low (0.28v). Pin 12 from MAX232 keep always BC327 in the same state.

http://www.eeweb.com/project/circuit_projects/rs232-rs485-converter-with-automatic-rx-tx-control[4/11/12 1:05:04 PM]

RS232 - RS485 Converter with Automatic RX - TX Control | EEWeb I dont know where is the problem. Thanks for your answer.

By Sergio Rodrguez 3 years ago: I have seen the tx led blinking. But nothing in the out of SN75176 Thanks Jack.

Score: 0

By Sergio Rodrguez 3 years ago: Wait a minute please. I forget to wire TR emisor to Vcc.

Score: 0

By jack Score: 0 3 years ago: 6.5V is the result of an input signal with a magnitude greater than 5V. It was only to show the toggle between the high and the low states. I am waiting the result after connecting the emitor :) I hope it will be ok this time.

By Sergio Rodrguez 3 years ago: Well. It seems to be working now, may be fine. I have not experience about this.

Score: 0

I think that have a weak signal level in the out of SN75176. I have teste (pin 6-7) with a led and serial resistence (500 ohm) and blink. In pin 3 I have 0.28v with no data and fluctuates between 0.34v - 0.56v with data trasmition. I just have a digital multimeter. 8-)) I beg your pardon again. Best Regards. Sergio.

By Sergio Rodrguez Score: 0 3 years ago: Hello Sirs. I am working in a develop to connect the computer with my car. I have a Ford car with ECC IV DCL ECU (not OBD2) that has a RS485 communication balanced lines D( ) and D(-). But my assembled circuit has between A-B 1.49V , AGround 3.2v and B-Ground 1.73v and the ECU has between D( )-D(-)4.53v D( )Groung 4.77v and D(-)-Ground 0.24v What do you think about that tensions levels.?? Could this assembled circuit work whit my ECU. ?? I have tryied to establish communication with ecu but nothing happend. Thanks and Best Regards. Sergio

By Sergio Rodrguez 3 years ago: Hello Sirs. I am working in a development to connect the computer with my car.

Score: 0

I have a Ford car with ECC IV DCL ECU (not OBD2) that has a RS485 communication balanced lines D( ) and D(-). But my assembled circuit has between A-B 1.49V , AGround 3.2v and B-Ground 1.73v and the ECU has between D( )-D(-)4.53v D( )Groung 4.77v and D(-)-Ground 0.24v What do you think about that tensions levels.?? Could this assembled circuit work whit my ECU. ?? I have tryied to establish communication with ecu but nothing happend. Thanks and Best Regards. Sergio

By Sergio Rodrguez 3 years ago: Thank you Sirs. I can do it work, with a few changes. Best regards and Merry Christmas.

Score: 0

By jack 3 years ago: Hi Sergio,

Score: 0

I couldn't write for a few days sorry. Did you change the output resistors to set the line voltage level?

http://www.eeweb.com/project/circuit_projects/rs232-rs485-converter-with-automatic-rx-tx-control[4/11/12 1:05:04 PM]

RS232 - RS485 Converter with Automatic RX - TX Control | EEWeb By Sergio Rodrguez 3 years ago: Hi Jack. Yes, I did it. You can see that here http://www.postimage.org/image.php?v=PqQCgbA Its the Ford way. Regards. Score: 0

By Jorge G. Toral Score: 0 3 years ago: Hello. What could happen if there is no resistor array on the MAX485 bus output/input? I mean, if the A-B terminals is taken directly to the bus. Is there an advantage? Thanks in advance.

By Z.R. Score: 0 3 years ago: Hello, I want to design a component to connect 2tx signal from 2 RS232 port to a RX of a RS232 port for communication.Can you help me? Thanks.

By jitender 3 years ago: Hi, I have assembled two rs232-rs485 converter as in the circuit.

Score: 0

Two rs485 lines are cross connected and two rs232 ports are connected to pc.Red, Green LED's are blinking but I am not receiving any data. I have not changed anything. any solution? TIA.

By jack Score: 0 3 years ago: Cross connection is not the proper connection for the RS485 network. You must connect all the A outputs together and all the B outputs together. How many converters you use doesn't matter. http://www.st.com/stonline/products/families/analog_and_mixed_signal/interface_ics/related_info/images/typhalf.gif

By jitender Score: 0 3 years ago: Hi, I did what jack has said, but now neither led's are blinking nor I am receiving any data. this is tha connection I am using... http://www.postimage.org/image.php?v=Pq1RHcc9 TIA

By Sergio Score: 0 3 years ago: Hi jitender. Connection seems to be OK, if your converters has no troubles when was ensambled, I think you have to review your soft.

By Dilip Vora 3 years ago: yes i have commeted

Score: 0

By Siddharth Score: 0 3 years ago: Sir can we use the circuit for RS485-RS232 converter, or is it can work only as RS232-RS485 converter. Please do clarify it Regards

By Siddharth 3 years ago: Can the circuit given work as a RS485-RS232 converter? Regards

Score: 0

By Jack Score: 0 3 years ago: Hi it is both RS485 to RS232 and RS232 to Rs485 converter. Working bidirectional.

http://www.eeweb.com/project/circuit_projects/rs232-rs485-converter-with-automatic-rx-tx-control[4/11/12 1:05:04 PM]

RS232 - RS485 Converter with Automatic RX - TX Control | EEWeb By Nischay Kumar 3 years ago: Hello author, Score: 0

i'd like to do RS485 comm. between micros only (no PC) and since the logic high is 5+V and logic low is 0V, do i still need Max232in the above circuit ?

By Hello Friends Score: 0 3 years ago: I have tried this smart project, it is working fine for receving message from my 89S52 uC based device but i could not broadcast the msg to that device. I have tried 00abc my device is supposed to send back the data once received. will there anything i need to do with uC to make it slave to lisent? Thanks

By Sebastian 2 years ago: In the photo te resistors color indicated that: R1 and R2 are 10K

Score: 0

R3 to R4 are 33K Please Check this values. The color in the photo is orange, not RED. Somebody test and use this circuit? Best Regards!

By jack Score: 0 2 years ago: They seem orange in the photo but they are red in real. Sure many people built this circuit and using it.

By Sergio Score: 0 2 years ago: To see if interface is working, anybody can add some leds over RS485 line like above in picture. Best Regards http://www.postimage.org/image.php?v=PqFvZur

By Babak Score: 0 2 years ago: Hi dear. I want connect modbus with rs485 to micro.can i use this project with auto rx/tx beacuse my modbus is 2 wire.

By Babak Score: 0 2 years ago: Hi Dear. Please send final circuits with last changs.i want build this project but i cant find last version of circuits,PCB and components list beacuse in each comment its change.

By Sergio Score: 0 2 years ago: I have tried the original circuit and think that work very very good.

By babak 2 years ago: Hi Dear. I have try to do this and work probably

Score: 0

By rudy fernandez Score: 0 2 years ago: What I like the most from this circuit is its flexibility to use the two types of communication ports. At least I won't have to rely on RS232 alone if the network equipment has only RS485 port. Thanks!

By MANU 2 years ago: SN75176 is equivalent to MAX485 ?

Score: 0

By Andy P

Score: 0

http://www.eeweb.com/project/circuit_projects/rs232-rs485-converter-with-automatic-rx-tx-control[4/11/12 1:05:04 PM]

RS232 - RS485 Converter with Automatic RX - TX Control | EEWeb

2 years ago: Tried to download the circuit, got the file downloaded by when trying to extract the jpg file nothing happens.

By ary Score: 0 2 years ago: can you give me information all about instalasi all component to PCB, for example Base,emiter,colector to PCB

By Roel Score: 0 2 years ago: Can I swap out the Max232 for a max3232 and the Max485 for a max3471? I want to run this off A 3v psu? Or would there be more changes? Thanks,

By j. johnson 2 years ago: wow! this sounds an interesting circuit. thanks for all your recommendations :)

Score: 0

By amer Score: 0 2 years ago: when the circuits is done, what is the baudrate of the serial com?

By typhoon 2 years ago: the baudrate depend on you cp and mcu decide.

Score: 0

By Tsog 2 years ago: Hi This converter's schematic ?

Score: 0

By synyuno Score: 0 2 years ago: Hi friends, I want to connect between microcontroller and PC with this converter. the converter responses receive or transmit data, but data is not correct. Example : when i send 'ABCD', another converter would received '????>~'. Can anybody help me This is my project http://www.postimage.org/image.php?v=Ts1cxBhJ

By synyuno Score: 0 2 years ago: Hi friends, I want to connect between microcontroller and PC with this converter. the converter responses receive or transmit data, but data is not correct. Example : when i send 'ABCD', another converter would received '????>~'. Can anybody help me This is my project http://www.postimage.org/image.php?v=Ts1cxBhJ

By Hexathlon 2 years ago: Hi Sir, I have built the circuit with all connections as shown.

Score: 0

But it is working good in uni-direction only. If i give some data from 485 to 232 it receives but don't work for reverse.I have used BC557 in place of BC327. Please suggest me solution. Regards, Hexathlon.

By Cassandra 1 year ago: Hi,

Score: 0

http://www.eeweb.com/project/circuit_projects/rs232-rs485-converter-with-automatic-rx-tx-control[4/11/12 1:05:04 PM]

RS232 - RS485 Converter with Automatic RX - TX Control | EEWeb

May I know what is the purpose of R10? Thanks & Regards Cassandra

By Cassandra 1 year ago: Hi,

Score: 0

What is TR emisor that Sergio was talking about? I've built my circuit and seems like not working. Pin 3 from Max485 is always low and no outputs from Max 485. Please help me. Thanks & Regards Cassandra

By alex Score: 0 1 year ago: Buenas, realice el circuito pero no entiendo como probarlo. Alguien puede ayudarme? Que se supone que debo hacer con U4 y U5? porque hay dos? Muchas Gracias Hi, I have donde the circuit but now i dont know how to test it. Can someone help me? What am i suposed to do with U4 and U5? why are too of them? Thanks

By Dhaval Score: 0 1 year ago: Hi, Sir i am using the same circuit as shown in figure but only uni-directional communication is taking place(i.e. transmitting).Actually i have done two changes 1. i have used Transistor 2907 in place of BC237 and given supply voltage of 3V in place of 5v. Am i doing something wrong please help me out. Regards, Dhaval

By saif Score: 0 1 year ago: hi can u plz explain the mechanism f how the auto data transmit detect works?

By sam Score: 0 1 year ago: Is it possible to directly connect the RS-485 lines RX,TX & GND to RS232 RX,TX & GND ?????

By Robert 1 year ago: Is the photo on this site the right side up???

Score: 0

I have produced the board exactly as it is in the PDF File. Unfortunately it doesn't work and the LM7805 becomes very hot and it is pulling almost 1 Amp. Is the PDF-File wrong side up??? My board looks like you put your board on the pictures above next to a mirror and look at it in the mirror. Please help me with the answers fast. please mail me: stocki.mail@gmail.com kind regards Robert from Austria

By Alexander 1 year ago: Hi guy

Score: 0

I have built the device but this is not working anybody help me why no function??

http://www.eeweb.com/project/circuit_projects/rs232-rs485-converter-with-automatic-rx-tx-control[4/11/12 1:05:04 PM]

RS232 - RS485 Converter with Automatic RX - TX Control | EEWeb

By Alexander 1 year ago: Hi guys,

Score: 0

Again me, I was testing the converter for a long time and after a lot of mistakes, I check and the converter works very good, I just changed a couple of resistors. If you want you can check out in link. http://www.postimage.org/image.php?v=PqQCgbA

By gokkul Score: 0 1 year ago: Thanks for the circuit it works great. How long do you think i can run the wire (i tested it with a short cable and it works), will any modification be needed if i run the AB wires for a few meters.

By Angel Score: 0 1 year ago: Hi gokkul, RS-485 standard allows wires to be up to 1200 meters, depending on speed (115200 kbit/s on 1200 m is okay). On long distances and high speeds termination and must be provided. Shielding must also decrease noise. Read here for example: http://www.maxim-ic.com/app-notes/index.mvp/id/763/CMP/WP-1

By syavash Score: 0 1 year ago: hi dear sir i have assembed and tested your board (with special thanks) i have designed a circuit that has rs485 data output . when i connect it to your board it works well but if i connect more than 4 nodes, none on them work when we use your board in the place of the server (computer) then the client circuits must be in which shape of below? 1- no pull up / pull down resstor for the A and B points of slaves 2- we should pull them up/down via a greater resistor such as 4.7k 3- or can we change the 560ohm resistors of your board to 4.7k and then use 4.7k in all the nodes too? thanks

By Jensen Score: 0 1 year ago: Thanks a lot! Usually I buy RS232 to RS485 converter, now I will make my own!

By Rangel Score: 0 10 months ago: I rode the board, but it can only receive data from RS-485 network. I tried to send data to the network RS-485 and failed. I noticed that the green did not rise.

Login or Register to post comments.

GO

EEWeb is the official strategic partner of TechXchange a user-to user forum where everyone from design engineers to hobbyists can discuss technology, products, designs and more. You can participate in discussions, ask questions of the community or of subject matter experts and learn about new products and the latest innovations.

Sensors Community Wireless Community Microcontroller Community Energy Harvesting

Power Community Lighting Community General Discussions

EEWeb Pulse Magazine


Karen Bartleson - Senior Director at Synopsys; President-Elect of IEEE Standards Association Subscribe Latest Issue Electronics News Electronics Quiz

EEWeb RSS Feeds


Engineering Jobs Featured Engineer EEWeb Articles Design Notes Featured Website EEWeb Forum EEWeb Projects Return to Zero Comic Engineering Events

http://www.eeweb.com/project/circuit_projects/rs232-rs485-converter-with-automatic-rx-tx-control[4/11/12 1:05:04 PM]

RS232 - RS485 Converter with Automatic RX - TX Control | EEWeb

Facebook

Twitter

Google+

About Us

Privacy Policy

Terms and Conditions

Copyright 2012 Aspen Labs, LLC

http://www.eeweb.com/project/circuit_projects/rs232-rs485-converter-with-automatic-rx-tx-control[4/11/12 1:05:04 PM]

Anda mungkin juga menyukai