Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

默认fromHex()脚本,会吞掉显示界面HEX格式的部分ASCII字符0x20,0x0D,0x0A等 #159

Closed
2 tasks done
qq19538 opened this issue Mar 13, 2024 · 4 comments
Closed
2 tasks done

Comments

@qq19538
Copy link

qq19538 commented Mar 13, 2024

描述一下这个bug / Describe the bug

image
显示界面,把0x20 以及0x0A都吞掉了,猜测应该是ASCII中0x20表示空格,0x0A表示换行,HEX显示时,显示界面程序没有把字符做替换。

复现步骤 / To Reproduce

更改编码格式不能避免这个显示吞字符的问题。

预期的行为 / Expected behavior

image
实际LOG是这样的

截图 / Screenshots

No response

日志 / Logs

No response

系统 / System

WIN10

软件版本 / Version

1.1.3.3

验证

  • 检查该问题是否已被提过 / Check that there isn't already an issue that reports the same bug to avoid creating a duplicate.
  • 提供了最小可复现工程或详细的复现步骤,确保开发者可以复现 / The provided reproduction is a minimal reproducible example of the bug.
@LuaRobot
Copy link

⚠ 你的Issue可能缺少了一些信息,请自觉补全,以证明issue内容的真实性:

⚠ Your issue may be missing some information, please complete it to prove the authenticity of the content of the issue:

  • ❌未提供复现所需的代码或工程 does not provide codes or project for reproduction
  • ❌未提供出错时需要的日志文件 does not provide logs when bug happening

@qq19538
Copy link
Author

qq19538 commented Mar 13, 2024

log20240313.txt
日志文件如上

@qq19538
Copy link
Author

qq19538 commented Mar 13, 2024

image
image
验证出问题在哪里,默认的脚本使用了fromHex()函数,这个函数应该会替换0x20以及0x0A这类的ASCII码。

@qq19538 qq19538 changed the title 确认是显示界面吞HEX格式字符了 默认fromHex()脚本,会吞掉显示界面HEX格式的部分ASCII字符0x20,0x0D,0x0A等 Mar 13, 2024
@chenxuuu
Copy link
Owner

软件默认脚本不会有任何处理:
https://github.com/chenxuuu/llcom/blob/master/llcom/DefaultFiles/user_script_recv_convert/default.lua
https://github.com/chenxuuu/llcom/blob/master/llcom/Model/Settings.cs#L29

fromhex不要乱用,这是用来把hex转成bin的函数

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants