| Age | Commit message (Collapse) | Author |
|
Arduino analog Signal ids used to be the pin name itself, so fixing a
wrong pin silently changed the id and orphaned any plot trace, control,
or filter pipeline pointing at it. Analog Signal ids are now positional
(ai0, ai1, ...) and decoupled from the underlying pin, matching how
digital I/O already worked.
More broadly, formalizes a Device -> Signal -> Channel -> Plot naming
model (SignalConfig for physical device channels, Channel for derived/
computed ones) and adds core/reference_registry.py to propagate any
Signal or Channel id rename through plot traces, controls, and filter
pipelines instead of leaving them dangling. Signal ids are now editable
in the Signals tab with the same propagation.
.labui profile schema bumped to v2.0 with a transparent migration for
old files, including remapping old pin-name Signal ids to the new
positional ones. Removed six confirmed-dead files (two legacy device
classes, four superseded top-level ui/ duplicates).
|
|
ControlWidget._write() called dev.write_channel() directly on the GUI
thread from Qt signal handlers — for CML (CoolMuscle), write() does 2-3
blocking serial round-trips, and a slider fires valueChanged on every drag
tick, so each tick froze the whole app until the device responded or timed
out. Replaced with a coalescing background dispatch: writes are keyed by
(device, channel) in a dict instead of a plain FIFO queue, so re-writing
the same channel while a write is still pending updates its value in place
rather than piling up — a strict FIFO was observed backing up 30+ deep
during a single drag, meaning the motor kept "moving" to seconds-old
positions long after the slider stopped, which looked like a freeze even
once off the GUI thread.
Separately, the motor never actually moved because it was never enabled:
per docs/CM1-C_ASCII_Command_Cheatsheet.md, a CM1-C motor stays disabled
("shaft free") until sent "(", and nothing in CMLLayer.write()'s VS/MA
handling ever sent it — enable only existed as a separate M1_ME channel
the generic MotorControl widget has no concept of. VS/MA now send enable
unconditionally before the move sequence (a no-op if already enabled).
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
|
|
Root cause of "QFont::setPointSize: Point size <= 0 (-1)" on some
dropdowns: the app never sets an explicit widget style, so it defaults to
native windowsvista, whose popup code calls setPointSize() on fonts
resolved from our QSS's pixel-based font-size (pointSize() is -1 by
design for px fonts). Tried app.setStyle("Fusion") first — silences it,
but Fusion doesn't render buttons/dropdowns to match the QSS the way the
native style does. Kept native style, filtered just that one message via
qInstallMessageHandler instead — it's cosmetic Qt console noise (the
rejected setPointSize call is a no-op, doesn't affect rendering), not a
real bug.
Also adds a handful of tooltips (Control Editor's Check Syntax/Cancel/
Create Control, device Configure dialog's Close, main toolbar's View/
Configure/RUN/LOG/Settings, a few Control Panel widgets) from an
in-progress app-wide tooltip pass, paused partway through by request —
remaining buttons are being done manually.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
|
|
Devices: auto-name from OS-reported port description (Device Manager /
udev string) instead of a generic label; default Serial #Channels 1;
consistent simulate-mode checkbox across backends; inline device rename.
Channels: calibration/filters move out of Signals into a Channel
"Operation" (adds Scale/Offset alongside the existing math kinds);
single-physical-source Channels get an embedded Filters block; new
Channels auto-name/auto-ID from their source and reject duplicate
names/IDs on apply; "Create Channel" button on each Signal row; renamed
"Sources" -> "Signals" in the Channels UI; Signals' READ/WRITE dir badge
(was silently-broken IN/OUT) now reflects the real writable flag.
Plot: default layout is one pane per Channel (not per device, not raw
Signals) titled by channel name; "+ Add Channel" is a checkbox dialog
instead of an inline dropdown; traces get up/down reorder; live unit
changes (e.g. a Mark-10 gauge switching lb/kgF/N/ozF) propagate to an
open pane's axis label without clobbering a manually-typed one.
Control Panel: hardware assignment now picks from the same writable-
Signals list instead of a separate device/channel combo with a
hardcoded Arduino pin list; stale visual indicator when a control's
target device/channel disconnects or disappears; documented the `vars`
bridge (Control Panel On Action Script <-> Channel scripts) in both
directions' help text and script templates.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
|
|
- Moved edit and X button to top with header of widget.
- Replaced up/down button with drag-and-drop style headers.
|
|
protocol updates
origin/main (23 commits) added a Debug window/log system on top of the old
separate Devices/Channels/Plot windows, plus protocol fixes (cml, mark10,
modbus_rtu, scpi) and device/profile changes. Local main (3 commits)
replaced the separate windows with a unified ConfigWindow + dock panel.
Kept local's ConfigWindow/dock architecture and ported the Debug window
onto it: new toolbar button + _open_debug(), gated by developer_mode same
as origin's version. Deduped the two independent "developer mode" toggles
that had collided in SettingsWindow (origin's General-tab checkbox gating
Debug window + device sim-mode visibility, local's Advanced-tab checkbox
setting verbose logging) into one General-tab checkbox that does both.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
|
|
- Added dedicated firmware file for arduino
- Added View button to consolidate windows
- Control Panel changes:
- Changed name fron "Controls" to "Control Panel"
- Blue side bar when Panel is hidden.
- Supports "popping" out contorl panel
- Settings > Advanced tab added with developer settings
|
|
# Conflicts:
# ui/control_editor.py
|
|
Run/Stop previously only paused acquisition — control outputs (motor
speed, switches, PWM duty) kept whatever value was last written, so
stopping the run loop didn't stop a running motor. Adds
ControlWidget.safe_stop() (per-widget override, default zeros the
output) and ControlPanel.safe_stop_all(), called from _toggle_run's
Stop branch before engine.stop().
Per-widget behavior is deliberately not uniform:
- OnOffSwitch/MotorControl/PwmControl have a latched running/enabled
state, so safe_stop() drives their own toggle handler (consistent UI
+ write in one path) and, for Motor/PWM, zeroes the slider too.
- SetpointControl/AnalogOutputControl only write on an explicit user
action and have no universally safe forced value (e.g. 0 isn't
necessarily "off" for an arbitrary process setpoint or analog
output) — Stop leaves them untouched rather than guessing.
Log button: added a :disabled QSS rule so "can't log yet" reads as
clearly inert rather than a duller version of the enabled look, and a
600ms blink (toggling a "recording" dynamic property the QSS keys off)
while a recording is active, so it reads as live/recording rather than
a static pressed button. Master Stop now calls _toggle_log(False)
explicitly when forcing the button off, since QPushButton.setChecked()
doesn't emit clicked — without this the blink would keep running after
a master Stop even though logging itself already halted via
engine.stop()'s internal stop_logging() call.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
|
|
Adds ChannelConfig.writable so the Controls editor can only bind to
channels with a real write mapping (VS/MA/ME/MD/ST for CML, do*/DO for
digital I/O, write_cmd-configured SCPI channels, holding-register Modbus
channels) instead of read-only telemetry — this is exactly the class of
mistake hit earlier (binding a motor-speed control to M1_TV instead of
M1_VS). Also carries forward the enabled-channel gating for controls
(hide disabled channels from the picker, block writes to them at
_write() time) done alongside this investigation.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
|
|
|
|
- Named variables in expressions: source channel IDs injected as Python
identifiers alongside x[] (e.g. write `A0 * 2` instead of `x[0] * 2`)
- Shared `vars` dict on SignalProcessor accessible from all expressions,
functions, and control scripts; persisted in .labdaq profiles
- Per-derived-channel `state` dict for persistent computation state in
custom scripts
- Control widgets gain optional on_action_script (Python snippet with
value, vars, channels, math in scope); syntax-checked in editor dialog
- Built-in derived kinds (derivative, rms, power, etc.) now show their
Python implementation as read-only code previews; "Edit as Custom Script"
converts to custom_script kind with template pre-filled
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
|
|
|
|
|
This version contains the profile feature. Allowins users to save the
channels, signals and plots for specific labs.
|
|
|