RS232与RS485的转换方法
Papouch UC485 RS232到RS485 422线转换器说明书

9/30/2016w w w .p a p o u c h .c o m0004RS232 <> RS485/422UC485RS232 to RS485 or RS422 line converterwith isolationUC485 Papouch s.r.o.Page 2U C 485DatasheetCreated: 5/4/2005 Last update: 5/19/2005 9:15Number of pages: 16 © 2016 Papouch s.r.o.P a p o u c h s.r.o.Address:Strasnicka 3164 110 00 Prague 10 Czech RepublicTel:+420 267 314 267Fax:+420 267 314 269Internet:E-mail:****************Papouch s.r.o.UC485Page 3TABLE OF CONTENTSDescription .......................................................... 4 Features ............................................................. 4 Installing options ................................................. 4 Technical Parameters .. (5)General ........................................................ 5 Connector pins ............................................. 5 Settings (6)Modes .......................................................... 6 Line termination and idle mode .................... 7 Automatic control settings ............................ 7 Installation for the RS485/422 line ............... 9 Installation for the RS422 line .................... 11 RS232 line extension ................................. 12 RS485 and RS422 lines .................................... 13 Possible problems during installation . (15)Fig. 1 –Principal diagram of isolationUC485 Papouch s.r.o.Page 4DESCRIPTIONThe UC485 module converts an RS232 line to RS485 or RS422. The module settings can be set with the aid of switches, as described below. The green LED indicates that the module is ON; the yellow indicators show the RxD and TxD status.FEATURES∙Lines can be set: RS485, RS422, and RS422 multimaster∙Transmission speed up to 480 kBd∙Direction control on the RS485 line can be automatic or by DTR signal (whose polarity can be set)∙The RS485/422 line (including the grounding) is completely isolated from RS232 and from the power supply (this isolation is provided as standard for all types) ∙Optionally, grounding of the power supply and grounding of the RS232 line can be isolated from each other∙The RS485/RS422 line is over voltage protected∙The ON and data flow statuses are indicated by LED indicators – the unit activation is easy ∙ A built-in optional termination, including resistors which define the line's idle status∙Power supply 7 to 40 V (depending on the type, also 36 to 75 V or 5 V)∙D-SUB 9 connectors or a slip-on termination board∙Dimensions 105 × 55 × 24 mm, optionally secured to a DIN stripINSTALLING OPTIONSHolder:∙Without a DIN rail holder (standard)∙With a DIN rail holder RS485/422 connection:∙D-SUB 9M (type UC485C)∙Slip-on terminal board (type UC485S)Power supply:∙7 to 40 V 1(standard configuration)∙ 5 V ±10% 1,2∙ 4.5 V ±10% 2,3∙9 V ±10% 2.3∙18 V to 36 V 2.3∙36 V to 75 V 2.3Please do not hesitate to contact us if you have specific requirements for the UC485 module's configuration and functionality.1 The RS485/422 line (including the grounding) is completely conductively separated from RS232 and from thepower supply (G1 separation cf. Fig. 1). The power supply and the RS232 line have common grounding.2 The time limit for delivery of this configuration is between one and three weeks.3 The RS232 line's grounding is conductively separated from the power supply's grounding (cf. Fig. 1 to seethe G2 separation).Fig. 2 – UC485SPapouch s.r.o.UC485Page 5TECHNICAL PARAMETERSG e n e r a lPower supply voltage ........................ 7 V to 40 V (optionally, 4.5 – 75 V) with protection frompolarity reversal Power supply connector .................... S lip-on connector board Isolation ............................................. 1,000 V Maximum transmission speed ........... 480 kBd Operating temperature....................... –20 °C to +70 °C RS485/422:Terminal resistors .............................. 120 Ω Resistors which define the idle status ......... 680 Ω Maximum number of connected devices . (31)Voltage overprotection ....................... y es, 12 V bipolar transil diodes UC485C connection .......................... D -SUB 9MUC485S ............................................. s lip-on connector board RS232:Voltage overprotection ....................... 15 kV Connection ........................................ D -SUB 9M C o n n e c t o r p i n s16Fig. 3 – RS232 pinsFig. 4 - RS485/422 pins on UC485CFig. 5 – Power supply connector Fig. 6 – RS485/422 pins on UC485SUC485 Papouch s.r.o. SETTINGSM o d e sThe communication modes are set by switches on the front panel.Fig. 7 – Front panel switches, module UC485 (they are all OFF in this figure)Table 1 – Settings of the communication line modesPage Papouch s.r.o.UC485Page 7L i n e t e r m i n a t i o n a n d i d l e m o d e TERM485This device connects the impedance termination of the RS485 or RS422 line on the transmitter's side. It prevents signal from reflection at the line ends. These resistors should be connected at both ends of the communication line.TERM422This device connects the impedance termination of the RS422 line on the receiver's side. It prevents signal from reflection at the line ends. These resistors should be connected at both ends of the communication line.BIAS485This device connects the resistors which define the idle mode of the RS485 or RS422 line on the transmitter's side. They determine the idle-status levels of the communication line. (More detailed information can be found in the section "Idle mode" on page 10.)A u t o m a t i c c o n t r o l s e t t i n g sWhen automatic (time) control is used for the RS485 or RS422 line, the value T of the time delay can be set, for which the driver remains switched to transmission.Fig. 8 – Time delay for which the driver remains switched to transmissionThe default value of this delay is 460 μs; it can be changed using jumpers inside of the module. First open the module case. Unscrew the two screws (opposite to each other) on the modulecase's bottom side, loosen the screws on the top lid, and tilt the top lid out.Fig. 9 – Locations of the screws securing the top lidUC485Papouch s.r.o.Page 8There are four jumpers inside.Fig. 10 – Jumpers for setting the time delay valueThe jumpers' configuration defines the time delay value T. The default value of this delay is 460 μs; it can be changed using jumpers inside of the module. The configurations and their meanings are shown in the Table below.Table 2 – Time delay value settingSW1 SW2 SW3 SW4Papouch s.r.o.UC485I n s t a l l a t i o n f o r t h e R S485/422l i n eThe following steps are used for the UC485 converter installation for communication on an RS485 line:1) Set the switches SW3 through SW8 according to Table 1 on page 6.2) Connect the RS485 wires to the D-SUB 9M connector according to Table 3. (Cf. theconnector diagram on page 5.)Table 3 – RS485 line connection3) Connect the RS232 wires to the D-SUB 9F connector according to Table 4 using anuncrossed cable.Table 4 – RS485 line connection4) If the converter is at a line endpoint, the termination resistors should to be connected bya TERM485. Switches consider connection of resistors which define the idle status.5) Connect to the power supply.1The DTR or RTS signal is only used within modes with the DTR line control. The mode settings are described on page 6 under "Modes". Page 9UC485Papouch s.r.o.Page 10Idle modeWhen communicating on the RS485 line or the RS422 multimaster line, there may be a no-transmission status (all lines are in the receiving mode). In this case, the status of the line is undefined and it is extremely sensitive to any induced voltage (interference), which is deemed incoming signals. Therefore an idle mode should be defined by connecting suitable resistors to a line. If the line is long, the best point is at the UC485 end-of-line modules or equipment.With the UC485 converter, built-in resistors can be used, connected by the BIAS485 switches; or the resistors may be connected directly to the RS485 connector (cf. Fig. 11). For long lines, the resistor values should be higher and the termination should be connected simultaneously.SGND can also be used for connection of the cable shielding contact.Fig. 11 – Connection of resistors which define the idle modeI n s t a l l a t i o n f o r t h e R S422l i n eThe following steps are used for the UC485 converter installation for communication between two devices on an RS422 line:1) Set the switches SW3 through SW8 according to Table 1 on page 6.2) Connect the RS422 leads to the D-SUB 9M connector according to Table 5 (a drawing ofthe connectors is on page 5).Table 5 – RS422 line connection3) Connect the RS232 leads to the D-SUB 9F connector according to Table 6 using anuncrossed cable.Table 6 – RS232 line connection4) If the converter is at a line endpoint, the termination resistors are to be connected by theTERM422. For the multimaster mode, consider connection of resistors which define the idle status.5) Connect to the power supply.5The DTR or RTS signal is only used within modes with the DTR line control. The mode settings are described on page 6 under "Modes".R S232l i n e e x t e n s i o nBy using two UC485, you can extend an RS232 line to a distance of up to 1,200 m.61) Connect the RS232 line and the power supply to the UC485 converters on both ends.2) Both converters should be set to the RS422 mode according to the above-mentionedinstructions.3) Connect the cable between the converters according to Table 7 (a drawing of theconnectors is on page 5).Table 7 – RS232 extension line connection6 An RS232 line can also be extended with the aid of a special LD232 set.RS485 AND RS422 LINESAn RS485 line consists of a pair of wires, denoted by symbols RxTx+ and RxTx-7, preferably by a twisted pair. In the idle mode, the RxTx+ wire's potential is more positive than that of RxTx-. The topology is a stem line with short branches. Impedance termination devices should be connected at both ends of the stem line. The RS485 line is a half-duplex bus: data is sent and received on the same wires. Therefore the communication direction must be switched between transmission and receipt.Fig. 12 – An example of a system with an RS485 line interconnection. Termination is connected inModules 1 and 5.The DTR signal of the RS232 line can be used for the direction control, or automatic (time) control can be used.Fig. 13 – An example of a system with an RS422 line interconnection. Termination is connected inboth modules.7 Notation A (for RxTx+) and B (for RxTx–) is sometimes used.Fig. 14 – An example of a system with an RS422 line interconnection in the multimaster mode.An RS422 line consists of two symmetric pairs of conductors. It is duplex line and directly substitutes the RxD and TxD signals of the RS232 lines; one pair is used for data receipt, the other pair for transmission. The transmission conductors are denoted by symbols Tx+ and Tx-; the receipt pair are denoted Rx+ and Rx-. In the idle mode, the + wire’s potential is more positive than the – wire. Impedance terminations are connected to the line endpoints. An RS422 line can have branches; in this case, transmitters must be disconnected –mode Multimaster must be set according Table 1.POSSIBLE PROBLEMS DURING INSTALLATIONRecognising RxTx+ and RxTx- conductors:In the idle mode of an RS485 (RS422) line, the RxTx+ conductor's potential is more positive than that of RxTx-. Before measuring, we must ensure that the equipment at the other endpoint is a transmitter and either idle or sending data with a very low frequency of occurrence. If the polarity of the RxTx+ and RxTx- conductors is correct, the yellow RxD indicator must be on when data is transmitted (test it when the control signal is off and the "positive control signal during transmission" option is set).Even thought the power supply is switched on, the green indicator is off: Make sure that power supply is on, the power supply voltage is accordant with converter installing option and polarity is not reversed.The RxD remains on even if no data is being transmitted:There may be several causes of this defect:–The RxTx+ and RxTx- conductors of the RS485 line may be mutually interchanged.–An impedance termination on the receiver side is connected, but there are no resistors which would define the line's idle mode.The impedance termination is connected to the module. On the opposite side, resistors –are connected which define the line's idle mode. However, the line or one of its wires is broken.Data transmission in industry, line and protocol conversions, RS232/485/422/USB/Ethernet/GPRS/ WiFi, measurement modules, intelligenttemperature sensors, I/O modules, and custom-made electronic applications.Address:Strasnicka 3164110 00 Prague 10Czech RepublicTel:+420 267 314 267Fax:+420 267 314 269Internet:E-mail:****************。
捷瑞2102G 无源光电隔离接口转换器使用说明说明书

