fix
This commit is contained in:
@@ -1640,6 +1640,7 @@ def run_pyqtgraph(args) -> None:
|
||||
changed = runtime.ring.ensure_init(sweep_width)
|
||||
if not changed:
|
||||
return
|
||||
log_debug_event("ring_resize", f"ring resized to width {int(sweep_width)}", every=1)
|
||||
f_min = float(runtime.range_min_ghz)
|
||||
f_max = float(runtime.range_max_ghz)
|
||||
freq_bounds = resolve_axis_bounds(runtime.current_freqs)
|
||||
@@ -1657,18 +1658,11 @@ def run_pyqtgraph(args) -> None:
|
||||
padding=0,
|
||||
)
|
||||
set_x_range_if_changed("line_x", p_line, f_min, f_max, padding=0)
|
||||
disp_fft = fft_bscan_image_to_db(runtime.ring.get_display_fft_linear())
|
||||
if disp_fft is not None:
|
||||
img_fft.setImage(disp_fft, autoLevels=False)
|
||||
set_image_rect_if_changed("fft_waterfall_rect", img_fft, 0.0, 0.0, float(max_sweeps), 1.0)
|
||||
set_xy_range_if_changed(
|
||||
"fft_waterfall_range",
|
||||
p_spec,
|
||||
x_bounds=(0, max_sweeps - 1),
|
||||
y_bounds=(0.0, 1.0),
|
||||
padding=0,
|
||||
)
|
||||
set_x_range_if_changed("fft_x", p_fft, 0.0, 1.0, padding=0)
|
||||
# NOTE: do NOT reset the B-scan (fft_waterfall) rect/range to a (0,1)
|
||||
# placeholder here. The real distance geometry (0..~12 m) is applied every
|
||||
# frame by update_physical_axes() and the B-scan draw block using the stable
|
||||
# axis. Writing the placeholder on every ring resize made the B-scan y-axis
|
||||
# thrash between height 1 and 12 → the flicker.
|
||||
|
||||
def _active_distance_axis() -> Optional[np.ndarray]:
|
||||
if runtime.current_distances is not None and runtime.current_distances.size > 0:
|
||||
|
||||
Reference in New Issue
Block a user