#File: dfc100a_d.src
program "%Z% MODULE: dfc100a_d.src RELEASE: %R%.%L% CREATED: %G% %U%"
# created 95.11.09 DPM  
#     Fixes an Error in TIM instruction which causes a delay of 1 tick.
#     The TIM instruction compares Mark time with LOBT. Although both 
#     times are 48 bit quantities bits 0-12 of Mark time are always set 
#     to zero. LOBT has bits 0-4 set to zero. Therefore the comparison 
#     fails even when the ms 36 bits match. The following patch corrects 
#     this by copying the low order bits from LOBT to MarkTime.
#Modified 12-Dec-95 by M.Morrison to add descr line
#
source "/mdisw/cfl/prepsrc/dfc100a_d.src"
descr "DEP Patch to fix time marks"

#Dump DEP memory prior to patch
tcblock mbdpmd 0 0x1650 160
wait time 3
#
tcb mbdpml 0 0x1650 0x8BFE 0xEA1E 0x8B4D 0xB107 0xD30C 0x8BE0 0x5816 0x8149 
tcb mbdpml 0 0x1660 0xFFE2 0x0B0F 0xA3C2 0x4EF4 0x078B 0x04B1 0xF8D3 0x8B99 
tcb mbdpml 0 0x1670 0x8C1E 0x8B40 0x8A0E 0x0340 0x13C8 0x89DA 0xF81E 0x894E 
tcb mbdpml 0 0x1680 0xF60E 0xA14E 0x495C 0x168B 0x495A 0x063B 0x4EF8 0x1D77 
tcb mbdpml 0 0x1690 0x2272 0x163B 0x4EF6 0x1577 0x1A72 0x58A1 0x3B49 0xF406 
tcb mbdpml 0 0x16A0 0x774E 0x720A 0xC70F 0xA006 0x034C 0xEB00 0xC73E 0xF646 
tcb mbdpml 0 0x16B0 0x0002 0x37EB 0x468B 0x89F8 0xFE46 0x06C7 0x4CA0 0x0004 
tcb mbdpml 0 0x16C0 0x29EB 0x27EB 0x25EB 0x23EB 0x21EB 0x1FEB 0x1DEB 0x1BEB 
tcb mbdpml 0 0x16D0 0x19EB 0x17EB 0x15EB 0x13EB 0x11EB 0x0FEB 0x0DEB 0x0BEB 
tcb mbdpml 0 0x16E0 0x09EB 0x07EB 0x05EB 
#
tcblock mbdpmd 0 0x1650 160
wait time 3
#
# Part 2: Set Seq Late Flag for missed time mark
#
tcblock mbdpmd 0 0x0836 32
wait time 3
#
tcb mbdpml 0 0x0836 0x7603 0xC706
tcb mbdpml 0 0x083E 0x8300 0x9E3E 0x024C 0x2375 0x00BE 0x8B40
#
tcblock mbdpmd 0 0x0836 32
wait time 3
#
##########################
# Patch to TAP instruction
##########################

# The following patch substitutes the statement,
#          status = SEQ_BREAK ( = 3)         in place of
#          seq_stt = SEQ_WAIT_CAMERA ( = 2)
# This returns control to the DEP after TAP instruction.
#
tcblock mbdpmd 0 0x159A 16
wait time 3
#
tcb mbdpml 0 0x159A 0xC78C 0xF646 0x0003 0xE990
#
tcblock mbdpmd 0 0x159A 16
wait time 3
#
tcb mbdpml   0x1000 0x8c96 0x0d10          ## update patch ver.

return
