TwoBitLookup.h
1 //-*-C++-*-
2 /***************************************************************************
3  *
4  * Copyright (C) 2008 by Willem van Straten
5  * Licensed under the Academic Free License version 2.1
6  *
7  ***************************************************************************/
8 
9 // dspsr/Kernel/Classes/dsp/TwoBitLookup.h
10 
11 #ifndef __TwoBitLookup_h
12 #define __TwoBitLookup_h
13 
14 #include "dsp/TwoBitTable.h"
15 
16 class JenetAnderson98;
17 
18 namespace dsp
19 {
20  class TwoBitTable;
21 
24  {
25 
26  public:
27 
28  TwoBitLookup ();
29  virtual ~TwoBitLookup ();
30 
32  void set_ndat (unsigned ndat);
33 
35  void set_ndim (unsigned ndim);
36 
38  void set_nlow_min (unsigned min);
39 
41  void set_nlow_max (unsigned max);
42 
44  virtual void lookup_build (TwoBitTable*, JenetAnderson98* = 0);
45 
47  virtual void get_lookup_block (float* lookup, TwoBitTable* table) = 0;
48 
50  virtual unsigned get_lookup_block_size () = 0;
51 
52  protected:
53 
54  unsigned nlow;
55  unsigned nlow_min;
56  unsigned nlow_max;
57 
58  unsigned ndat;
59  unsigned ndim;
60 
61  float* lookup_base;
62 
63  // create lookup_base
64  virtual void create ();
65 
66  private:
67 
68  // delete lookup_base
69  void destroy ();
70  };
71 
72 }
73 
74 #endif
void set_Phi(double Phi)
void set_nlow_min(unsigned min)
Set the minimum acceptable number of low voltage states.
Definition: TwoBitLookup.C:33
Contains all Baseband Data Reduction Library classes.
Definition: ASCIIObservation.h:17
void set_lo_val(float lo_val)
Set the value of the low voltage state.
Definition: TwoBitTable.C:21
virtual void lookup_build(TwoBitTable *, JenetAnderson98 *=0)
Build the output value lookup table.
Definition: TwoBitLookup.C:77
void set_nlow_max(unsigned max)
Set the maximum acceptable number of low voltage states.
Definition: TwoBitLookup.C:39
void set_hi_val(float hi_val)
Set the value of the high voltage state.
Definition: TwoBitTable.C:27
double get_hi() const
void set_ndat(unsigned ndat)
Set the number of time samples in each population counted.
Definition: TwoBitLookup.C:45
virtual void get_lookup_block(float *lookup, TwoBitTable *table)=0
Unpack a block of unique samples, given the current table.
Creates lookup table for 2-bit dynamic output level setting.
Definition: TwoBitLookup.h:23
void set_ndim(unsigned ndim)
Set the dimension of the time samples (1=real, 2=complex)
Definition: TwoBitLookup.C:52
Look-up table for converting 2-bit digitized to floating point numbers.
Definition: TwoBitTable.h:25
virtual unsigned get_lookup_block_size()=0
Return the number of unique samples per block.
double get_lo() const

Generated using doxygen 1.8.17