Scope
|
#include <FPGAAnalogIntegrator.h>
Inherits scope::FPGAInterface, and scope::FPGAIO5771.
Public Member Functions | |
FPGAAnalogIntegrator () | |
~FPGAAnalogIntegrator () | |
void | Initialize (parameters::InputsFPGA *_parameters) override |
double | SetPixeltime (const uint32_t &_area, const double &_pixeltime) override |
double | SetLinetime (const uint32_t &_area, const double &_linetime) override |
void | SetTriggering (const bool &_waitfortrigger) override |
void | SetContinuousAcquisition (const bool &_cont) override |
void | SetRequestedPixels (const uint32_t &_area, const uint32_t &_reqpixels) override |
void | StartAcquisition () override |
void | StopAcquisition () override |
int32_t | ReadPixels (DaqChunk &_chunk, const double &_timeout, bool &_timedout) override |
void | SetChannelProps () |
void | CheckFPGADiagnosis () |
void | ClearFIFOs () |
Public Member Functions inherited from scope::FPGAInterface | |
virtual | ~FPGAInterface () |
virtual void | SetScannerdelay (const uint32_t &_scannerdelay) |
FPGAStatusSafe | CurrentStatus () const |
Public Member Functions inherited from scope::FPGAIO5771 | |
FPGAIO5771 (const uint32_t &_user_command_idle, const uint32_t &_pll_locked, const uint32_t &_configured, const uint32_t &_user_error, const uint32_t &_user_command_status, const uint32_t &_user_command_control, const uint32_t &_user_data_0_control, const uint32_t &_user_data_1_control, const uint32_t &_user_command_commit) | |
void | SetClockSource (NiFpga_Session _session, const uint8_t &_clock_source=0) |
bool | CheckIOModule (NiFpga_Session _session) |
Protected Attributes | |
parameters::InputsFPGAAnalogIntegrator * | parameters |
std::array< NiFpga_AnalogIntegrator_NI5771_TargetToHostFifoU32, 2 > | fifos |
Protected Attributes inherited from scope::FPGAInterface | |
FPGAStatusSafe | status |
NiFpga_Session | session |
bool | initialized |
Protected Attributes inherited from scope::FPGAIO5771 | |
const uint32_t | user_command_idle_indicator |
const uint32_t | pll_locked_indicator |
const uint32_t | configured_indicator |
const uint32_t | user_error_indicator |
const uint32_t | user_command_status_indicator |
const uint32_t | user_command_control |
const uint32_t | user_data_0_control |
const uint32_t | user_data_1_control |
const uint32_t | user_command_commit_control |
FPGAStatusSafe | iostatus |
Additional Inherited Members | |
Protected Member Functions inherited from scope::FPGAIO5771 | |
void | WaitForIdle (NiFpga_Session _session) |
Wraps an FPGA that does analog pixel integration (with the NI 5771 FlexRIO adapter module http://sine.ni.com/nips/cds/view/p/lang/en/nid/210735)
Definition at line 18 of file FPGAAnalogIntegrator.h.
scope::FPGAAnalogIntegrator::FPGAAnalogIntegrator | ( | ) |
Load the FPGA bitfile, set the IO module's onboard clock and initialize the acquisition.
Definition at line 8 of file FPGAAnalogIntegrator.cpp.
scope::FPGAAnalogIntegrator::~FPGAAnalogIntegrator | ( | ) |
Close FPGA session.
Definition at line 45 of file FPGAAnalogIntegrator.cpp.
|
overridevirtual |
Set initial parameters.
Derived classes override this and cast _parameters to the appropriate derived type. Derived functions should check if already initialized.
Reimplemented from scope::FPGAInterface.
Definition at line 51 of file FPGAAnalogIntegrator.cpp.
|
overridevirtual |
Sets the time per pixel/dwell time (in seconds)
[in] | _area | for which area |
[in] | _pixeltime | the pixel dwell time in seconds |
Reimplemented from scope::FPGAInterface.
Definition at line 61 of file FPGAAnalogIntegrator.cpp.
|
overridevirtual |
Sets the time per line (in seconds) for the generation of the line clock (if implemented)
[in] | _area | for which area |
[in] | _linetime | the line time in seconds |
Reimplemented from scope::FPGAInterface.
Definition at line 76 of file FPGAAnalogIntegrator.cpp.
|
overridevirtual |
Sets if the FPGA should wait for a trigger before starting acquisition.
[in] | _waitfortrigger | true if wait for trigger |
Reimplemented from scope::FPGAInterface.
Definition at line 91 of file FPGAAnalogIntegrator.cpp.
|
overridevirtual |
Sets if the FPGA should acquire data continuously or acquire the number of pixels per channel set with SetRequestedPixels.
[in] | _cont | yes or no |
Reimplemented from scope::FPGAInterface.
Definition at line 95 of file FPGAAnalogIntegrator.cpp.
|
overridevirtual |
Sets the number of pixels per channel the FPGA should acquire, set to -1 for live scanning.
[in] | _area | for which area |
[in] | _reqpixels | number of pixels the FPGA should acquire before automatically stopping acquisition |
Reimplemented from scope::FPGAInterface.
Definition at line 99 of file FPGAAnalogIntegrator.cpp.
|
overridevirtual |
Starts the acquisition on the FPGA.
Reimplemented from scope::FPGAInterface.
Definition at line 103 of file FPGAAnalogIntegrator.cpp.
|
overridevirtual |
Stops the acquisition on the FPGA.
Reimplemented from scope::FPGAInterface.
Definition at line 156 of file FPGAAnalogIntegrator.cpp.
|
overridevirtual |
Read only pixels from the FPGA FIFO.
[in,out] | _chunk | the daq chunk to read into, inside _chunk is information about the area for wich to retrieve, the number of pixels per channel to read, and the number of channels |
[in] | _timeout | time out for reading in seconds |
[out] | _timedout | set to true if reading timed out |
Implements scope::FPGAInterface.
Definition at line 109 of file FPGAAnalogIntegrator.cpp.
void scope::FPGAAnalogIntegrator::SetChannelProps | ( | ) |
Set channel properties as baseline and bitshift.
Definition at line 160 of file FPGAAnalogIntegrator.cpp.
void scope::FPGAAnalogIntegrator::CheckFPGADiagnosis | ( | ) |
Checks the status of the FIFOs on the FPGA.
Definition at line 171 of file FPGAAnalogIntegrator.cpp.
void scope::FPGAAnalogIntegrator::ClearFIFOs | ( | ) |
Clears the interloop and ToHost FIFOs.
Definition at line 187 of file FPGAAnalogIntegrator.cpp.
|
protected |
the parameter set
Definition at line 24 of file FPGAAnalogIntegrator.h.
|
protected |
both fifos for both channels
Definition at line 27 of file FPGAAnalogIntegrator.h.