Skip to content

Commit da53246

Browse files
Update Demo_DeviceConfig.py
1 parent 5f1c3ef commit da53246

1 file changed

Lines changed: 22 additions & 0 deletions

File tree

demos/Demo_DeviceConfig.py

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,27 @@
11
from snAPI.Main import *
22

3+
# Reading and printing the device configuration
4+
# =============================================
5+
# This demo demonstrates how to access and inspect the configuration of a
6+
# PicoQuant time tagging device with snAPI.
7+
#
8+
# The script initializes the device, loads an ini configuration file, and then
9+
# prints the complete device configuration structure. This structure contains
10+
# device information as well as the current settings of the input channels.
11+
#
12+
# Setup:
13+
# The device type is selected by the ini file loaded with `loadIniConfig`. The
14+
# example uses `config\MH.ini`, which should be replaced by the configuration
15+
# file matching the connected device and measurement setup.
16+
#
17+
# After loading the configuration, the script reads selected entries from
18+
# `sn.deviceConfig`, such as the device ID, the trigger or discriminator levels
19+
# of all channels, and the enable state of a selected channel.
20+
#
21+
# This is useful for checking whether a device has been configured correctly,
22+
# verifying channel settings before a measurement, and learning how to access
23+
# configuration values programmatically for use in custom scripts.
24+
325
if(__name__ == "__main__"):
426

527
# set the library for your device type

0 commit comments

Comments
 (0)