Project

General

Profile

Get_TC

Added by Dosme Nicolas almost 14 years ago

Can we have a Get_TC function to get the information using XML format, for all TCs in current topology?
We just need in the result the list of "Triple Cluster".

But maybe you can add an other function Get_Crystals with one argument "TC ID" to get the list of crystal attached to this TC.


Replies (2)

RE: Get_TC - Added by Legay Eric almost 14 years ago

Hi,

We need this functionnality, so we implement it on our local TM for development use.
We take this format, if you want use an other one, don't hesitate, just tell us the one you will take.

<devices>
  <device device_type="triple_crystal" name="TC1 status="on"></device>
  <device device_type="triple_crystal" name="test status="on"></device>
  <device device_type="triple_crystal" name="GRRRR status="on"></device>
  <device device_type="triple_crystal" name="Yahou2 status="on"></device>
</devices>

RE: Get_TC - Added by Guevara Luz over 13 years ago

In the r13, i added a generic function 'Get_List_Device_Type' (If you agree, in order to replace the functions get_crystals, get_TC, get_....etc) :

Input Parameters:
- Device type : Crystal, adc, digitizer, triple_cluster, etc

Response:
- String : XML String with the same format that you have proposed above. Depending on the device type, the number of returned parameters in the xml string will be different.

Example 1: Get_List_Device_Type (Crystal)
<devices>
<device name="crystal001" color="green" father="1" status="on" id="1" ></device>
<device name="crystal002" color="green" father="1" status="off" id="2"></device>
<device name="crystal003" color="green" father="1" status="off" id="3"></device>
<device name="crystal004" color="green" father="1" status="off" id="4"></device>
<device name="crystal005" color="green" father="1" status="off" id="5"></device>
<device name="crystal006" color="green" father="1" status="off" id="6"></device>
</devices>

Example 2: Get_List_Device_Type (Triple_Cluster)
<devices>
<device name="tc001" position="10" status="off" id="1"></device>
<device name="tc002" position="15" status="off" id="2"></device>
<device name="tc003" position="150" status="off" id="3"></device>
</devices>

    (1-2/2)