提交代码

This commit is contained in:
zhangsheng 2025-05-07 19:46:31 +08:00
parent ee2d142182
commit 020e7fb47e
4 changed files with 10 additions and 2 deletions

View File

@ -95,6 +95,7 @@ void MyTcpClient::onReadyRead() {
} else {
// 2. 根据头部的 len 读取剩余数据
qint64 remainingBytes = m_currentHead.len - (m_buffer.size() - sizeof(PackageHead));
if (remainingBytes <= 0) {
// 数据已经完整,触发信号
emit dataReceived(m_buffer);

View File

@ -290,6 +290,13 @@ typedef struct {
char data[0]; // 文件内容
} PackageHead;
typedef struct {
uint8_t head[3]; // 固定值0xAA55AA
uint8_t cmd;
uint8_t code;
int len;
} CommonRsp;
typedef struct {
uint8_t card_id; // 0xff是本机其它子卡是115
char data[0];

View File

@ -1765,7 +1765,7 @@
<item>
<widget class="QLabel" name="label_standby">
<property name="text">
<string>5-6</string>
<string>--</string>
</property>
</widget>
</item>

View File

@ -11,7 +11,7 @@
</rect>
</property>
<property name="windowTitle">
<string>Form</string>
<string>触发配置</string>
</property>
<widget class="QWidget" name="layoutWidget">
<property name="geometry">