Commit ed77f93b authored by mfioren's avatar mfioren
Browse files

Added cfg attributes, updated get_cfg

parent c635275d
Loading
Loading
Loading
Loading
+4 −1
Original line number Diff line number Diff line
@@ -33,5 +33,8 @@
		<temps_2 description="temperature on board 2" />
		<temps_3 description="temperature on board 3" />
		<temps_4 description="temperature on board 4" />

   <cfg_1 description="configuration on board 1" />
	<cfg_2 description="configuration on board 2" />
	<cfg_3 description="configuration on board 3" />
	<cfg_4 description="configuration on board 4" />
</SRTDBESM>
+4 −0
Original line number Diff line number Diff line
@@ -48,6 +48,10 @@
	   	 <xs:element name="temps_2" type="baci:ROdouble" />
	   	 <xs:element name="temps_3" type="baci:ROdouble" />
	   	 <xs:element name="temps_4" type="baci:ROdouble" />
	    <xs:element name="cfg_1" type="baci:ROstring" />
	    <xs:element name="cfg_2" type="baci:ROstring" />
	    <xs:element name="cfg_3" type="baci:ROstring" />
	    <xs:element name="cfg_4" type="baci:ROstring" />
      </xs:sequence>
       <xs:attribute name="addr_1" type="xs:long" use="required"/>
	    <xs:attribute name="addr_2" type="xs:long" use="required"/>
