# File: track_rot_v01.src
#
program "%Z% MODULE: %M% RELEASE: %R%.%L% CREATED: %G% %U%"
source "/mdisw/cfl/prep/src/track_rot_v01.src"
descr "Loads IP queue instructions"
#=======================================================
#
#
#;
#; FILE:    track_rot.ips
#; PURPOSE: Adjust the extract location to adjust for rotation
#; METHOD:
#;	IPRL_TRACK_NMIN		- number of minutes before increment
#;	IPRL_TRACK_NPIX		- number of pixels to move extract
#;	IPRL_TRACK_NPIX_MAX	- maximum number of pixels to move
#;
#;	IPRL_TRACK_IMIN		- counter for N minutes (count down)
#;	IPRL_TRACK_EXTRACT (2)	- offset location (low/high)
#;	IPRL_TRACK_OFFSET	- number of pixels to add to extract
#; HISTORY: Written 1-Oct-96 by M.Morrison
#;
#QSR_TRACK_ROT::
#    BRANCHNE R3072 1 &SET_EXTRACT				;only count minutes on frame
tcblock mbipmacl 0x0B50    0x01B0 0x0C00 0x0001 0x0B6A 
#
#    ADDREGD  $IPRL_TRACK_IMIN -1
tcblock mbipmacl 0x0B54    0x01BC 0x151E 0xFFFF 
#    BRANCHGT $IPRL_TRACK_IMIN 0 &SET_EXTRACT			;not time to incre
tcblock mbipmacl 0x0B57    0x01BA 0x151E 0x0000 0x0B6A 
#
#    REGSUB   $IPRL_TRACK_NPIX_MAX $IPRL_TRACK_OFFSET $IPRL_JUNK_R
tcblock mbipmacl 0x0B5B    0x2146 0x151D 0x1521 0x0DF0 
#    BRANCHLT $IPRL_JUNK_REG 1 &SET_EXTRACT			;no incrementing of 
tcblock mbipmacl 0x0B5F    0x01B8 0x0DF0 0x0001 0x0B6A 
#								;if equal 0 (reached max) or less
#
#    REGADD   $IPRL_TRACK_OFFSET $IPRL_TRACK_NPIX $IPRL_TRACK_OFFS
tcblock mbipmacl 0x0B63    0x0146 0x1521 0x151C 0x1521 
#    COPYREG  $IPRL_TRACK_NMIN $IPRL_TRACK_IMIN    
tcblock mbipmacl 0x0B67    0x0142 0x151B 0x151E 
#
#SET_EXTRACT:							;overwrite copy in camera header
#    REGADD   $IPRL_TRACK_OFFSET $IPRL_TRACK_EXTRACT R3078	;low - 
tcblock mbipmacl 0x0B6A    0x0146 0x1521 0x151F 0x0C06 
#								;the 16 bit number because IPRL_TRACK_NPIX_MAX
#								;will be less than 1024
#    COPYREG  $IPRL_TRACK_EXTRACT+1  R3079			;high
tcblock mbipmacl 0x0B6E    0x0142 0x1520 0x0C07 
#
#DONE:
#    RTNQUE
tcblock mbipmacl 0x0B71    0x01FA 
#=======================================================
#
return
#
#=======================================================
