daplis_rtp.gui.tabs.full_sensor module

Full Sensor: both halves of the LinoSPAD2 sensor, 512 pixels at once.

Two boards, each writing into a directory of its own, plotted end to end with a dashed line marking the seam. Pixel-address correction is always applied to board 2 and never to board 1, as the sensor geometry requires, so no switch is offered for it; the same holds for the absolute timestamps, which full-sensor data are always collected with because they are what synchronizes the two halves.

Both browse rows are used here, which is why every other tab reserves two as well: the plot has to begin at the same height on all five.

class daplis_rtp.gui.tabs.full_sensor.LinoSPAD2Dual(parent=None)[source]

Bases: PlotTab

Photon rate across both sensor halves, from two boards at once.

bind_session()[source]

Register the controls this tab should remember.

build()[source]

Fill the shell. Every tab writes this and nothing else.

canvas_class

alias of DualSensorCanvas

combined_mask()[source]

Both boards’ masks laid end to end on the 0-511 axis.

hint_text = 'Both sensor halves end to end, from two boards writing in step. Board 2 is always address-corrected; Ctrl+click a pixel to mask it.'
mask_pixels()[source]
on_refresh_requested()[source]

Hook: what an explicit ‘look again’ re-arms.

on_stream_start()[source]

Hook: what this tab arms when a run starts.

on_stream_stop()[source]

Hook: what this tab stands down when a run ends.

plotted_data()[source]

The numbers behind the plot, for File -> Export.

Returns None when there is nothing to export, or a dict:

stem

A suggested file name, without an extension.

columns

Ordered {heading: 1-D array}; every column the same length.

notes

Lines describing where the numbers came from, written into the file as # comments so that a plot found on a disk six months later can still say what it was.

presetmask_pixels()[source]

Apply each board’s recorded warm-pixel mask, or lift them.

Each board uses the shared daughterboard and its own motherboard to look up its file. A board with no mask recorded is skipped silently; the warning comes only when neither has one, since one board masked and the other not is a perfectly ordinary state.

refresh()[source]

Read the newest file and redraw. Written by every tab.

report_occupancy(fw_ver, occupancy_1, occupancy_2)[source]

Hand one refresh’s slot occupancy to the status box.

The pixels of interest are given on the 0-511 x-axis of this tab, so each board takes the part of them that falls on its own half and maps it to TDCs with the pix_add_fix its rates were built with - always off for board 1 and on for board 2.

reset_pix_mask()[source]
session_scope = 'full_sensor'
slot_mask_changed()[source]

Rebuild both masks, update the count, and redraw.

toggle_pixel_mask(pixel)[source]

Ctrl+click on the plot: mask this pixel, or unmask it.

The plot’s x-axis runs 0-511 across both halves, so which board the click landed on is the half it fell in.

watched_paths()[source]

The folders a running stream should watch. Tabs override.