Guidelines for Troubleshooting Serial Communication Issues

2023-06-29 usr News

When we are engaged in the development of embedded projects, we often encounter a variety of serial communication problems. According to the previous debugging and development experience, this paper summarizes a serial communication troubleshooting guide, hoping to provide some troubleshooting directions and methods for engineers who often use Serial to Ethernet Device Server.


Serial communication is a kind of communication mode that transmits data by bit between peripherals and computers, or between peripherals and peripherals through data signal lines, ground lines, etc. The communication format of this communication mode includes a start bit, data bit, check bit and stop bit, as shown in the following figure. Serial communication is characterized by low cost but slow transmission speed.The distance of serial communication can be from several meters to several kilometers.



After a brief introduction to serial communication, let's get down to business. The direction for us to troubleshoot serial communication problems is basically as follows, as shown in the figure.



1. Check the middleware

There must be a sending end and a receiving end in serial communication, and both of them pass through middleware (such as wires). In case of problems, the first thing is to ensure that the wires are connected normally. If this part is not determined and other directions are directly investigated, it is likely to do useless work.


2. Troubleshoot the hardware layer

The logic analyzer, oscilloscope, and other instruments are used to judge whether the pin waveforms of the sending end and the receiving end are normal during sending, receiving, and idling. When the serial port is idle, it is high level, and there will be a level change when there is data. It is also necessary to determine whether the voltage is normal. The position of waveform measurement starts from the endpoint, and then the detection points in the middle part are checked in turn to determine the location of the problem.


If waveform deformation, distortion, abnormal voltage, and other conditions are found, please ask the hardware engineer to assist in troubleshooting. The waveform is visible at its start point, but not at its endpoint, and a multimeter is required to determine if there is a cold solder joint on the pin.


3. Check the serial driver layer

If there is no problem after checking the hardware, but there is no waveform in the serial port of the sending end, it is necessary to check whether the serial port driver is configured successfully. The Tx and Rx pins at the transmitting end can be short-circuited for loopback tests. It is better to test with a simple routine first and try to eliminate the influence of multiple variables. When troubleshooting, special attention should be paid not only to the logic of the code, but also to the actual debugging, and be good at using the software debugging window to observe the values of the relevant registers.



4. Application protocol layer

Through the investigation of the above directions, it can be proved that there is no problem with spontaneous receipt. The next step is to verify whether the two sides can communicate normally. Possible problems at the application protocol layer include:


① There is a problem with the data protocol between the sending end and the receiving end, such as CRC, frame header and trailer check, and parsing of data packets.

② The serial port configuration parameters of the sending end and the receiving end: the baud rate and the check bit are inconsistent, resulting in the failure of communication.


We also need to pay attention to the following points:

① As the signal is easy to be interfered with, it is recommended to use a shielded wire, and the wiring must be strict, and it is better to ground if grounding is needed. For some 485 communication, it is also necessary to consider connecting a terminal resistor to match. If it is RS232 communication, try not to make the line too long.

② Because many devices have errors in the baud rate calculated by the external crystal oscillator or internal clock. In this case, if the message is too long, it will lead to the accumulation of errors, and then the serial identification will be garbled or can not be received.

③ In some places where there may be interference, you can consider using odd parity or even parity, so that you can filter out the wrong messages or try to use some data parity protocols to prevent data errors.


授权代理商:世强先进(深圳)科技股份有限公司
技术资料,数据手册,3D模型库,原理图,PCB封装文件,选型指南来源平台:世强硬创平台www.sekorm.com
现货商城,价格查询,交期查询,订货,现货采购,在线购买,样品申请渠道:世强硬创平台电子商城www.sekorm.com/supply/
概念,方案,设计,选型,BOM优化,FAE技术支持,样品,加工定制,测试,量产供应服务提供:世强硬创平台www.sekorm.com
集成电路,电子元件,电子材料,电气自动化,电机,仪器全品类供应:世强硬创平台www.sekorm.com
  • +1 赞 0
  • 收藏
  • 评论 0

本文由Vicky转载自usr News,原文标题为:Guidelines for troubleshooting serial communication issues,本站所有转载文章系出于传递更多信息之目的,且明确注明来源,不希望被转载的媒体或个人可与我们联系,我们将立即进行删除处理。

相关研发服务和供应服务

评论

   |   

提交评论

