##########################                                            ##-#
#                                                                     ##-#
# Assembled by checkpoint, 1.18.2 (23-Sep-99).                        ##-#
# (EDIT THE ORIGINAL SOURCE, NOT THIS FILE!)                          ##-#
# Date-assembled: Mon Jul  5 14:13:51 EDT 2010                        ##-#
# Orig-source: /mdisw/cfl/flight/src/obs_std_head_v51.src             ##-#
#                                                                     ##-#
##########################                                            ##-#
program "%Z% MODULE: %M% RELEASE: %R%.%L% CREATED: %G% %U%"
source "/mdisw/cfl/flight/src/q_obs_std_head_v51.src"
descr  "Loads a DEP Frame List"
                                                                      ##-#
#=#=#=#=#=#=#=#=#=#=# src ln 4.  (Open Log file)                      ##-#
if !GS9 = "" then                                                     ##-#
  display "Opening logfile from q_obs_std_head_v51"                   ##-#
  perf openlog                                                        ##-#
end if                                                                ##-#
write !GS9 "%s q_obs_std_head_v51:" !TIME                             ##-#
writen !GS9 "Starting..."                                             ##-#
#=#=#=#=#=#=#=#=#=#=#+ src ln 4.  Block 0  Next line is #21           ##-#
 display "Running block 0 of q_obs_std_head_v51."                     ##-#
set !LI0 = getint(mktccnt)                                            ##-#
queue on ## Queue next 6 commands.                                    ##-#
tcb mbdpml 0x1000 0x3DB0 0x0005 0x0AA1 0x0050 0x0000 0x0000 0x0007 
tcb mbdpml 0x1000 0x3DBC 0xFE38 0x8B1E 0x059B 0x0000 0x4343 0x4343 
tcb mbdpml 0x1000 0x3DC8 0xFE68 0x9430 0x058B 0x0000 0x4343 0x4343 
tcb mbdpml 0x1000 0x3DD4 0xFE98 0x9430 0x058B 0x0000 0x4343 0x4343 
tcb mbdpml 0x1000 0x3DE0 0xFEC8 0x8B1E 0x058B 0x0000 0x4343 0x4343 
tcb mbdpml 0x1000 0x3DEC 0xFEF8 0x820C 0x058B 0x0000 0x4343 0x4343 
queue off ## Synchronize w/ POCC                                      ##-#
# Enter new observation address into obs pointer table
tcb mbdpml 0x1000 0x407E 0x2D28
#=#=#=#=#=#=#=#=#=#=#- src ln 12.  Block 0   Cmds:7   Total:7         ##-#
wait time 8 ## Wait for hk packet                                     ##-#
set !LI2 = !LI0 + 7                                                   ##-#
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_head_v51:" !TIME                            ##-#
 writen !GS9  "CMD CT ERR in block 0. cmd ctr: %d" !LI2               ##-#
 writen !GS9  "      (Sent 7 cmds; expected cmd ctr: %d)" !LI1        ##-#
 writen !GS9  "      Halted.  (restart at line 21)"                   ##-#
 display "ERR: q_obs_std_head_v51 blk 0: cmd ctr isnt %d. (CONT 21)" !LI1##-#
 halt                                                                 ##-#
 write !GS9 "%s q_obs_std_head_v51:" !TIME                            ##-#
 writen !GS9  "Override.  Continuing past block 0..."                 ##-#
else                                                                  ##-#
 write !GS9 "%s q_obs_std_head_v51:" !TIME                            ##-#
 writen !GS9  "Block 0 completed OK."                                 ##-#
display "Completed block 0 of q_obs_std_head_v51."                    ##-#
end if                                                                ##-#
#################### END of BLOCK 0 ####################              ##-#
write !GS9 "%s q_obs_std_head_v51:" !TIME                             ##-#
writen !GS9 "Falling off the bottom."                                 ##-#
