迪文科技论坛

 找回密码
 立即注册
搜索
查看: 412|回复: 6

[Question]DWINOS ModBus 485 at 9600 baud is not working well

[复制链接]

5

主题

7

回帖

260

积分

中级会员

Rank: 3Rank: 3

积分
260
发表于 2025-5-12 18:04:01 | 显示全部楼层 |阅读模式
I'm trying to make a small utility for downloading icl and bin via Modbus RTU. But there are 2 problems:
1.) At a speed of 9600 baudrate, the DWIN display seems to send an error code during data transmission. Which makes it even longer for me to wait for the response timeout.
2.) Sometimes at a speed of 9600 baudrate, after writing a 32KBYTE sector of external flash memory, display artifacts appear. Is there any way to check the CRC (even if modbus-CRC is used for data transmission) of these 32K bytes in RAM memory before writing them to external flash memory?


Moreover, at a speed of 115200, everything works stably. The error code is calculated on time and I did not notice any image artifacts.

I'm doing the same as the instructions from the forum: how to upload an icl file. Only by adapting to RTU ModBus.

RAM memory from 0x8000 to 0xBFFF is not used.
I use function code 0x10 for multiple entries of 0x40 registers.
I tried touching the 0xFC register. Neither 0x55AA5A5A nor 0x55AA5AA5 helped.

I use the display model - DMG80480C070_15WTR.
T5L UI - V65.
T5L OS - V22.
The ModBus implementation - DWINOS_DWIN_T5L_9600__UART5_ModBus.

本帖子中包含更多资源

您需要 登录 才可以下载或查看,没有账号?立即注册

x
回复

使用道具 举报

0

主题

928

回帖

8808

积分

论坛元老

Rank: 8Rank: 8

积分
8808
发表于 2025-5-13 09:46:04 | 显示全部楼层
You can first check if the communication is normal when setting the baud rate of 9600
回复

使用道具 举报

5

主题

7

回帖

260

积分

中级会员

Rank: 3Rank: 3

积分
260
 楼主| 发表于 2025-5-14 18:03:15 | 显示全部楼层
I checked the operation of modbus communication at a speed of 9600 baud using a usb-rs485 CH340 adapter and FTDI. Through the modbus master tool utility, it reads and writes registers well (only occasionally reading errors occur).

Sometimes, after applying 0xAA to write to the external memory, artifacts may appear:


No matter how much I tried, artefacts didn't happen at 115200. Only for 9600 baud.

本帖子中包含更多资源

您需要 登录 才可以下载或查看,没有账号?立即注册

x
回复

使用道具 举报

0

主题

452

回帖

3716

积分

论坛元老

Rank: 8Rank: 8

积分
3716
发表于 2025-5-15 17:28:02 | 显示全部楼层
DoMiaN115 发表于 2025-5-14 18:03
I checked the operation of modbus communication at a speed of 9600 baud using a usb-rs485 CH340 adap ...

Check if the bit error rate at 9600 baud rate is too high, affecting communication
回复

使用道具 举报

5

主题

7

回帖

260

积分

中级会员

Rank: 3Rank: 3

积分
260
 楼主| 发表于 2025-5-15 18:39:12 | 显示全部楼层
yuanbin2020 发表于 2025-5-15 17:28
Check if the bit error rate at 9600 baud rate is too high, affecting communication

The error rate is approximately 20 out of 256 modbus function code 0x10 commands on average. Image artefacts.

Image artifacts don't always show up, even after error responses.
回复

使用道具 举报

5

主题

7

回帖

260

积分

中级会员

Rank: 3Rank: 3

积分
260
 楼主| 发表于 2025-6-17 16:36:09 | 显示全部楼层
I also tried 3 more different power adapters: one for 12V and 1.5A, and two for 12V and 1A. The quality of the connection remains the same.

Does anyone have a C or Python implementation for updating files to external flash?
回复

使用道具 举报

0

主题

372

回帖

2477

积分

金牌会员

Rank: 6Rank: 6

积分
2477
发表于 2025-6-17 19:58:22 | 显示全部楼层
You can refer to this upgrade package for upgrading.

本帖子中包含更多资源

您需要 登录 才可以下载或查看,没有账号?立即注册

x
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

QQ|Archiver|手机版|小黑屋|迪文科技论坛 ( 京ICP备05033781号-1 )

GMT+8, 2025-10-18 07:12 , Processed in 0.038169 second(s), 23 queries .

Powered by Discuz! X3.4

© 2001-2023 Discuz! Team.

快速回复 返回顶部 返回列表