JaRa® MODEL 2102GRS232<->RS485 无源光电隔离接口转换器使用说明概述:MODEL 2102G是RS-232与RS-485之间的防静电防浪涌双向接口转换器。
直接插在计算机串口上使用。
简单的两线通讯,可以架构RS485半双工点到点及点到多点通信网络。
在以下系统中有广泛的应用:◆工控自动化系统 ◆PLC和PLD ◆监视智能化系统◆POS刷卡机、收款机系统 ◆数据采集、控制系统等MODEL 2102G能够将RS-232串行口的TXD和RXD信号转换成两线平衡的半双工RS-485信号。
无需外接电源,可直接从RS232端口的3脚窃电,同时由7脚(请求发送RTS)、4脚(数据终端准备好DTR)给MODEL 2102G辅助供电,自动的流控使你不必重新设置硬件与安装软件,使用非常简单。
MODEL 2102G内部有光电隔离芯片,可消除因两端设备不稳定的电压引起的“地环流”,保护两端设备的串口不被“地环流”产生的大电流损坏!性能参数:串口界面 接口兼容EIA/TIA的RS232C、RS485标准传输介质 普通双绞线传输距离 1.2Km(可达到19.2 Kpbs)电源要求 串口供电/外部供电光电隔离 隔离电压连续2500V,瞬间7000V脉冲接头方式 DB9F、DB9M、DB9F(带四位接线端子)信号 RS-232: TxD, RxD, RTS, CTS, DTR, DSR, DCD, GNDRS-485:Date+/A,Date-/B, GND工作方式 异步半双工通信协议 透明工作温度 -10℃~70℃相对湿度 5%~95%连接器和信号:MODEL 2102G采用DB9F与RS232设备相连,另一端采用DB9M与RS485设备相连。
接口定义如下:RS232C引脚定义DB9F 1 2 3 4 5 6 7 8 RS232C DCD RXD TXD DTR GND DSR RTS CTSRS485引脚定义DB9M 1 2 3 4 5 6RS485 Date+/A Date-/B GND +5v 其工作电源获得有两种情况: 直接由RS232端口的3脚供电,同时7(RTS)、4(DTR)脚给MODEL 2102G辅助供电; 当RS232不能正常供电时,可由RS485端的DB9M 6脚(+5v)和5脚(GND)供电。
RS485-RS232-RS422通信协议