全部评论(0

暂无评论

相关推荐

How to Solve the Problem of Serial Port Connection Failure

When using a serial port conversion device such as a Serial to Ethernet Device Server, you may encounter some obstacles. This article sums up part of the experience for engineers to make references when debugging.

2023-06-25 -  技术探讨 代理服务 技术支持 采购服务

What Are the Transparent Transmission Characteristics of Serial to Ethernet Device Server?

The serial to ethernet device server provides the function of converting serial port to network port, which can convert RS232/485/422 serial port to TCP/IP network interface, and maintain bidirectional and transparent transmission of statistical data between RS232/485/422 serial port and TCP/IP network interface.

2023-06-13 -  技术探讨

The Function and Application of Serial to Ethernet Device Server

The serial to Ethernet device server is the core crystallization of the development of science and technology. Because of its wide range of applications, many applications can be involved. In this article PUSR will introduce the function and application of serial to ethernet device server.

2023-06-23 -  技术探讨 代理服务 技术支持 采购服务

PUSR Launched the Building Block Edge Gateway USR-M100, a Comprehensive and Scalable Data Transmission Gateway

PUSR launched the building block edge gateway USR-M100.M100 is a comprehensive and scalable data transmission gateway, which integrates the functions of Ethernet, 4G, transparent transmission, network IO, edge computing, MQTT and cloud platform fast access.

2023-05-13 -  原厂动态 代理服务 技术支持 采购服务
2022.5.30  - 有人物联  - 开发环境(软件/固件)  - V2.0.0 代理服务 技术支持 采购服务

USR-N5x0系列串行到以太网设备服务器用户手册

型号- USR-N520-6,USR-N510-4,USR-N540,USR-N520,USR-N5X0 SERIES,USR-N510,USR-N540-4,USR-N5X0,USR-N580

2022.7.30  - 有人物联  - 用户指南  - V1.0.0 代理服务 技术支持 采购服务

IP Settings and Port Allocation Methods for Serial to Ethernet Device Server

In a word, a Serial to Ethernet Device Server is a necessary network device to realize the Internet of Things communication, remote control, and data acquisition. An excellent Serial to Ethernet Device Server should have industrial-grade, high-performance, and rich expansion functions.

2023-06-22 -  设计经验 代理服务 技术支持 采购服务

有人物联(usr)以太网系列产品选型指南

目录- 公司简介和主营产品概览    串口服务器    Wi-Fi 串口服务器    以太网模块    工业级以太网交换机    数据采集网关系列   

型号- USR-W600,USR-K7,USR-K6,USR-N510,USR-CANET200,USR-TCP232-T2,USR-SDR080,USR-SDR160,USR-SDR041,USR-M511,USR-SDR021,USR-N668,USR-TCP232-ED2,USR-TCP232-E2,USR-N540,USR-N520,USR-N580,USR-W630,USR-W610,USR-TCP232-S2,USR-SDR050,USR-TCP232-306,USR-TCP232-410S,USR-TCP232-304,USR-TCP232-302

2019/6/12  - 有人物联  - 选型指南 代理服务 技术支持 采购服务

有人物联推出IP转换器USR-G807,支持宽压9~36V供电,解决PLC跨网段通讯难题

有人物联推出的IP转换器USR-G807采用钣金外壳、散热更佳,支持宽压9~36V供电,解决PLC终端无法修改IP问题和PLC跨网段通讯难题。该产品可以在不修改原系统的任何软硬件,不影响原系统正常通信,实现PLC的IP地址转换;具备核心NAT功能,可实现LANO设备IP和端口映射到WAN口的任意IP。

2024-12-20 -  产品 代理服务 技术支持 采购服务

【经验】解析串口服务器USR-TCP232-410如何使用485口并联方式与设备通信

本文主要介绍串口服务器USR-TCP232-410使用485口并联方式与设备通信。有人物联410的485口最大支持32个设备,485总线协议标准是200多个,实际连接还需要设备的负载决定。

2023-06-06 -  设计经验 代理服务 技术支持 采购服务

鼎桥CEO莅临有人物联参观交流,深化5G战略合作

在数字化转型浪潮的推动下,物联网技术的融合创新成为推动工业产业升级的关键力量。近日,行业领先的物联网解决方案服务提供商——有人物联,与享誉全球的通信解决方案供应商鼎桥通信技术有限公司,正式签署战略合作框架协议。此次合作不仅标志着双方在5G RedCap工业通信领域达成战略合作,也预示着双方共同推动物联网技术与产业的深度融合的坚定决心。

2024-08-23 -  原厂动态 代理服务 技术支持 采购服务

打破远程运维边界,有人物联异地组网方案彻底解决终端设备无法统一远程管理痛点

现在,只需将这些终端设备连接在有人物联路由器网口下,通过异地组网平台简单配置,就能轻松搭建起一个终端互通的网络。企业总部人员或外出员工借助手机、PC随时随地对终端进行远程调试、下载程序、配置等运维操作,彻底解决终端设备无法统一远程管理的痛点。

2024-12-16 -  产品 代理服务 技术支持 采购服务

有人物联网双网口8串口的串口服务器USR-N580,独特的工业功能支持,支持Modbus网关功能

为了能为客户降低成本和减少布线难度,有人物联网研发出了一款双网口8串口的串口服务器,专门应用于多设备联网的复杂环境。八串口服务器USR-N580,是用来将TCP/UDP数据包与RS485接口实现数据透明传输的设备。 独特的工业功能支持,支持Modbus网关功能,更加方便工业现场使用。 支持网络打印,打印机行业使用更加方便。

2024-06-21 -  产品 代理服务 技术支持 采购服务

【选型】有人物联WiFi6工业无线客户端、小体积5G工业数传终端满足AGV小车联网需求,确保通信稳定

AGV小车要不断移动就要依靠稳定的无线通信网络覆盖,以及快速的AP间漫游切换,保证各工业场景中AGV的高效稳定工作。AGV无线通信组网系统要具备较大带宽,支持实时双向通信,能够承载诸如高清视频、机器人/车辆运行数据、传感器数据、语音及其他网络业务。有人物联新推出的WiFi6工业无线客户端W660和小体积5G工业数传终端G815可助力AGV+物联网推动各行各业数字化转型升级。

2023-09-01 -  器件选型 代理服务 技术支持 采购服务
展开更多

电子商城

查看更多

品牌:有人物联

品类:Wi-Fi 加强版工业路由器

价格:

现货: 0

品牌:有人物联

品类:路由器

价格:

现货: 0

品牌:有人物联

品类:DTU数传终端

价格:¥225.8824

现货: 0

品牌:有人物联

品类:LTE路由器

价格:¥203.5295

现货: 0

品牌:有人物联

品类:Lora模块

价格:¥164.7059

现货: 0

品牌:有人物联

品类:网络IO设备

价格:¥964.7059

现货: 0

品牌:有人物联

品类:串口服务器

价格:¥96.4706

现货: 0

品牌:有人物联

品类:串口服务器

价格:¥91.7648

现货: 0

品牌:有人物联

品类:串口服务器

价格:¥176.4706

现货: 0

品牌:有人物联

品类:LTE路由器

价格:¥441.1765

现货: 0

品牌:

品类:

价格:

现货:

品牌:

品类:

价格:

现货:

品牌:

品类:

价格:

现货:

品牌:

品类:

价格:

现货:

品牌:

品类:

价格:

现货:

品牌:

品类:

价格:

现货:

品牌:

品类:

价格:

现货:

品牌:

品类:

价格:

现货:

品牌:

品类:

价格:

现货:

品牌:

品类:

价格:

现货:

现货市场

查看更多

暂无此商品

海量正品紧缺物料,超低价格,限量库存搜索料号

查看更多

授权代理品牌:接插件及结构件

查看更多

授权代理品牌:部件、组件及配件

查看更多

授权代理品牌:电源及模块

查看更多

授权代理品牌:电子材料

查看更多

授权代理品牌:仪器仪表及测试配组件

查看更多

授权代理品牌:电工工具及材料

查看更多

授权代理品牌:机械电子元件

查看更多

授权代理品牌:加工与定制

世强和原厂的技术专家将在一个工作日内解答,帮助您快速完成研发及采购。
我要提问

954668/400-830-1766(工作日 9:00-18:00)

service@sekorm.com

研发客服
商务客服
服务热线

联系我们

954668/400-830-1766(工作日 9:00-18:00)

service@sekorm.com

投诉与建议

E-mail:claim@sekorm.com

商务合作

E-mail:contact@sekorm.com

收藏
收藏当前页面