# # slitscan.pro # # Usage: call slitscan size1 n nscans # # Take a scan of n spectra along the slit evenly spaced by size1 arcsec. The # star should be centered along the slit. The telescope is returned to center # after the slit scan. Requires the correct value of the rotator angle to be # set by zcenter.pro. Rot is given in degrees. Repeat the scan nscans times. # parameter size1 n nscans yorn 'Disable the tip tilt guider during offsets?' if (yorn==1) usetip=1 else usetip=2 end_if if (n==0.0)|(size1==0.0) ask 'Number of spectra to take along slit?' n ask 'What is the separation between spectra (arcsec)?' size1 end_if if (nscans==0) ask 'Number of scans?' nscans end_if call askpars theta=271.5-rot # # this is the basic step # stepn=size1*sind[theta] stepe=size1*cosd[theta] # # set to the end of the slit from the middle or middle from the end # on1=(1-n)*0.5*stepn oe1=(1-n)*0.5*stepe yorn 'Are the OBSERVE params OK and TELESCOPE centered' if (yorn~=1) printf 'Aborting sequence: reset parameters/center telescope' printf 'and try again' return end_if # # begin sequence # do j=1,nscans if (usetip==1) call ttd end_if offset ra=oe1 dec=on1 twait=0 printf 'offset %f6.2 %f6.2' oe1 on1 if (usetip==1) call tte end_if avego $coad do i=1,n-1 if (usetip==1) call ttd end_if printf 'offset %f6.2 %f6.2' stepe stepn offset ra=stepe dec=stepn if (usetip==1) call tte end_if avego $coad end_do # # return to center # if (usetip==1) call ttd end_if printf 'offset %f6.2 %f6.2' oe1 on1 offset ra=oe1 dec=on1 twait=0 if (usetip==1) call tte end_if end_do alert 'SCAN COMPLETED' 3 1 return