Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

myana.cc - example code to make a simple averaging histogram

myana_morefeatures.cc - example code that does a little more.

...

         getAcqConfig - fetches the configuration information for any of the Acquiris devices.
                        Checks that the detector has been used / has data, and tells you the number
                        of channels used, number of samples collected and the sample interval.
                        This is typically done in the myana::beginjob() or myana::beginrun() functions.
                        Specify with enum which device you want information from, and supply a
                        pointer to two integers and a double: numChannels, numSamples, sampleInterval.
         getAcqValue  - fetches data from any of the Acquiris devices.
                        Specify with enum which device you want the information from, and an integer
                        to store channel information, as well as pointers two arrays of doubles. These will
                        be pointed to time information and voltage information. Optional: you can also
                        supply a pointer to another double, which will be pointed to trigger time.

                                                In the myana.cc example, we fetch data from the AmoITof device (AMO Ion Time-of-flight).
                        Other Acquiris devices (see main.hh for an up-to-date list):

                        AMO:
                            AmoIms      AmoIms         - ion momentum spectrometer
                            AmoGasdet   -AmoGasdet    - gas detector (in the Front End Enclusure)
                            AmoETof     AmoETof       - electron time-of-flight
                            AmoMbes     AmoMbes      - magnetic bottle electron spectrometer
                            AmoVmiAcq   - (Vmi = Velocity mapping imaging)
                            AmoBpsAcq   - (Bps = Beam position screen)
                            Camp        Camp            - for the CAMP experimental setup
                        SXR:
                            SxrBeamlineAcq1
                            SxrBeamlineAcq2
                            SxrEndstationAcq1
                            SxrEndstationAcq2

          getFrameConfig - Checks that the xtc file has got data from this device.
          getFrameValue - fetches an image from the FrameDetector of your choice.
                          Specify the detector (using an appropriate enum), give pointers to
                          int frame width, frame height and short imgage of the Camera::FrameV1.

          Other frame detectors:
          AMO:
              AmoVmi
              AmoBps1
              AmoBps2
          SXR:
              SxrBeamlineOpal1
              SxrBeamlineOpal2
              SxrEndstationOpal1
              SxrEndstationOpal2
              SxrFccd
           XPP:
              XppSb1PimCvd
              XppMonPimCvd
              XppSb3PimCvd
              XppSb4PimCvd

          You need another function to access data from the Opal cameras:
          getOpal1kValue(Opal1kDetector det, int& frameWidth, int& frameHeight, unsigned short*& image )
                  - This function gets an Camera::FrameV1& frame. (But what does it do with it?)
          Possible Opal1kDetectors:
             AmoVmi
             AmoBps1
             AmoBps2