Loading Common/Servers/Roach/include/CommandLine.h +4 −0 Original line number Diff line number Diff line Loading @@ -739,6 +739,10 @@ private: bool m_RC00; bool m_RL00; bool m_RP00; bool m_RK00S; bool m_RC00S; bool m_RL00S; bool m_RP00S; }; Loading Common/Servers/Roach/include/Common.h +6 −6 Original line number Diff line number Diff line Loading @@ -29,14 +29,14 @@ #define MAX_SECTION_NUMBER 14 #define MAX_BOARDS_NUMBER 14 #define DEFAULT_SAMPLE_RATE 0.000025 //one sample every 40 milliseconds #define DEFAULT_SAMPLE_RATE 3000.0 //one sample every 40 milliseconds //#define DEFAULT_SAMPLE_RATE 0.001 //one sample every 1 milliseconds #define DEFAULT_INTEGRATION 0 // no second of integration #define MIN_INTEGRATION 5 // millisecond of integration #define MAX_INTEGRATION 1000 // millisecond of integration #define DEFAULT_INTEGRATION 40 // milliseconds of integration #define MIN_INTEGRATION 5 // milliseconds of integration #define MAX_INTEGRATION 1000 // milliseconds of integration #define DEFAULT_DIODE_SWITCH_PERIOD 0 // the cal diode is not switched #define MAX_BAND_WIDTH 1500.0 #define MAX_BAND_WIDTH 2300.0 #define MIN_BAND_WIDTH 0.0 #define MAX_ATTENUATION 15.0 Loading @@ -45,7 +45,7 @@ #define MAX_BINS 16384 #define MIN_BINS 1024 #define MAX_SAMPLE_RATE 3000.0 // MHz #define MAX_SAMPLE_RATE 4600.0 // MHz #define FLOW_NUMBER 1 #endif /*COMMON_H_*/ Common/Servers/Roach/src/CommandLine.cpp +33 −6 Original line number Diff line number Diff line Loading @@ -45,6 +45,10 @@ CCommandLine::CCommandLine(ContainerServices *service): CSocket(), m_RC00=false; m_RL00=false; m_RP00=false; m_RK00S=false; m_RC00S=false; m_RL00S=false; m_RP00S=false; } CCommandLine::~CCommandLine() Loading Loading @@ -483,7 +487,8 @@ void CCommandLine::setAttenuation(const long&inputId, const double& attenuation) } */ if (inputId>=0) { if (inputId>=m_sectionsNumber) { //if (inputId>=m_sectionsNumber) { if (inputId>m_sectionsNumber) { // TBC !!! _EXCPT(ComponentErrors::ValidationErrorExImpl,impl,"CCommandLine::setAttenuation()"); impl.setReason("the input identifier is out of range"); throw impl; Loading Loading @@ -643,6 +648,7 @@ void CCommandLine::setConfiguration(const long& inputId,const double& freq,const impl.setValueName("pol"); throw impl; } newPol = pol; } else newPol = m_polarization[inputId]; Loading Loading @@ -716,7 +722,7 @@ void CCommandLine::setConfiguration(const long& inputId,const double& freq,const temp="FULL_STOKES"; ACS_LOG(LM_FULL_INFO,"CCommandLine::setConfiguration()",(LM_NOTICE,"SECTION_CONFIGURED %ld,FREQ=%lf,BW=%lf,FEED=%d,POL=%s,SR=%lf,BINS=%d",inputId,m_frequency[inputId],newBW,m_feedNumber[inputId], (const char *)temp,newSR,m_bins[inputId])); if (m_RK00==true || m_RC00==true) { if (m_RK00==true || m_RC00==true || m_RK00S==true || m_RC00S==true) { if (newBW==300.00) filter=300.00; if (newBW==1500.00) Loading Loading @@ -1104,22 +1110,42 @@ void CCommandLine::setDefaultConfiguration(const IRA::CString & config) throw (C if (config.Compare("RK00")==0) { filter=1250.0; m_RK00=true; m_RC00=m_RL00=m_RP00=false; m_RC00=m_RL00=m_RP00=m_RK00S=m_RC00S=m_RL00S=m_RP00S=false; } if (config.Compare("RC00")==0) { filter=1250.0; m_RC00=true; m_RK00=m_RL00=m_RP00=false; m_RK00=m_RL00=m_RP00=m_RK00S=m_RC00S=m_RL00S=m_RP00S=false; } if (config.Compare("RL00")==0) { filter = 2300.0; m_RL00=true; m_RK00=m_RC00=m_RP00=false; m_RK00=m_RC00=m_RP00=m_RK00S=m_RC00S=m_RL00S=m_RP00S=false; } if (config.Compare("RP00")==0) { filter = 730.0; m_RP00=true; m_RK00=m_RC00=m_RL00=false; m_RK00=m_RC00=m_RL00=m_RK00S=m_RC00S=m_RL00S=m_RP00S=false; } if (config.Compare("RK00S")==0) { filter=1250.0; m_RK00S=true; m_RC00=m_RL00=m_RP00=m_RK00=m_RC00S=m_RL00S=m_RP00S=false; } if (config.Compare("RC00S")==0) { filter=1250.0; m_RC00S=true; m_RK00=m_RL00=m_RP00=m_RK00S=m_RC00=m_RL00S=m_RP00S=false; } if (config.Compare("RL00S")==0) { filter = 2300.0; m_RL00S=true; m_RK00=m_RC00=m_RP00=m_RK00S=m_RC00S=m_RL00=m_RP00S=false; } if (config.Compare("RP00S")==0) { filter = 730.0; m_RP00S=true; m_RK00=m_RC00=m_RL00=m_RK00S=m_RC00S=m_RL00S=m_RP00S=false; } try { m_totalPower->setSection(0,-1, filter, -1, -1, -1, -1); Loading Loading @@ -2008,6 +2034,7 @@ bool CCommandLine::initializeConfiguration(const IRA::CString & config) throw (C m_sections[m_boards[i]]=i; //m_input[i]=m_defaultInput[m_boards[i]]; m_polarization[i]=setup.polarizations[i]; printf ("m_polarization = %d\n", m_polarization[i]); m_ifNumber[i]=setup.ifs[i]; m_feedNumber[i]=setup.feed[i]; m_inputSection[i]=i; // input 0 belongs to section 0 and so on..... Loading Common/Servers/Roach/src/Configuration.cpp +5 −3 Original line number Diff line number Diff line Loading @@ -119,11 +119,13 @@ bool CConfiguration::getSetupFromID(const IRA::CString setupID,TBackendSetup& se if (ret=="L") { setup.polarizations[i]=Backends::BKND_LCP; } else if (ret="R") { else if (ret=="R") { setup.polarizations[i]=Backends::BKND_RCP; } else else { setup.polarizations[i]=Backends::BKND_FULL_STOKES; } printf("setup.pol = %d\n", setup.polarizations[i]); if (!IRA::CIRATools::getNextToken(feed,start_feed,' ',ret)) return false; setup.feed[i]=ret.ToLong(); if (!IRA::CIRATools::getNextToken(ifs,start_ifs,' ',ret)) return false; Loading Loading
Common/Servers/Roach/include/CommandLine.h +4 −0 Original line number Diff line number Diff line Loading @@ -739,6 +739,10 @@ private: bool m_RC00; bool m_RL00; bool m_RP00; bool m_RK00S; bool m_RC00S; bool m_RL00S; bool m_RP00S; }; Loading
Common/Servers/Roach/include/Common.h +6 −6 Original line number Diff line number Diff line Loading @@ -29,14 +29,14 @@ #define MAX_SECTION_NUMBER 14 #define MAX_BOARDS_NUMBER 14 #define DEFAULT_SAMPLE_RATE 0.000025 //one sample every 40 milliseconds #define DEFAULT_SAMPLE_RATE 3000.0 //one sample every 40 milliseconds //#define DEFAULT_SAMPLE_RATE 0.001 //one sample every 1 milliseconds #define DEFAULT_INTEGRATION 0 // no second of integration #define MIN_INTEGRATION 5 // millisecond of integration #define MAX_INTEGRATION 1000 // millisecond of integration #define DEFAULT_INTEGRATION 40 // milliseconds of integration #define MIN_INTEGRATION 5 // milliseconds of integration #define MAX_INTEGRATION 1000 // milliseconds of integration #define DEFAULT_DIODE_SWITCH_PERIOD 0 // the cal diode is not switched #define MAX_BAND_WIDTH 1500.0 #define MAX_BAND_WIDTH 2300.0 #define MIN_BAND_WIDTH 0.0 #define MAX_ATTENUATION 15.0 Loading @@ -45,7 +45,7 @@ #define MAX_BINS 16384 #define MIN_BINS 1024 #define MAX_SAMPLE_RATE 3000.0 // MHz #define MAX_SAMPLE_RATE 4600.0 // MHz #define FLOW_NUMBER 1 #endif /*COMMON_H_*/
Common/Servers/Roach/src/CommandLine.cpp +33 −6 Original line number Diff line number Diff line Loading @@ -45,6 +45,10 @@ CCommandLine::CCommandLine(ContainerServices *service): CSocket(), m_RC00=false; m_RL00=false; m_RP00=false; m_RK00S=false; m_RC00S=false; m_RL00S=false; m_RP00S=false; } CCommandLine::~CCommandLine() Loading Loading @@ -483,7 +487,8 @@ void CCommandLine::setAttenuation(const long&inputId, const double& attenuation) } */ if (inputId>=0) { if (inputId>=m_sectionsNumber) { //if (inputId>=m_sectionsNumber) { if (inputId>m_sectionsNumber) { // TBC !!! _EXCPT(ComponentErrors::ValidationErrorExImpl,impl,"CCommandLine::setAttenuation()"); impl.setReason("the input identifier is out of range"); throw impl; Loading Loading @@ -643,6 +648,7 @@ void CCommandLine::setConfiguration(const long& inputId,const double& freq,const impl.setValueName("pol"); throw impl; } newPol = pol; } else newPol = m_polarization[inputId]; Loading Loading @@ -716,7 +722,7 @@ void CCommandLine::setConfiguration(const long& inputId,const double& freq,const temp="FULL_STOKES"; ACS_LOG(LM_FULL_INFO,"CCommandLine::setConfiguration()",(LM_NOTICE,"SECTION_CONFIGURED %ld,FREQ=%lf,BW=%lf,FEED=%d,POL=%s,SR=%lf,BINS=%d",inputId,m_frequency[inputId],newBW,m_feedNumber[inputId], (const char *)temp,newSR,m_bins[inputId])); if (m_RK00==true || m_RC00==true) { if (m_RK00==true || m_RC00==true || m_RK00S==true || m_RC00S==true) { if (newBW==300.00) filter=300.00; if (newBW==1500.00) Loading Loading @@ -1104,22 +1110,42 @@ void CCommandLine::setDefaultConfiguration(const IRA::CString & config) throw (C if (config.Compare("RK00")==0) { filter=1250.0; m_RK00=true; m_RC00=m_RL00=m_RP00=false; m_RC00=m_RL00=m_RP00=m_RK00S=m_RC00S=m_RL00S=m_RP00S=false; } if (config.Compare("RC00")==0) { filter=1250.0; m_RC00=true; m_RK00=m_RL00=m_RP00=false; m_RK00=m_RL00=m_RP00=m_RK00S=m_RC00S=m_RL00S=m_RP00S=false; } if (config.Compare("RL00")==0) { filter = 2300.0; m_RL00=true; m_RK00=m_RC00=m_RP00=false; m_RK00=m_RC00=m_RP00=m_RK00S=m_RC00S=m_RL00S=m_RP00S=false; } if (config.Compare("RP00")==0) { filter = 730.0; m_RP00=true; m_RK00=m_RC00=m_RL00=false; m_RK00=m_RC00=m_RL00=m_RK00S=m_RC00S=m_RL00S=m_RP00S=false; } if (config.Compare("RK00S")==0) { filter=1250.0; m_RK00S=true; m_RC00=m_RL00=m_RP00=m_RK00=m_RC00S=m_RL00S=m_RP00S=false; } if (config.Compare("RC00S")==0) { filter=1250.0; m_RC00S=true; m_RK00=m_RL00=m_RP00=m_RK00S=m_RC00=m_RL00S=m_RP00S=false; } if (config.Compare("RL00S")==0) { filter = 2300.0; m_RL00S=true; m_RK00=m_RC00=m_RP00=m_RK00S=m_RC00S=m_RL00=m_RP00S=false; } if (config.Compare("RP00S")==0) { filter = 730.0; m_RP00S=true; m_RK00=m_RC00=m_RL00=m_RK00S=m_RC00S=m_RL00S=m_RP00S=false; } try { m_totalPower->setSection(0,-1, filter, -1, -1, -1, -1); Loading Loading @@ -2008,6 +2034,7 @@ bool CCommandLine::initializeConfiguration(const IRA::CString & config) throw (C m_sections[m_boards[i]]=i; //m_input[i]=m_defaultInput[m_boards[i]]; m_polarization[i]=setup.polarizations[i]; printf ("m_polarization = %d\n", m_polarization[i]); m_ifNumber[i]=setup.ifs[i]; m_feedNumber[i]=setup.feed[i]; m_inputSection[i]=i; // input 0 belongs to section 0 and so on..... Loading
Common/Servers/Roach/src/Configuration.cpp +5 −3 Original line number Diff line number Diff line Loading @@ -119,11 +119,13 @@ bool CConfiguration::getSetupFromID(const IRA::CString setupID,TBackendSetup& se if (ret=="L") { setup.polarizations[i]=Backends::BKND_LCP; } else if (ret="R") { else if (ret=="R") { setup.polarizations[i]=Backends::BKND_RCP; } else else { setup.polarizations[i]=Backends::BKND_FULL_STOKES; } printf("setup.pol = %d\n", setup.polarizations[i]); if (!IRA::CIRATools::getNextToken(feed,start_feed,' ',ret)) return false; setup.feed[i]=ret.ToLong(); if (!IRA::CIRATools::getNextToken(ifs,start_ifs,' ',ret)) return false; Loading