+65 −123
Original line number Diff line number Diff line
@@ -17,164 +17,106 @@ module Backends {
	@
	*/
	interface SRTDBESM: ACS::CharacteristicComponent {
	/*

	 DBESM boards addresses and components values

	/*
	 DBESM boards addresses 
        */
        readonly attribute ACS::ROlong addr_1, addr_2, addr_3, addr_4;

	/*
	 DBESM boards registers values
        */
        readonly attribute ACS::ROlongSeq regs_1, regs_2, regs_3, regs_4;

	/*
	 DBESM boards attenuators values
        */
	readonly attribute ACS::ROdoubleSeq atts_1, atts_2, atts_3, atts_4;

        /*
	 DBESM boards amplifiers values
        */
	readonly attribute ACS::ROlongSeq amps_1, amps_2, amps_3, amps_4;

        /*
	 DBESM boards addresses and components values
        */
	readonly attribute ACS::ROlongSeq eqs_1, eqs_2, eqs_3, eqs_4;

        /*
	 DBESM boards band-pass filters values
        */
	readonly attribute ACS::ROlongSeq bpfs_1, bpfs_2, bpfs_3, bpfs_4;

        /*
	 DBESM boards voltage values
        */
	readonly attribute ACS::ROdoubleSeq volts_1, volts_2, volts_3, volts_4;

        /*
	 DBESM boards temperature values
        */
	readonly attribute ACS::ROdouble temps_1, temps_2, temps_3, temps_4;

	void set_all(in string cfg_name) raises (BackendsErrors::BackendsErrorsEx);

	void set_mode(in short b_addr, in string cfg_name) raises (BackendsErrors::BackendsErrorsEx);

	void set_att(in short b_addr, in short out_ch, in double att_val) raises (BackendsErrors::BackendsErrorsEx);

	void store_allmode(in string cfg_name) raises (BackendsErrors::BackendsErrorsEx);

	void clr_mode(in string cfg_name) raises (BackendsErrors::BackendsErrorsEx);

	string get_status(in short b_addr) raises (BackendsErrors::BackendsErrorsEx);

	string get_comp(in short b_addr) raises (BackendsErrors::BackendsErrorsEx);

	string get_diag(in short b_addr) raises (BackendsErrors::BackendsErrorsEx);

	string get_cfg() raises (BackendsErrors::BackendsErrorsEx);

        string dbe_att(in string out_dbe, in string att_val) raises (BackendsErrors::BackendsErrorsEx);

//	string get_diag_all() raises (BackendsErrors::BackendsErrorsEx);
        /*
	 names of configurations currently set on the DBESM boards
        */
        readonly attribute ACS::ROstring cfg_1, cfg_2, cfg_3, cfg_4;

	/**
        /*
	 set whole DBESM configuration 
        */
	void set_all(in string cfg_name) raises (BackendsErrors::BackendsErrorsEx);

	/**
	 set single DBESM board configuration 
        /*
	 set a single DBESM board configuration
        */
	void set_mode(in short b_addr, in string cfg_name) raises (BackendsErrors::BackendsErrorsEx);

	/**
	 delete DBESM configuration
        */
	/**
	 set a single DBESM attenuator based on which output to attenuate
        /*
	 set a single DBESM attenuator on a particular board and channel
        */
	void set_att(in short b_addr, in short out_ch, in double att_val) raises (BackendsErrors::BackendsErrorsEx);

	/**
        /*
	 store whole DBESM configuration
        */
	/**
	 set the DBESM amplifliers 
	
	void set_amp(in short b_addr, in short amp_ch, in double amp_val) raises (BackendsErrors::BackendsErrorsEx);
	
	
	 set the DBESM equalizers 

	
	void set_eq(in short b_addr, in short eq_ch, in double eq_val) raises (BackendsErrors::BackendsErrorsEx);
	
	
	 set the DBESM band-pass filters 

	
	
	void set_bpf(in short b_addr, in short bpf_ch, in double bpf_val) raises (BackendsErrors::BackendsErrorsEx);
	void store_allmode(in string cfg_name) raises (BackendsErrors::BackendsErrorsEx);

        /*
	 delete DBESM configuration
        */
	void clr_mode(in string cfg_name) raises (BackendsErrors::BackendsErrorsEx);

        /**
	 get DBESM registers values 
	 
	 
    * @throw ReceiversErrors::ReceiversErrorsEx
    * @throw CORBA::SystemExcpetion 
	

	ACS::uLongSeq get_reg_val(in short b_addr, out long reg_val) raises (BackendsErrors::BackendsErrorsEx);
	
	/**
	 get single DBESM board attenuators values 

	
	ACS::doubleSeq get_att(in short b_addr) raises (BackendsErrors::BackendsErrorsEx);
	
	/**
	 get single DBESM board amps values 

	
	ACS::uLongSeq get_amp(in short b_addr) raises (BackendsErrors::BackendsErrorsEx);
	/**
	 get single DBESM board eqs values 

	
	ACS::uLongSeq get_eq(in short b_addr) raises (BackendsErrors::BackendsErrorsEx);
	/**
	 get single DBESM board bpfs values 

	
	ACS::uLongSeq get_bpf(in short b_addr) raises (BackendsErrors::BackendsErrorsEx);

	/**
	 get single DBESM board voltages 

	
	ACS::doubleSeq get_voltage(in short b_addr) raises (BackendsErrors::BackendsErrorsEx);

	/**
	 get single DBESM board temperature 

	ACS::doubleSeq get_temp(in short b_addr) raises (BackendsErrors::BackendsErrorsEx);







	/**
        /*
	 get single DBESM board status: registers and attenuators values
        */
	void get_status(in short b_addr) raises (BackendsErrors::BackendsErrorsEx);

	
	
	

	/**
        /*
	 get single DBESM board amps, eqs and bpfs values 
        */
	void get_comp(in short b_addr) raises (BackendsErrors::BackendsErrorsEx);

	

	
	/**
        /*
	 get single DBESM board voltages and temperatures 
        */
	void get_diag(in short b_addr) raises (BackendsErrors::BackendsErrorsEx);

        /*
	 get configurations currently set on the DBESM boards
        */
	void get_cfg() raises (BackendsErrors::BackendsErrorsEx);

        /*
	 set one or more attenuators depending on which output is requested
        */
        void set_dbeatt(in string out_dbe, in string att_val) raises (BackendsErrors::BackendsErrorsEx);


	
	/**
	 get whole DBESM voltages and temperatures 


	

	
        /*
	 get one or more attenuator values depending on which output is requested
        */
        void get_dbeatt(in string out_dbe) raises (BackendsErrors::BackendsErrorsEx);
	
};

+8 −2
Original line number Diff line number Diff line
@@ -76,7 +76,9 @@ public:
   
   string get_cfg();
   
   string dbe_att(const char * out_dbe, const char * att_val);
   string set_dbeatt(const char * out_dbe, const char * att_val);
   
   string get_dbeatt(const char * out_dbe);
			
	void parse_longSeq_response(string status_str, string start, string end, ACS::longSeq* vals); //throw (BackendsErrors::BackendsErrorsEx);
   
@@ -84,6 +86,8 @@ public:
   
   void parse_double_response(string status_str, string start, string end, double* val); //throw (BackendsErrors::BackendsErrorsEx);
   
   void CCommandSocket::parse_string_response(string status_str, string start, string end, string* val);
      
protected:
	/**
	 * Automatically called by the framework as a result of a connection request. See super-class for more details.
@@ -132,7 +136,9 @@ private:
	
	string get_cfg_command();
	
	string dbe_att_command(const char * out_dbe, const char * att_val);
	string set_dbeatt_command(const char * out_dbe, const char * att_val);
	
	string get_dbeatt_command(const char * out_dbe);
	
};

+10 −0
Original line number Diff line number Diff line
@@ -78,6 +78,11 @@ public:
	inline double temps_3() const { return m_temps_3; }
	inline double temps_4() const { return m_temps_4; }
	                    
	inline char * cfg_1() const { return m_cfg_1; }
	inline char * cfg_2() const { return m_cfg_2; } 
	inline char * cfg_3() const { return m_cfg_3; } 
   inline char * cfg_4() const { return m_cfg_4; } 
                    
private:

	long m_addr_1;
@@ -122,6 +127,11 @@ private:
   double m_temps_3;
   double m_temps_4;

   char * m_cfg_1 = new char[20];
   char * m_cfg_2= new char[20];
   char * m_cfg_3= new char[20];
   char * m_cfg_4= new char[20];
   
};

#endif /*CONFIGURATION_H_*/
Loading