Skip to main content

Software to work with QNet DAQ cards designed for students experiments

Project description

The muonic project provides an interface to communicate with QuarkNet DAQ cards and to perform simple analysis of the generated data. Its goal is to ensure easy and stable access to the QuarkNet cards and visualize some of the features of the cards. It is meant to be used in school projects, so it should be easy to use even by people who do not have lots LINUX backround or experience with scientific software. Automated data taking can be used to ensure no valuable data is lost.

Licence and terms of agreement

Muonic is ditributed under the terms of GPL (Gnu Public License). With the use of the software you accept the condidions of the GPL. This means also that the authors can not be made responsible for any damage of any kind to hard- or software.

muonic setup and installation

Muonic consists of two main parts: 1. the python package muonic 2. a python executable

prerequesitories

muonic needs the following packages to be installed (list may not be complete!)

  • python-scipy

  • python-matplotlib

  • python-numpy

  • python-qt4

  • python-serial

installation with the setup.py script

Run the following command in the directory where you checked out the source code:

python setup.py install

This will install the muonic package into your python site-packages directory and also the exectuables muonic and which_tty_daq to your usr/bin directory. It also generates a new directory in your home dir: $HOME/muonic_data

The use of python-virtualenv is recommended.

installing muonic without the setup script

You just need the script ./bin/muonic to the upper directory and rename it to muonic.py. You can do this by typing

mv bin/muonic muonic.py

while being in the muonic main directory.

Afterwards you have to create the folder muonic_data in your home directory.

mkdir ~/muonic_data

How to use muonic

start muonic

If you have setup muonic via the provided setup.py script or if you hav put the package somewhere in your PYTHONPATH, simple call from the terminal

muonic [OPTIONS] xy

where xy are two characters which you can choose freely. You will find this two letters occuring in automatically generated files, so that you can identify them.

For help you can call

muonic --help

which gives you also an overview about the options:

muonic

[OPTIONS]

-s
use the simulation mode of muonic (no real data, so no physics behind!). This should only used for testing and developing the software

-d
debug mode. Use it to generate more log messages on the console.

-t sec
change the timewindow for the calculation of the rates. If you expect very low rates, you might consider to change it to larger values.
default is 5 seconds.

-p
automatically write a file with pulsetimes in a non hexadecimal representation

-n
supress any status messages in the output raw data file, might be useful if you want use muonic only for data taking and use another script afterwards for analysis.

Saving files with muonic

All files which are saved by muonic are ASCII files. The filenames are as follows:

YYYY-MM-DD_HH-MM-SS_TYPE_MEASUREMENTTME_xy

  • YYYY-MM-DD is the date of the measurement start

  • HH-MM-SS is the GMT time of the measurement start

  • MEASUREMENTTIME if muonic is closed, each file gets is corresponding measurement time (in hours) assigned.

  • xy the two letters which were specified at the start of muonic

  • TYPE might be one of the following:

  • RAW the raw ASCII output of the DAQ card, this is only saved if the ‘Save to file’ button in clicked in the ‘Daq output’ window of muonic

  • R is an automatically saved ASCII file which contains the rate measurement data, this can then be used to plot with e.g. gnuplot later on

  • L specifies a file with times of registered muon decays. This file is automatically saved if a muon decay measurement is started.

  • P stands for a file which contains a non-hex representation of the registered pulses. This file is only save if the -p option is given at the start of muonic

Representation of the pulses:

(69.15291364, [(0.0, 12.5)], [(2.5, 20.0)], [], [])

This is a python-tuple which contains the triggertime of the event and four lists with more tuples. The lists represent the channels (0-3 from left to right) and each tuple stands for a leading and a falling edge of a registered pulse. To get the exact time of the pulse start, one has to add the pulse LE and FE times to the triggertime

Performing measurements with muonic

Setting up the DAQ

For DAQ setup it is recommended to use the ‘settings’ menu, allthough everything can also be setup via the command line in the DAQ output window (see below.) Muonic translates the chosen settings to the corresponding DAQ commands and sends them to the DAQ. So if you want to change things like the coincidence time window, you have to issue the corresponding DAQ command in the DAQ output window.

Two menu items are of interest here: * Channel Configuration: Enable the channels here and set coincidence settings. A veto channel can also be specified.

  • Thresholds: For each channel a threshold (in milliVolts) can be specified. Pulse which are below this threshold are rejected. Use this for electronic noise supression. One can use for the calibration the rates in the muon rates tab.

Muon Rates

In the first tab a plot of the measured muonrates is displayed. A triggerrate is only shown if a coincidence condition is set. In the block on the right side of the tab, the average rates are displayed since the measurement start. Below you can find the number of counts for the individual channels. On the bottom right side is also the maximum rate of the measurment. The plot and the shown values can be reset by clicking on ‘Restart’. The ‘Stop’ button can be used to temporarily hold the plot to have a better look at it.

Muon Lifetime

A lifetime measurement of muons can be performed here. A histogram of time differences between succeding pulses in the same channel is shown. It can be fit with an exponential by clicking on ‘Fit!’. The fit lifetime is then shown in the above right of the plot, for an estimate on the errors you have to look at the console.

The measurment can be activated with the checkbox. In the following popup window the measurment has to be configured. It depends mainly on the detector you use and influences the quality of the measurment. The signal is accepted if more than one pulse appears in the single pulse channel or if one pulse appears in the single pulse channel and >= 2 pulses appear in the double pulse channel. The coincidence time is set to ?microseconds for this measurement. The signal are vetoed with the veto channel: only events are accepted if no pulse occurs there. If the selfveto is activated it accepts only events if: * more than one pulse appears in the single pulse channel and none pulse is measured in the double pulse channel * one pulse in the single pulse channel appears and exactly two pulses in the double pulse channel.

Muon Velocity

In this tab the muon velocity can be measured. The measurement can be started with activating the checkbox. In the following popup window it has to be configured.

Pulse Analyzer

You can have a look at the pulsewidhts in this plot. The height of the pulses is lost during the digitization prozess, so all pulses have the same height here. On the left side is an oscilloscope of the pulsewidths shown and on the right side are the pulsewidths collected in an histogram.

GPS Output

In this tab you can read out the GPS information of the DAQ card. It requires a connected GPS antenna. The information are summarized on the bottom in a text box, from where they can be copied.

Raw DAQ data

The last tab of muonic displays the raw ASCII DAQ data. This can be saved to a file. If the DAQ status messages should be supressed in that file, the option -n should be given at the start of muonic. The edit field can be used to send messages to the DAQ. For an overview over the messages, look here (link not available yet!). To issue such an command periodically, you can use the button ‘Periodic Call’

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

muonic-2.0.0.tar.gz (278.3 kB view hashes)

Uploaded Source

Built Distributions

muonic_2.0.egg (376.3 kB view hashes)

Uploaded Source

muonic-2.0.0-py2.7.egg (375.4 kB view hashes)

Uploaded Source

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page