From 417965a1115fc1c7c212b9243e8787a111c33dde Mon Sep 17 00:00:00 2001 From: zhangsheng Date: Tue, 3 Jun 2025 12:42:15 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E9=80=9F=E5=BA=A6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- SamplingDialog.py | 3 ++- mainwindow.py | 1 + 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/SamplingDialog.py b/SamplingDialog.py index 4e16bf9..33ccc61 100644 --- a/SamplingDialog.py +++ b/SamplingDialog.py @@ -292,6 +292,7 @@ class CalibrationDialog(QDialog): self.setWindowTitle("校准设置") self.socket = socket self.type_index = 0 + self.setFixedWidth(300) # 通道与类型选择 self.partial_data = QByteArray() self.recv_state = '' @@ -594,7 +595,7 @@ class CalibrationDialog(QDialog): print(f"top10_min 去除最大的数据后的平均值2:{mean_min}") pp = mean_max - mean_min if self.type_cb.currentIndex() == 2: - self.value_labels[self.type_index].setText(str(round(pp,3))) + self.value_labels[self.type_index].setText(str(round(pp,6))) print(f"pp :{mean_max - mean_min}") def closeEvent(self, event): diff --git a/mainwindow.py b/mainwindow.py index d685f81..8f1fc3f 100644 --- a/mainwindow.py +++ b/mainwindow.py @@ -466,6 +466,7 @@ class SocketClientApp(QMainWindow): execution_time = end_time - self.start_time print(f"结束时间戳: {end_time}") print(f"代码执行时间: {execution_time} 秒") + print(f"speed :{round((self.sampling_rate * 4 * 8) / execution_time,3)} Kbps") self.process_wave_packet(bytes(self.partial_data)) self.recv_state = 'WAIT_HEADER' self.partial_data.clear()