泰安思科赛德电子科技有限公司RS485 通讯协议RS-232与RS-422之间转换原理和接法通常我们对于视频服务器、录像机、切换台等直接播出、切换控制主要使用串口进行,主要使用到RS-232、RS-422与RS-485三种接口控制。
下面就串口的接口标准以及使用和外部插件和电缆进行探讨。
RS485 通讯协议RS-232、RS-422与RS-485标准只对接口的电气特性做出规定,而不涉及接插件、电缆或协议,在此基础上用户可以建立自己的高层通信协议。
例如:视频服务器都带有多个RS422串行通讯接口,每个接口均可通过RS422通讯线由外部计算机控制实现记录与播放。
视频服务器除提供各种控制硬件接口外,还提供协议接口,如RS422接口除支持RS422的Profile协议外,还支持Louth、Odetics、BVW等通过RS422控制的协议。
RS-232、RS-422与RS-485都是串行数据接口标准,都是由电子工业协会(EIA)制订并发布的,RS-232在1962年发布。
RS-422由RS-232发展而来,为改进RS-232通信距离短、速率低的缺点,RS-422定义了一种平衡通信接口,将传输速率提高到10Mbps,传输距离延长到4000英尺(速率低于100Kbps时),并允许在一条平衡总线上连接最多10个接收器。
RS-422是一种单机发送、多机接收的单向、平衡传输规范,被命名为TIA/EIA-422-A 标准。
为扩展应用范围,EIA又于1983年在RS-422基础上制定了RS-485标准,增加了多点、双向通信能力,即允许多个发送器连接到同一条总线上,同时增加了发送器的驱动能力和突保护特性,扩展了总线共模范围,后命名为TIA/EIA485-A标准。
RS485 通讯协议1. RS-232串行接口标准目前RS-232是PC机与通信工业中应用最广泛的一种串行接口。
RS-232被定义为一种在低速率串行通讯中增加通讯距离的单端标准。
RS232 通讯原理

