Control of the MPI facility Schottky/SIS frontends G.Schneider, J.B.Schraml Version 1: June 1992 I.) INTRODUCTION: The MPI facility Schottky/SIS frontend control (FEC) is a self contained unit controlled by individual micro processors. It consists of a common optic part with choppers, calibration loads and an IF distribution. The beam is directed onto the individual frontends by means of mirrors and grating beam splitters. This is controlled by one micro processor. The individual high frequency detectors are controlled by their own micro processors, which tune the receivers and set the observing frequency. All processors are communicating along a local fiber optic serial link. The station computer (VAX) is hooked into that ring via a terminal server, it is just another node. The physical connection is via a RS232 terminal line of the station computer. For this purpose the particular line has to be set to SET TERM .../PERM/NOECHO/UNKNOWN/WID=132/PAR=EVEN/EIGHT/NOTTSYNC/SPEED=9600 II.) GENERAL: Communication between the FEC and the control VAX occurs through messages. Except for the very first configuration the messages send to the FEC have all the same format, the messages received from the FEC upon request also have the all the same format, that differs from the messages send by one more address. All characters are ASCII, all addresses and functions hexadecimal. All messages have to be finished by the carriage return character, which is abbrevated hereafter. Addresses are the addresses of the nodes which should pick up the information or send it. Two bytes are used, and the are abbrevated with . All general messages contain a 2 byte function code, which is abbrevated . 1.) TRANSMIT FORMAT: Character 1 : "W" Character 2,3 : of receiving node in the FEC Character 4,5 : function code optional ... : data n Bytes Character n+6 : ":" the : is used as a terminator of valid data Character n+7,n+8 : decimal length of valid data (unit :) = n+5 Character n+9 : After receiving the message, the node addressed answers with an acknowledge. The acknowledge consist of 2 bytes of data: "FF" if the request can be executed, otherwise with an error code. If the message was sent to an unactive node, no acknowledge will occur. This condition can be sensed by waiting for an excess response time. 2.) RECEIVE FORMAT: Character 1 : "W" Character 2,3 : of receiving node (own address) Character 4,5 : of sending node in the FEC Character 6,7 : function code optional ... : data n Bytes Character n+6 : ":" the : is used as a terminator of valid data Character n+8,n+9 : decimal length of valid data (unit :) = n+7 Character n+10 : The message has to be requested first by sending the proper polling function to the node of interest, wich then will return the information in the format as given above. III.) FIRST INITIALIZATION: At program start three steps have to be taken to initialize the node to which the station VAX is communicating. These steps again are executed by sending messages, but the format is different from the general FEC formats described above. 1.) get the 2 byte address of the own node "@FF" and the node will send the address, called from now on 2.) Initialize the node "I" send the address after an I 3.) disable timeout for the node "PT0000" Now the communication can start. It is advisable to perform this functions at the very start of the program., possibly with plausibility tests by polling some information. IV.) FUNCTIONS available up to now: The following is a list of the functions available now. For each function the observing program state (CONTROL) is given, in which this function should be requested. 1.) command functions: 1.1) **** CODE 04 Obs_flag Micro adress Optics Data: 0 (set the flag) CONTROL: MEASURE (start of subscan) 1 (clear the flag) CONTROL: FINISH (end of subscan) Remarks: While obs_flag is set, no command function other than clear is accepted. This way an unobstructed observation can be executed. 1.2)**** CODE 0A IF-connection between frontend and backend Micro adress Optics Data: First byte : Frontend Second byte: Backend CONTROL: INITIALIZE Remarks: This allows to connect the various frontends to the backends through the IF-distribution. Currently one message connects, the second time the same message disconnects the frontend. Therefore a polling function will be installed that allows to inquire the current configuration. 1.3)**** CODE 0E Hot-Sky-chopper Micro adress Optics Data : 1 Sky position 2 Absorber position 3 Rotating CONTROL: SETUP Remarks: If there is no calibration action requested (see below), this allows to change between total power and load switch mode. 1.4)**** CODE 0F Hot-Cold-chopper (calibration) Micro adress Optics Data : 0 calibration mirror removed 1 Cold position 2 Absorber position 3 Rotating CONTROL: SETUP, possibly INITIALIZATION Remarks: A mirror can be brought into the beam that allows to calibrate the noise temperature of the receiver. Note: during astronomical observations the mirror should be removed. If a calibration is requested, it should be done inside the setup procedure, than continuing with code 0F 1.5)**** CODE 11 Mirror/Gratings selection Micro adress Optics Data : 0 mirror 1 1 mirror 4 2 mirror 5 3 mirror 6 4 mirror 7 6 grating 1 7 grating 2 9 Filter CONTROL: INITIALIZE (possibly SETUP) Remarks: This allows to change the configuration of filters, mirrors and beam splitters. 1.6)**** CODE A0 Observing frequency, Side band Micro adress correct Frontend Data : MHz with "." and three digits of fraction Next character : L for lower side band U for upper side band CONTROL: SETUP, PREPARE Remarks: This is the actual Doppler corrected frequency. The conversion to the correct synthesizer and side band setting is done by the frontend micro. Note: the very last character always has to be the side band; thus no undefined state can arise in the real time application. 2.) Polling functions: 2.1)**** CODE 14 Status optics Micro adress Optics Data : 0 in beam 1 out of beam 2 error Remarks: This gives the current state of the beam chopper. The backend however uses hardware signals (SAM bus) rather than polling (timing) 2.2)**** CODE 16 Status Hot/Sky chopper Micro adress Optics Data : 1 Hot position 2 Absorber position 3 Rotating Remarks: This gives the state of the hot/sky chopper 2.2)**** CODE 17 Status Hot/Cold chopper Micro adress Optics Data : 0 calibration mirror removed 1 Cold position 2 Absorber position 3 Rotating Remarks: This gives the state of the calibration chopper 2.3)**** CODE 1F Status IF-distribution Micro adress Optics