##########################                                            ##-#
#                                                                     ##-#
# Assembled by checkpoint, 1.18.2 (23-Sep-99).                        ##-#
# (EDIT THE ORIGINAL SOURCE, NOT THIS FILE!)                          ##-#
# Date-assembled: Thu Aug 26 10:52:39 EDT 2010                        ##-#
# Orig-source: /mdisw/cfl/flight/src/obs_std_fd_mag_v50.src           ##-#
#                                                                     ##-#
##########################                                            ##-#
program "%Z% MODULE: %M% RELEASE: %R%.%L% CREATED: %G% %U%"
source "/mdisw/cfl/flight/src/q_obs_std_fd_mag_v50.src"
descr  "Loads a DEP Frame List"
                                                                      ##-#
#=#=#=#=#=#=#=#=#=#=# src ln 4.  (Open Log file)                      ##-#
if !GS9 = "" then                                                     ##-#
  display "Opening logfile from q_obs_std_fd_mag_v50"                 ##-#
  perf openlog                                                        ##-#
end if                                                                ##-#
write !GS9 "%s q_obs_std_fd_mag_v50:" !TIME                           ##-#
writen !GS9 "Starting..."                                             ##-#
#=#=#=#=#=#=#=#=#=#=#+ src ln 4.  Block 0  Next line is #21           ##-#
 display "Running block 0 of q_obs_std_fd_mag_v50."                   ##-#
set !LI0 = getint(mktccnt)                                            ##-#
queue on ## Queue next 11 commands.                                   ##-#
tcb mbdpml 0x1000 0x3BC4 0x000A 0x0AD9 0x0050 0x0000 0x0000 0x006F 
tcb mbdpml 0x1000 0x3BD0 0x0108 0x8A1C 0x05BB 0x0000 0x4040 0x4040 
tcb mbdpml 0x1000 0x3BDC 0x0138 0x8A1C 0x05CB 0x0000 0x4141 0x4141 
tcb mbdpml 0x1000 0x3BE8 0x0168 0x932E 0x05CB 0x0000 0x4242 0x4242 
tcb mbdpml 0x1000 0x3BF4 0x0198 0x932E 0x05AB 0x0000 0x4343 0x4343 
tcb mbdpml 0x1000 0x3C00 0x01C8 0x8137 0x05AB 0x0000 0x4444 0x4444 
tcb mbdpml 0x1000 0x3C0C 0x01F8 0x9C40 0x05AB 0x0000 0xC0C0 0xC0C0 
tcb mbdpml 0x1000 0x3C18 0x0228 0x9C40 0x05CB 0x0000 0xC1C1 0xC1C1 
tcb mbdpml 0x1000 0x3C24 0x0258 0xA552 0x05CB 0x0000 0xC2C2 0xC2C2 
tcb mbdpml 0x1000 0x3C30 0x0288 0xA552 0x05AB 0x0000 0xC3C3 0xC3C3 
tcb mbdpml 0x1000 0x3C3C 0x02B8 0x810A 0x058B 0x0000 0x4444 0x4444 
queue off ## Synchronize w/ POCC                                      ##-#
# Enter new observation address into obs pointer table
tcb mbdpml 0x1000 0x4070 0x2B3C
#=#=#=#=#=#=#=#=#=#=#- src ln 17.  Block 0   Cmds:12   Total:12       ##-#
wait time 8 ## Wait for hk packet                                     ##-#
set !LI2 = !LI0 + 12                                                  ##-#
if !LI2 > 255 then                                                    ##-#
 set !LI1 = !LI2 - 256                                                ##-#
else                                                                  ##-#
 set !LI1 = !LI2                                                      ##-#
end if                                                                ##-#
set !LI2 = getint(mktccnt)                                            ##-#
if !LI1 <> !LI2 then                                                  ##-#
 write !GS9 "%s q_obs_std_fd_mag_v50:" !TIME                          ##-#
 writen !GS9  "CMD CT ERR in block 0. cmd ctr: %d" !LI2               ##-#
 writen !GS9  "      (Sent 12 cmds; expected cmd ctr: %d)" !LI1       ##-#
 writen !GS9  "      Halted.  (restart at line 21)"                   ##-#
 display "ERR: q_obs_std_fd_mag_v50 blk 0: cmd ctr isnt %d. (CONT 21)" !LI1##-#
 halt                                                                 ##-#
 write !GS9 "%s q_obs_std_fd_mag_v50:" !TIME                          ##-#
 writen !GS9  "Override.  Continuing past block 0..."                 ##-#
else                                                                  ##-#
 write !GS9 "%s q_obs_std_fd_mag_v50:" !TIME                          ##-#
 writen !GS9  "Block 0 completed OK."                                 ##-#
display "Completed block 0 of q_obs_std_fd_mag_v50."                  ##-#
end if                                                                ##-#
#################### END of BLOCK 0 ####################              ##-#
write !GS9 "%s q_obs_std_fd_mag_v50:" !TIME                           ##-#
writen !GS9 "Falling off the bottom."                                 ##-#
