Skip to content

Commit 128817b

Browse files
Bump dvg-qdeviceio==0.2.0
1 parent d0896a4 commit 128817b

File tree

2 files changed

+10
-11
lines changed

2 files changed

+10
-11
lines changed

Arduino_PyQt_demo_with_multithreading.py

Lines changed: 9 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@
66
__author__ = "Dennis van Gils"
77
__authoremail__ = "vangils.dennis@gmail.com"
88
__url__ = "https://github.com/Dennis-van-Gils/DvG_Arduino_PyQt_multithread_demo"
9-
__date__ = "02-07-2020"
10-
__version__ = "3.0"
9+
__date__ = "07-07-2020"
10+
__version__ = "3.1"
1111

1212
import os
1313
import sys
@@ -29,15 +29,15 @@
2929

3030
from dvg_devices.Arduino_protocol_serial import Arduino # I.e. the `device`
3131

32-
#from dvg_devices.Arduino_qdev import Arduino_qdev # Alternative approach as subclassed QDeviceIO()
32+
# from dvg_devices.Arduino_qdev import Arduino_qdev # Alternative approach as subclassed QDeviceIO()
3333
from dvg_qdeviceio import QDeviceIO
3434

3535

3636
# Constants
3737
# fmt: off
38-
DAQ_INTERVAL_MS = 10 # 10 [ms]
39-
DRAW_INTERVAL_CHART = 10 # 10 [ms]
40-
CHART_HISTORY_TIME = 10 # 10 [s]
38+
DAQ_INTERVAL_MS = 10 # 10 [ms]
39+
CHART_INTERVAL_MS = 10 # 10 [ms]
40+
CHART_HISTORY_TIME = 10 # 10 [s]
4141

4242
# Global variables for date-time keeping
4343
cur_date_time = QDateTime.currentDateTime()
@@ -298,8 +298,7 @@ def update_chart():
298298
if DEBUG:
299299
dprint(
300300
" update_curve done in %.2f ms"
301-
% (time.perf_counter() - tick)
302-
* 1000
301+
% ((time.perf_counter() - tick) * 1000)
303302
)
304303

305304

@@ -322,7 +321,7 @@ def stop_running():
322321
def notify_connection_lost():
323322
stop_running()
324323

325-
excl = " ! ! ! ! ! ! ! ! "
324+
excl = " ! ! ! ! ! ! ! "
326325
window.qlbl_title.setText("%sLOST CONNECTION%s" % (excl, excl))
327326

328327
str_msg = (
@@ -509,7 +508,7 @@ def DAQ_function():
509508

510509
timer_chart = QtCore.QTimer()
511510
timer_chart.timeout.connect(update_chart)
512-
timer_chart.start(DRAW_INTERVAL_CHART)
511+
timer_chart.start(CHART_INTERVAL_MS)
513512

514513
# --------------------------------------------------------------------------
515514
# Start the main GUI event loop

requirements.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,5 +5,5 @@ pyqt5~=5.12
55
pyqtgraph~=0.10
66

77
dvg-debug-functions~=2.0
8-
dvg-qdeviceio~=0.1.2
8+
dvg-qdeviceio~=0.2.0
99
dvg-devices~=0.0.4

0 commit comments

Comments
 (0)