RS232 通讯原理 ? RS485通讯原理?RS422 是什么?RS485接线的正确原理图常见的RS485错误接线RS-232是串行数据接口标准,最初都是由电子工业协会(EIA)制订并发布的,RS-232在1962年发布,命名为EIA-232-E,作为工业标准,以保证不同厂家产品之间的兼容。
RS-422由RS-232发展而来,它是为弥补RS-232之不足而提出的。
为改进RS-232通信距离短、速率低的缺点,RS-422定义了一种平衡通信接口,将传输速率提高到10Mb/s,传输距离延长到4000英尺(速率低于100kb/s时),并允许在一条平衡总线上连接最多10个接收器。
RS-422是一种单机发送、多机接收的单向、平衡传输规范,被命名为TIA/EIA-422-A标准。
为扩展应用范围,EIA又于1983年在RS-422基础上制定了RS-485标准,增加了多点、双向通信能力,即允许多个发送器连接到同一条总线上,同时增加了发送器的驱动能力和冲突保护特性,扩展了总线共模范围,后命名为TIA/EIA-485-A标准。
由于EIA提出的建议标准都是以“RS”作为前缀,所以在通讯工业领域,仍然习惯将上述标准以RS作前缀称谓。
备注:以上是官方的专业描述,看不懂没有关系,大致有个印象就可以了,有兴趣的可以上网可以买一些专业书籍做深入研究,我再用通俗的语言补充描述一下RS232通讯的基础知识:RS232通讯又叫串口通讯方式。
是指计算机通过RS232国际标准协议用串口连接线和单台设备(控制器)进行通讯的方式。
通讯距离:9600波特率下建议在13米以内。
通讯速率(波特率 Baud Rate ):缺省常用的是 9600 bps ,常见的还有 1200 2400 4800 19200 38400等。
波特率越大,传输速度越快,但稳定的传输距离越短,抗干扰能力越差。
备注:一般台式机会自带1-2个串口插座(公头 (9针插头上带针的俗称公头,带针孔的俗称母头)),现在的笔记本一般不带串口插座,可以购买 USB 串口转换器,具体请参考 怎样使用USB 串口转换器?公头 接线端子排序图母头 接线端子排序图一般只用 2 3 5 号三根线。
RS232与RS485串行接口转换电路及其编程实现(1)

