3 #include "ScopeDefines.h"
5 #include "helpers/ScopeNumber.h"
6 #include "helpers/ScopeString.h"
13 namespace parameters {
15 using boost::property_tree::wptree;
25 virtual std::unique_ptr<Inputs>
Clone()
const = 0;
51 void Load(
const wptree& pt)
override;
52 void Save(wptree& pt)
const override;
65 static std::unique_ptr<Inputs>
Create() {
return std::unique_ptr<Inputs>(
new InputsDAQmx()); }
67 std::unique_ptr<Inputs>
Clone()
const override {
return std::unique_ptr<Inputs>(
new InputsDAQmx(*
this)); }
100 : daqmxversion(L
"", L
"DAQmxVersion") {
111 void Load(
const wptree& pt)
override;
112 void Save(wptree& pt)
const override;
123 static std::unique_ptr<Inputs>
Create() {
return std::unique_ptr<Inputs>(
new InputsFPGA()); }
125 std::unique_ptr<Inputs>
Clone()
const override {
return std::unique_ptr<Inputs>(
new InputsFPGA(*
this)); }
131 void Load(
const wptree& pt)
override;
132 void Save(wptree& pt)
const override;
160 : ToHostOverflowA1Ch1(false, false, true, L
"ToHostOverflowA1Ch1")
161 , ToHostOverflowA1Ch2(false, false, true, L
"ToHostOverflowA1Ch2")
162 , ToHostOverflowA2Ch1(false, false, true, L
"ToHostOverflowA1Ch1")
163 , ToHostOverflowA2Ch2(false, false, true, L
"ToHostOverflowA1Ch2")
164 , Acquiring(false, false, true, L
"Acquiring") {
190 void Load(
const wptree& pt)
override;
191 void Save(wptree& pt)
const override;
226 : ToHostOverflowA1Ch1(false, false, true, L
"ToHostOverflowA1Ch1")
227 , ToHostOverflowA1Ch2(false, false, true, L
"ToHostOverflowA1Ch2")
228 , ToHostOverflowA2Ch1(false, false, true, L
"ToHostOverflowA2Ch1")
229 , ToHostOverflowA2Ch2(false, false, true, L
"ToHostOverflowA2Ch2")
230 , InterloopOverflow(false, false, true, L
"InterloopOverflow")
231 , InterloopTimeout(false, false, true, L
"InterloopTimeout")
232 , Acquiring(false, false, true, L
"Acquiring")
233 , MeasuredLaserFreq(0.0, 0.0, 1E10, L
"MeasuredLaserFrequency_Hz") {
240 void Load(
const wptree& pt)
override;
241 void Save(wptree& pt)
const override;
275 : ToHostOverflowCh1(false, false, true, L
"ToHostOverflowCh1")
276 , ToHostOverflowCh2(false, false, true, L
"ToHostOverflowCh2")
277 , InterloopOverflow(true, false, true, L
"InterloopOverflow")
278 , InterloopTimeout(false, false, true, L
"InterloopTimeout")
279 , Acquiring(false, false, true, L
"Acquiring")
280 , CountingMode(true, false, true, L
"CountingMode") {
287 void Load(
const wptree& pt)
override;
288 void Save(wptree& pt)
const override;
319 void Load(
const wptree& pt)
override;
320 void Save(wptree& pt)
const override;
349 void Load(
const wptree& pt)
override;
350 void Save(wptree& pt)
const override;
393 : ToHostOverflowA1(false, false, true, L
"ToHostOverflowA1")
394 , ToHostOverflowA2(false, false, true, L
"ToHostOverflowA2")
395 , InterloopOverflow(false, false, true, L
"InterloopOverflow")
396 , InterloopTimeout(false, false, true, L
"InterloopTimeout")
397 , Acquiring(false, false, true, L
"Acquiring")
398 , AIOverRange(false, false, true, L
"AIOverRange") {
405 void Load(
const wptree& pt)
override;
406 void Save(wptree& pt)
const override;
443 : ToHostOverflowCh1(false, false, true, L
"ToHostOverflowCh1")
444 , ToHostOverflowCh2(false, false, true, L
"ToHostOverflowCh2")
445 , InterloopOverflow(false, false, true, L
"InterloopOverflow")
446 , InterloopTimeout(false, false, true, L
"InterloopTimeout")
447 , Acquiring(false, false, true, L
"Acquiring")
448 , AIOverRange(false, false, true, L
"AIOverRange") {
455 void Load(
const wptree& pt)
override;
456 void Save(wptree& pt)
const override;
493 : ToHostOverflowCh1(false, false, true, L
"ToHostOverflowCh1")
494 , ToHostOverflowCh2(false, false, true, L
"ToHostOverflowCh2")
495 , InterloopOverflow(false, false, true, L
"InterloopOverflow")
496 , InterloopTimeout(false, false, true, L
"InterloopTimeout")
497 , Acquiring(false, false, true, L
"Acquiring")
498 , AIOverRange(false, false, true, L
"AIOverRange") {
505 void Load(
const wptree& pt)
override;
506 void Save(wptree& pt)
const override;
520 virtual std::unique_ptr<Outputs>
Clone()
const = 0;
546 void Load(
const wptree& pt)
override;
547 void Save(wptree& pt)
const override;
558 std::unique_ptr<Outputs>
Clone()
const override {
return std::unique_ptr<Outputs>(
new OutputsDAQmx(*
this)); }
589 void Load(
const wptree& pt)
override;
590 void Save(wptree& pt)
const override;
648 void Load(
const wptree& pt)
override;
649 void Save(wptree& pt)
const override;
690 void Load(
const wptree& pt)
override;
691 void Save(wptree& pt)
const override;
739 void Load(
const wptree& pt)
override;
740 void Save(wptree& pt)
const override;
752 Daq(
const bool& _isslave);
796 void Load(
const wptree& pt)
override;
797 void Save(wptree& pt)
const override;
ScopeNumber< double > referenceclockrate
rate in Hertz of the reference clock.
Parameters for x/y-scanner/fast z/Pockels signal generation with NI-DAQmx where all output channels (...
static std::unique_ptr< Outputs > Create()
Create function for factory.
std::unique_ptr< Outputs > outputs
the output parameters
double CoercedPixeltime(const double &_pixeltime) const override
ScopeString pixel_referenceclocksource
source terminal of the reference clock for pixel sampling clock
ScopeNumber< uint32_t > requested_frames
number of frames to acquire
ScopeString zoomchannelstring
the digital channel to use for the resonance scanner zoom factor
void Load(const wptree &pt) override
load parameters from a boost::property_tree
double MinimumPixeltime() const override
double MinimumPixeltime() const override
ScopeNumber< double > pixeltime
pixel dwell time in microseconds, this is also the analog out sampling interval
ScopeNumber< double > referenceclockrate
rate in Hertz of the reference clock.
double CoercedPixeltime(const double &_pixeltime) const override
void Load(const wptree &pt) override
load parameters from a boost::property_tree
void Load(const wptree &pt) override
load parameters from a boost::property_tree
void Load(const wptree &pt) override
load parameters from a boost::property_tree
ScopeNumber< double > minimumpixeltime
Minimum sample time for 2 channel output.
ScopeNumber< double > minoutputpockels
minimum output voltage for scaling of the pockels signal
static std::unique_ptr< Outputs > Create()
Create function for factory.
ScopeString externalclocksource
source terminal of an external clock for sampling clock (could be e.g.
ScopeValue< DaqTiming > line_timing
where to get the line sampling clock from? Onboard, from external reference clock, or from external source
std::unique_ptr< Outputs > Clone() const override
Abstract clone method to clone into a pointer.
ScopeNumber< uint32_t > resonance_frequency
frequency of the resonance scanner used, which is especially the frequency of the synchronization sig...
void Save(wptree &pt) const override
save parameters into a boost:property_tree
std::unique_ptr< Outputs > Clone() const override
Abstract clone method to clone into a pointer.
ScopeNumber< double > minimumpixeltime
Minimum sample time for 4 channel output.
All parameters for scanner data generation and pixel acquisition If you add/remove parameters or deri...
double MinimumPixeltime() const override
All parameter classes derive from this.
void Save(wptree &pt) const override
save parameters into a boost:property_tree
ScopeNumber< double > referenceclockrate
rate in Hertz of the reference clock for sampling clock.
ScopeString shutterline
digital output line of the shutter
ScopeString referenceclocksource
source terminal of the reference clock
virtual double CoercedPixeltime(const double &_pixeltime) const
void Load(const wptree &pt) override
load parameters from a boost::property_tree
Base class for all Scope datatypes here, provides a uniform interface (and saves typing...).
ScopeString scanveclength
the length of the scanner vector (per channel)
double CoercedPixeltime(const double &_pixeltime) const override
ScopeString exportpixelclockterminal
terminal to which the pixel/sampleclock is exported
ScopeValue< DaqTiming > daq_timing
where to get the sampling clock from? Onboard, from external reference clock, or from external source...
Parameters for scanner data generation, base class.
ScopeString zoomresonanceline
digital output line of the zoom factor for a resonance scanner
double CoercedPixeltime(const double &_pixeltime) const override
void SetReadOnlyWhileScanning(const RunState &_runstate) override
set values that must not be changed to read-only during scanning.
void SetReadOnlyWhileScanning(const RunState &_runstate) override
set values that must not be changed to read-only during scanning.
ScopeString externalclocksource
source terminal of an external clock
ScopeString externalclocksource
source terminal of an external clock
ScopeNumber< double > minimumpixeltime
Minimum sample time for 2 channel output.
ScopeString referenceclocksource
source terminal of the reference clock
static std::unique_ptr< Outputs > Create()
Create function for factory.
virtual std::unique_ptr< Outputs > Clone() const =0
Abstract clone method to clone into a pointer.
int32_t ScannerDelaySamples(const bool &_respectoversampling) const
ScopeNumber< DaqTiming > daq_timing
where to get the sampling clock from? Onboard, from external reference clock, or from external source...
void Load(const wptree &pt) override
load parameters from a boost::property_tree
ScopeValue< DaqTiming > pixel_timing
where to get the pixel sampling clock from? Onboard, from external reference clock, or from external source
In here all declarations for all kinds of datatypes Scope needs.
ScopeString channelsstring
the four analog output channels to use for x, y, z, Pockels
ScopeNumber< double > pixel_referenceclockrate
rate in Hertz of the reference clock for pixel clock.
void SetReadOnlyWhileScanning(const RunState &_runstate) override
set values that must not be changed to read-only during scanning.
Daq & operator=(const Daq &_daq)
Supply assignment operator because of the unique_ptrs to base class.
static std::unique_ptr< Outputs > Create()
Create function for factory.
ScopeString channelsstring
the four analog output channels to use for x, y, z, Pockels
void Save(wptree &pt) const override
save parameters into a boost:property_tree
ScopeString line_referenceclocksource
source terminal of the reference clock for line sampling clock
const bool isslave
true if belongs to a slave area
void SetReadOnlyWhileScanning(const RunState &_runstate) override
set values that must not be changed to read-only during scanning.
std::unique_ptr< Outputs > Clone() const override
Abstract clone method to clone into a pointer.
ScopeString exportpixelclockterminal
terminal to which the pixel/sampleclock is exported
void Save(wptree &pt) const override
save parameters into a boost:property_tree
virtual double MinimumPixeltime() const
std::unique_ptr< Inputs > inputs
the input parameters
A templated class for a thread-safe value, with signals to GUI or other stuff that are called on valu...
ScopeNumber< uint32_t > averages
number of images to average
void Save(wptree &pt) const override
save parameters into a boost:property_tree
A templated class for a thread-safe std::wstring, with signals that are called on value changes...
ScopeNumber< double > line_referenceclockrate
rate in Hertz of the reference clock for line clock.
ScopeNumber< double > range
Output range of the DAC to use for all outputs.
ScopeString yzout
Analog output channel for y-scanner and fast z device (clocked by line clock)
ScopeValue< DaqTiming > timing
where to get the sampling clock from? Onboard, from external reference clock, or from external source...
ScopeNumber< double > minimumpixeltime
Minimum sample time for 4 channel output.
Daq(const bool &_isslave)
Constructor.
ScopeString pixel_externalclocksource
source terminal of an external clock for x and p pixel clock
void SetReadOnlyWhileScanning(const RunState &_runstate) override
set values that must not be changed to read-only during scanning.
ScopeString switchresonanceline
digital output line turning the resonance scanner on and off
double MinimumPixeltime() const override
void SetReadOnlyWhileScanning(const RunState &_runstate) override
set values that must not be changed to read-only during scanning.
Parameters for fastz/Pockels signal generation with NI-DAQmx where zp are driven by a pixel clock fro...
void Save(wptree &pt) const override
save parameters into a boost:property_tree
Various helper functions and classes for Scope.
ScopeNumber< double > maxoutputpockels
maximum output voltage for scaling of the pockels signal
Parameters for signal generation for y scanner and digital zoom with NI-DAQmx when the x scanner is a...
static std::unique_ptr< Outputs > Factory(const OutputsType &_type)
Factory method to generate parameter sets for different scan types and put them into a ScannerVectorF...
ScopeString line_externalclocksource
source terminal of an external clock for y and z line clock
Parameters for x/y-scanner/fast z/Pockels signal generation with NI-DAQmx where xp are driven by a pi...
ScopeString zpout
Analog output channel for fast z and Pockels cell (clocked by a pixel clock)
ScopeString referenceclocksource
source terminal of the reference clock for the sampling clock
std::unique_ptr< Outputs > Clone() const override
Abstract clone method to clone into a pointer.
ScopeNumber< double > scannerdelay
compensate, by waiting, the time that scanners lag behind the command voltage, in microseconds ...
ScopeString xpout
Analog output channel for x-scanner and Pockels cell (clocked by pixel clock)
ScopeNumber< double > minoutputscanner
minimum output voltage for scaling of the scanner signal
ScopeNumber< double > maxoutputscanner
maximum output voltage for scaling of the scanner signal
void CoercePixeltime()
Coerces pixeltime to a value that both inputs and outputs support.