SEG 25-Oct-99 Making Multi-Chain Control Files 1. Start up IDL NOT as MDI user (i.e. log in under your account) unix-prompt>idl 2. Start up xset_chains idl>xset_chains 3. Click and drag on 1st Campaign button and choose the campaign desired. You may need to drag the window all the way to the top to view the lower listed campaigns in the menu. 4. Click and drag the subsequent campaigns desired. 5. When the campaigns are chosen the Offset location ("page") used will appear to the right of the campaign. This offset location will be used to set the extract coordinates of the offset location down below. 6. Once the Offset location is determined you can set the coordinates of the extract region for that Offset location in the boxes below the chain campaign listings. Click in the box for the Offset location desired and enter the coordinates (format = x,y) FOLLOWED by a carriage return. 7. Once the various campaigns and extract coordinates have been chosen, click on the button "Write out file". This will actually create the control file containing the commands to set up the multiple chaining. You should see, in the idl text window, the contents of the control file and the name of the control file. Here is an example of what will be seen in the idl text window: program "%Z% MODULE: %M% RELEASE: %R%.%L% CREATED: %G% %U%" #======================================================= source "/md87/people/covingto/set_chains9610.src" descr "set_chains - Sets the chain addresses" # # File created: 15-OCT-96 17:31:16 UT by covingto # tcb mbsqreg 73 0x0600 ## 1536 cam_phase_div tcb mbsqreg 151 0x0600 ## 1536 cam_phase_div tcb mbsqreg 152 0x0742 ## 1858 cam_hr_dynamics3 tcb mbsqreg 153 0xffff ## 65535 None tcb mbsqreg 154 0xffff ## 65535 None tcb mbsqreg 155 0xffff ## 65535 None tcb mbsqreg 156 0xffff ## 65535 None tcb mbsqreg 157 0xffff ## 65535 None tcb mbsqreg 158 0xffff ## 65535 None tcblock mbdpml 0x1000 0x40C0 0x0000 0x0000 ##10 0,0 % Compiled module: SCRATCH. 8. Once the file has been written out click on the exit button, then go to mdicmd and freeze the file: mdicmd-covingto> freeze /md87/people/covingto/set_chains9610.src this will send the control file to the "flight" directory making it ready to be uploaded. Here is an example of what will be seen after freezing the file: /md87/people/covingto/set_chains9610.src--> /mdisw/cfl/prep/src/set_chains9610_v01.src 9. You may want to got to that directory and more the file to make sure that it is the correct file. 10. If any errors are made it is best to completely exit xset_chains and start again to be safe. 11. Sometimes you may need to make a chain list that includes commands to set the New flag and address. These commands must be like the other tcblock commands that xset_chains generates for you, although, you must manually edit your file with the commands. Therefore, after you have generated a chain list to set the chain, hit the quit button and edit the file in emacs or vi BEFORE YOU FREEZE THE FILE ON MDICMD!! Here is an example: program "%Z% MODULE: %M% RELEASE: %R%.%L% CREATED: %G% %U%" #======================================================= source "/md87/people/gregory/set_chains9910.src" descr "set_chains - Sets the chain addresses" # # File created: 22-OCT-99 16:14:17 UT by gregory # tcb mbsqreg 69 0x0984 ## 2436 new_cam_addr tcb mbsqreg 68 1 ## enable new flag tcb mbsqreg 73 0x0984 ## 2436 cam_p30vr_fd_m1 tcb mbsqreg 151 0x0984 ## 2436 cam_p30vr_fd_m1 tcb mbsqreg 152 0x0984 ## 2436 cam_p30vr_fd_m1 tcb mbsqreg 153 0x0984 ## 2436 cam_p30vr_fd_m1 tcb mbsqreg 154 0x0984 ## 2436 cam_p30vr_fd_m1 tcb mbsqreg 155 0x0984 ## 2436 cam_p30vr_fd_m1 tcb mbsqreg 156 0x0984 ## 2436 cam_p30vr_fd_m1 tcb mbsqreg 157 0x0984 ## 2436 cam_p30vr_fd_m1 tcb mbsqreg 158 0x0984 ## 2436 cam_p30vr_fd_m1 where: tcb mbsqreg 69 0x0984 ## 2436 new_cam_addr tcb mbsqreg 68 1 ## enable new flag are the manually inserted commands. Note that "tcb mbsqreg 69" or "tcb mbsqreg 68 1" are always supposed to be there in order to correctly set the new address or enable the new flag. The numbers 69 and 68 were taken from the q_seq_options_v09 file, "tcblock mbsqreg 69" sets the New address to what ever is specified, while "tcblock mbsqreg 68" always enables the New flag. However, the hex number "0x0984" for the new address must match the hex number "0x0984" for the commands generated by xset_chains. Also, note the hex number to enable the new flag is 1, this is always true. In other words, the only hex number that you need to double check is the hex number for the first command to set the new address. You can double check this by typing "dectohex ####" where #### is the campaign address. In this particular example, the command was "dectohex 2436" for cam_p30vr_fd_m1 and the output was 984. Thus, the correct hex number to enter into the command line is 0x0984 which correctly matches the hex numbers generated by xset_chains. NOTE: In the set_chains file, you can mix dec and hex numbers. If you look at http://mdisas.nascom.nasa.gov/manual/tcblock_cmds.txt this page tells you what the different tcblock commands are for various procedures such as setting the New address and flag. On this page everything is in hex, for example: Set new cam addr to campaign 2116 (hex=844) mbsqreg,0045,0844 Set new cam flag to on mbsqreg,0044,0001 These commands are the same as the ones above in the xset_chains list, however, they are all in hex. Where it says, "mbsqreg,0045,0844", this translates into "mbsqreg 69 0x0844" for cam_p30c_fd_m1, where 0x0844 is hex for campaign address 2116 and 0045 is hex for 69. Where it says, "mbsqreg,0044,0001", this translates into "mbsqreg 68 1", where 0044 is hex for 68. Also note, the 1 is the same to enable the New flag. 12. Once the file has been correctly edited with the correct tcblock commands, you can save the file exit your editor and the got to mdicmd and freeze the file as shown above in step 8. 13. The next step is to make a "make_loads" file, see: http://mdiwww/manual/commanding_bkd_del.txt NOTE: If you are mixing hex and decimal numbers in the chain list, the make_loads programs will correctly convert the decimal numbers to hex.