第8卷第1期实验科学与技术·69·RS232与RS485串行接口转换电路及其编程实现胡玮,魏伟(华中科技大学电气学院.武汉430074)摘要:文章给出了一种通用RS232一RS485串口通信转换器的硬件结构和程序实现。
介绍了该转换器在电路测试技术课程电子实验报告中的应用实例。
关键词:电子实验报告;串口通信;转换器;MAX232芯片;MAX485芯片中图分类号:TP311:TM930文献标识码:B文章编号:1672—4550(2010)01—0069—03RS232toRS485SerialInterfaceConversionCircuitanditsProgrammeHUWei,WEIWei(CdlegeofElectrical&ElectronicEngineedng。
HuazhongUniversityofScieneandTechnology,Wuhan430074,China)Abstract:llfispaperpresentedusedRS232-RS485serialinterfaceconversioncircuitanditsprogrmme.Inaddition,thewholeconfigurationofelectronicalexperimentreportsforcircuitmeoryexperimentWaSalsogiveninthepaper.Keywords:ehctronicalexperimentreports;serialcommunication;conveyor;MAX232;MAX4851引言本文介绍的电路测试技术电子实验报告是电工实验台综合软件,该软件选用华中科技大学编著的电工基础实验讲义,制作了9个实验内容:2个直流实验,3个交流实验,4个动态实验。
每个实验相对于一个独立的实验界面,这个实验界面运用软件平台制作完成。
通过使用该软件,学生可以在课堂上完成实验的同时完成实验报告,并在网络打印机上打印出来。
rs232和485串口GPRS DTU说明书

