当前位置:网站首页>USB to RS485 serial port circuit design "suggestions collection"
USB to RS485 serial port circuit design "suggestions collection"
2022-06-29 10:53:00 【Full stack programmer webmaster】
Hello everyone , I meet you again , I'm your friend, Quan Jun .
USB The serial port signal of the serial port chip is generally TTL/CMOS level , In half duplex RS485 External connection is required for serial port 485 Level conversion chip , Design A signal is required to control 485 Transmit and receive enable end of the transfer chip , It is recommended to choose to bring 485 Switching chip of control pin ( Such as CH340/CH342 Series of chips TNOW Pin ), This pin defaults to low level , When the serial port is in the sending state, it will be automatically raised to be in the effective state , The transmission is completed and then the low level is restored . Empathy , It can be extended to other application scenarios , Such as MCU serial port to 485 Can be used in circuit design GPIO Mouth to control 485 Transmit and receive enable of the transfer chip .
With MAX485 For example :
1. DE Enable... For sending ,RE Enable... For reception ,DI by TTL/CMOS Serial transmission ,RO by TTL/CMOS A serial port to receive .
2. TNOW Control signal pins are connected at the same time DE and RE; In the serial port sending state ,TNOW Output high level , open DE Receive enable ; When the serial port does not send ,TNOW Output low level , The default RE Receive enable ;
common problem Q&A
Q: The serial port often receives 0x00 Bit error value ?
A: In the receive enable state , commonly 485 Of A and B The signal terminal is in high resistance state , In the process of transmitting and receiving A and B The signal remains , Did not return to idle state . Lead to RO End sampling error . here , stay A Terminate a pull-up resistor ,B Terminate a pull-down resistor , The resistance value shall be calculated according to the manual and practical application .
Q:AB Whether the terminal needs parallel terminal matching resistance ?
A: According to the manual , At present, many chips are built-in 120 Ohm matching resistance , It's not a mandatory option .
Q: How to calculate the number of cascade devices ?
A: It shall be determined according to the received input impedance marked in the manual , Generally, the maximum number of transceivers allowed will also be directly marked .
Application circuit 1
The following figure shows the use of the built-in TNOW Pin 485 Control signal USB Switch to dual serial chip CH342F Designed two-way RS485 Serial port circuit :
notes :CH342F Of DTR When the pin is connected to the pull-down resistor, it will switch to TNOW Pin , Used in the above figure is 4.7K.
Application circuit 2
If the selected model does not 485 Control signals , Use only TXD and RXD Two signal lines 485 The need for circuit switching is also very common . The following is the schematic diagram :
Realization principle : take RE Keep setting 0, Enable receive enable (RE And DE Direct short connection is also possible ), take TXD Reverse post connect send enable end DE.TXD The output is high , Connected 485 The chip send enable is invalid , The bus output is idle ( High level ),TXD Output low level , Send enable is valid . Compared to the application 1, Because there is a triode reverse circuit , The signal output control will have a delay , It is not recommended to use in high baud rate communication .
The above conversion circuit and design principle are in 485 High frequency is used in the conversion circuit , Users can flexibly select according to their needs .
Publisher : Full stack programmer stack length , Reprint please indicate the source :https://javaforall.cn/132437.html Link to the original text :https://javaforall.cn
边栏推荐
- 嵌入式学习书籍推荐[通俗易懂]
- 深入浅出总结Flink运行时架构
- UserWarning: Usage of dash-separated ‘script-dir‘ will not be supported in future versions. 笔记
- Daily question brushing record (VII)
- 最后的 48 小时!云 XR 专题赛邀你一起绽放精彩,我们赛场见!
- SQL Server 数据库的连接查询
- Dormitory maintenance management system based on stm32+rfid design
- Xiaomi mobile phone - Unlock BL + open root permission
- Analysis of reentrantlock source code of AQS
- zabbix监控mysql各项指标
猜你喜欢

Qt编写物联网管理平台37-逻辑设计

SQL Server 数据库的几种简单查询

STM32F1与STM32CubeIDE编程实例-超声波测距传感器驱动

Daily question brushing record (VII)

SQL Server 数据库的连接查询

【Rust每周一库】Tokei - 统计代码行数等信息的实用工具

在Clion中使用EasyX配置

学习通否认 QQ 号被盗与其有关:已报案;iPhone 14 量产工作就绪:四款齐发;简洁优雅的软件早已是明日黄花|极客头条...

UserWarning: Usage of dash-separated ‘script-dir‘ will not be supported in future versions. note

Atomic explanation of AQS
随机推荐
Agctfb partial solution
容器平台性能如何测试,稳定性、扩展效率、组件性能
PyTorch学习笔记(6)——DataLoader源代码剖析
Ikvm Net project progress
【Rust每周一库】Tokei - 统计代码行数等信息的实用工具
全面理解Volatile关键字
SQL Server 数据库的连接查询
(JS)isNaN()方法判断undefined为true的原因
The use and difference of watch listening and computed calculation attributes
Stm32f1 and stm32subeide programming example - ultrasonic distance sensor drive
认不出原来的模样
SQL Server 数据库的统计查询
给定两个整形变量的值,将两个值的内容进行交换 (C语言)
With this tool, automatic identification and verification code is no longer a problem
SQL Server 数据库增删改查语句
免费送书啦!畅销书《 OpenCV图像处理入门与实践》一本全搞定
Alibaba cloud server is installed and configured with redis. Remote access is unavailable
励志!专科“逆袭”读浙大硕士,3篇SCI,最终成清华博士!
Does your project need automated testing?
Excel日期及数字格式处理