具有RS232和RS485两种接口,实现串口转GPRS透明传输;
四频:GSM850/900,DCS1800/1900,全球通用;
支持GSM/GPRS/EDGE网络;支持2G/3G/4G手机卡的2G流量;
支持2个网络连接同时在线,支持TCP和UDP;
每路连接支持4KB数据缓存,连接异常时可选择缓存数据不丢失;
3.8
USR-GPRS232-730支持通过串口进行升级,升级串口预留在PCB上,需要客户将外壳拆下,使用USB转TTL进行连接。接线孔从左到右依次是GND,RXD,TXD。
接下来使用我们提供专用的升级软件进行升级,首先要点击设置后加载固件
然后选择下载的串口号
然后返回主页点击全部开始即可
等待进度条到达最后升级完成。
本模块支持两路socket连接,分别为socket A和socket B,它们是相互独立的。USR-GPRS232-730支持仅支持作为TCP Client和UDP Client。
3.1.2
3.1.2.1
在此模式下,用户的串口设备,可以通过本模块发送请求数据到指定的HTTP服务器,然后模块接收来自HTTP服务器的数据,对数据进行解析并将结果发至串口设备。
3.设备接收到“OK”后,知道模块已回到之前的工作模式。
4.1.2.
串口AT指令是指工作在透传模式下,我们不需要切换到指令模式,可以使用密码加AT指令方法去查询和设置参数的方法。
4.1.3.
网络AT指令是指工作在透传模式下,通过网络发送密码加AT指令的方式去设置和查询参数。
4.1.4.
短信AT指令是指,我们可以使用短信的方式去查询和配置模块的参数。可以方便的远程设置模块的运行参数,为维护提供了便捷。
CS101C智能CAN转RS232、485、422说明书
CS101C 智能CAN通讯转换模块说明书功能概述1. 连接RS232 / RS485 / RS422 和CAN网络,延长通讯距离,扩展总线节点数。
2. 适合于CANBUS的小流量数据传输,最高可达400幀/秒的传输速率。
3. 集成1个独立的CAN口,一个RS232或RS485或RS422接口。
4. 可应用于CANBUS实验室,工业控制,智能楼宇等领域。
5. 通过串行电缆与PC机或其他设备进行连接,是便携式用户的最佳选择。
性能和技术指标1. 传输方式:标准RS232/RS485和CAN2.0B规范(PeliCAN),兼容CAN2.0A,接口规范符合ISO/IS 11898。
2. 网络拓扑结构:线型,星型,树型。
3. 传输速率: RS232/RS485/RS422:1200~57600 BPSCAN:5K~1M BPS4. 传输介质:屏蔽或非屏蔽双绞线。
5. 通讯接口:CAN总线接口为光电隔离,隔离电压≥1000V。
6. 最大总线长度及总线上的节点数:RS232:点到点通讯,最长通讯距离70米。
RS485:双绞线网络通讯方式,总线上最多可接32个节点,最长通讯距离1200米。
RS422:四线制网络通讯方式,总线上最多可接32个节点,最长通讯距离1200米。
CAN:双绞线网络通讯方式,总线上最多可接110个节点,最长通讯距离10公里。
RS串口最快每秒钟可收发400幀CAN总线数据。
7. 外形尺寸: 100mm×70mm×20mm8. 使用环境:工作温度:0ºC-70ºC相对湿度:40%-60%RH存储温度:-55ºC-+85ºC9. 供电电压: DC10V~30V宽压输入(功耗≤0.6W)。
10. 典型应用: 不同网络设备互连、网络的升级和扩展。
使用说明1. 接口定义:RS232通讯接口:三线制,RXD 、TXD 、GND 。
RS422通讯接口:四线制,RX+、TX+、RX-、TX- 。
5种RS485切换方向的方法及优劣势分析
RS485作为常见的总线之一,几乎每个工控设备都在用,我们也对其熟悉不过了。
我们都知道RS485双半双工通信,其CPU内部的根源是串口通信,串口通信是区分发送TX和接收RX的,在同一对差分信号线上同时传输TX、RX,就是进行方向的控制,方向的控制时机不对,数据传送是要出问题的。
例如下图1、图2中,CPU端的TX信号发送完毕后约100uS后方向引脚拉低,切换到接收状态,但是在TX信号发送完毕后60uS从机就回复了的RX信号,由于此时还是处于RS485芯片还是处于发送状态,此时的接收数据将会被忽略,在系统层面就是体现为数据接收丢包。
图1 RS485 接口电路有些读者会可能回想,只要从机回复数据晚一些,不要这么快速回复,就不存在这个问题了。
但是从机一般都是客户的机器,我们几乎不可能要求别人更改回复时间。
例如三菱的Fx3U PLC作为从机时,从主机发送数据结束到从机回复数据,只用了60uS,部分控制板,甚至回复时间在10uS以内。
研究RS485的方向切换的目标就是:RS485总线空闲时要处于接收状态,如果有主机发送数据,则置高方向引脚,发送完成及时切换到接收状态。
图2 方向脚切换时间过长的情形一、RS485方向切换的方案1:使用反相器自动切换大部分的低成本RS232-RS485转换器采用了这种方法。
具体的实现方法是:把串口的发送信号TX作为反相器的输入,反相器的输出则用来控制RS485收发器的收发控制引脚,同时在RS485收发器的A/B输出端加上上拉/下拉电阻,具体电路如图3所示。
图3 使用反相器自动切换电路在空闲状态下,串口的发送信号TXD为高电平,经过反相器后输出低电平,使485芯片处于接收状态,而RS485总线由于上下拉电阻的作用处于A高B低的状态。
当发送数据时,TXD信号线上的低电平比特位控制485芯片进入发送状态,将该比特发送出去。
而高电平比特位则使485芯片处于接收状态,由于RS485总线上下拉电阻把总线置于A高B低的状态,即表示发送了高电平。
RS232&RS422&RS485接口介绍
RS-232、RS-422与RS-485标准及应用问题一、RS-232、RS-422与RS-485的由来RS-232、RS-422与RS-485都是串行数据接口标准,都是由电子工业协会EIA(Electronic Industry Association)制订并发布的。
RS是英文“推荐标准”的缩写,在通讯工业领域,习惯将上述标准以RS作前缀称谓。
RS-232在1962年发布,命名为EIA-232-E,作为工业标准,以保证不同厂家产品之间的兼容。
RS-422由RS-232发展而来,它是为弥补RS-232之不足而提出的。
为改进RS-232通信距离短、速率低的缺点,RS-422定义了一种平衡通信接口,将传输速率提高到10Mb/s,传输距离延长到4000英尺(速率低于100kb/s时),并允许在一条平衡总线上连接最多10个接收器。
RS-422是一种单机发送、多机接收的单向、平衡传输规范,被命名为TIA/EIA-422-A 标准。
为扩展应用范围,EIA又于1983年在RS-422基础上制定了RS-485标准,增加了多点、双向通信能力,即允许多个发送器连接到同一条总线上,同时增加了发送器的驱动能力和冲突保护特性,扩展了总线共模范围,后命名为TIA/EIA-485-A标准。
二、各串行接口标准1.RS-232-C,232为标识号,C表示修改次数。
RS-232-C总线标准设有25条信号线,包括一个主通道和一个辅助通道,在多数情况下主要使用主通道,对于一般双工通信,仅需几条信号线就可实现,如一条发送线、一条接收线及一条地线。
RS-232-C标准规定的数据传输速率为每秒50、75、100、150、300、600、1200、2400、4800、9600、19200波特。
RS-232-C 标准规定,驱动器允许有2500pF的电容负载,通信距离将受此电容限制,例如,采用150pF/m 的通信电缆时,最大通信距离为15m;若每米电缆的电容量减小,通信距离可以增加。
RS232和RS485通讯介绍
RS232和RS485通讯介绍1、什么是RS-232-C接口?采用RS-232-C接口有何特点?传输电缆长度如何考虑?计算机与计算机或计算机与终端之间的数据传送可以采用串行通讯和并行通讯二种方式。
由于串行通讯方式具有使用线路少、成本低,特别是在远程传输时,避免了多条线路特性的不一致而被广泛采用。
在串行通讯时,要求通讯双方都采用一个标准接口,使不同的设备可以方便地连接起来进行通讯。
RS-232-C接口(又称EIA RS-232-C)是目前最常用的一种串行通讯接口。
它是在1970年由美国电子工业协会(EIA)联合贝尔系统、调制解调器厂家及计算机终端生产厂家共同制定的用于串行通讯的标准。
它的全名是“数据终端设备(DTE)和数据通讯设备(DCE)之间串行二进制数据交换接口技术标准”该标准规定采用一个25个脚的DB25连接器,对连接器的每个引脚的信号内容加以规定,还对各种信号的电平加以规定。
1)接口的信号内容实际上RS-232-C的25条引线中有许多是很少使用的,在计算机与终端通讯中一般只使用3-9条引线。
RS-232-C最常用的9条引线的信号内容见附表2)接口的电气特性在RS-232-C中任何一条信号线的电压均为负逻辑关系。
即:逻辑“1”,-5— -15V;逻辑“0” +5— +15V 。
噪声容限为2V。
即要求接收器能识别低至+3V的信号作为逻辑“0”,高到-3V的信号作为逻辑“1”附表1 引脚序号信号名称符号流向功能2 发送数据TXD DTE→DCE DTE 发送串行数据3 接收数据RXD DTE←DCE DTE 接收串行数据4 请求发送RTS DTE→DCE DTE 请求DCE将线路切换到发送方式5 允许发送CTS DTE←DCE DCE告诉DTE线路已接通可以发送数据6 数据设备准备好DSR DTE←DCE DCE准备好7 信号地信号公共地8 载波检测DCD DTE←DCE 表示DCE接收到远程载波20 数据终端准备好DTR DTE→DCE DTE准备好22 振铃指示RI DTE←DCE 表示DCE与线路接通,出现振铃3) 接口的物理结构RS-232-C接口连接器一般使用型号为DB-25的25芯插头座,通常插头在DCE端,插座在DTE端. 一些设备与PC机连接的RS-232-C接口,因为不使用对方的传送控制信号,只需三条接口线,即“发送数据”、“接收数据”和“信号地”。
- 1、下载文档前请自行甄别文档内容的完整性,平台不提供额外的编辑、内容补充、找答案等附加服务。
- 2、"仅部分预览"的文档,不可在线预览部分如存在完整性等问题,可反馈申请退款(可完整预览的文档不适用该条件!)。
- 3、如文档侵犯您的权益,请联系客服反馈,我们会尽快为您处理(人工客服工作时间:9:00-18:30)。
RS232与RS485的转换方法
有三种方法可以使用。
1:简单的转换方式。
2:接收端缓冲存储器控制转换方式。
3:接收端缓冲存储器加RTS 信号控制转换方式。
松下电器公司CCVE 产品两线连接的RS485控制方式只能采用(2)或(3)方式。
不能用第1种方式。
四线连接方式可以任意使用以上3种方式转换。
图2表示第2种转换方式。
其中(a )是接收缓冲存储器接收控制端。
当PC 机发送 数据时,(a )控制端可以避免RS485产生数据冲突。
图3表示第3种转换方式。
图中(b )是RTS 控制端,当PC 机接受数据时,RTS 信号被机活因此PC 机发送数据被延迟。
总之,通过(a )和(b )信号的控制,可以避免数据在发送和接受时发生冲突。
图1:简单转换方式:
图2:接收端缓冲存储器控制方式。
图3:接收端缓冲存储器加RTS 信号控制转换方式。
摄象机端 PC 机端
摄象机端 PC 机端 摄象机端 PC 机端。