| 1 |
C @(#)gd8z.for 19.1 (ES0-DMD) 02/25/03 13:55:09 |
| 2 |
C=========================================================================== |
| 3 |
C Copyright (C) 1995 European Southern Observatory (ESO) |
| 4 |
C |
| 5 |
C This program is free software; you can redistribute it and/or |
| 6 |
C modify it under the terms of the GNU General Public License as |
| 7 |
C published by the Free Software Foundation; either version 2 of |
| 8 |
C the License, or (at your option) any later version. |
| 9 |
C |
| 10 |
C This program is distributed in the hope that it will be useful, |
| 11 |
C but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 12 |
C MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 13 |
C GNU General Public License for more details. |
| 14 |
C |
| 15 |
C You should have received a copy of the GNU General Public |
| 16 |
C License along with this program; if not, write to the Free |
| 17 |
C Software Foundation, Inc., 675 Massachusetss Ave, Cambridge, |
| 18 |
C MA 02139, USA. |
| 19 |
C |
| 20 |
C Corresponding concerning ESO-MIDAS should be addressed as follows: |
| 21 |
C Internet e-mail: [email protected] |
| 22 |
C Postal address: European Southern Observatory |
| 23 |
C Data Management Division |
| 24 |
C Karl-Schwarzschild-Strasse 2 |
| 25 |
C D 85748 Garching bei Muenchen |
| 26 |
C GERMANY |
| 27 |
C=========================================================================== |
| 28 |
C |
| 29 |
SUBROUTINE GD8012(DISPLAY,CHAN,NOCHAN,SCX,SCY,IDST) |
| 30 |
C |
| 31 |
C++++++++++++++++++++++++++++++++++++++++++++++++++ |
| 32 |
C |
| 33 |
C.IDENTIFICATION |
| 34 |
C subroutine IIWSC version 1.00 880125 |
| 35 |
C K. Banse ESO - Garching |
| 36 |
C |
| 37 |
C.KEYWORDS |
| 38 |
C DeAnza, memory, scroll |
| 39 |
C |
| 40 |
C.PURPOSE |
| 41 |
C fulfill the requirements as described in the IDI document |
| 42 |
C |
| 43 |
C.ALGORITHM |
| 44 |
C use DeAnza level 0 software |
| 45 |
C |
| 46 |
C.INPUT/OUTPUT |
| 47 |
C call as IIZWSC(DISPLAY,CHAN,NOCHAN,SCX,SCY,IDST) |
| 48 |
C |
| 49 |
C input par: |
| 50 |
C DISPLAY: I*4 display id. |
| 51 |
C CHAN: I*4 array memory ids |
| 52 |
C NOCHAN: I*4 no. of memory ids |
| 53 |
C SCX: I*4 x-scroll value |
| 54 |
C SCY: I*4 y-scroll value |
| 55 |
C |
| 56 |
C output par: |
| 57 |
C IDST: I*4 return status |
| 58 |
C |
| 59 |
C-------------------------------------------------- |
| 60 |
C |
| 61 |
IMPLICIT NONE |
| 62 |
C |
| 63 |
INTEGER*4 DISPLAY,CHAN(1),NOCHAN,SCX,SCY,IDST |
| 64 |
INTEGER*4 SCRTOP,N,NN |
| 65 |
C |
| 66 |
INTEGER*2 UNIT,SC,C1,NSCX,NSCY |
| 67 |
INTEGER*2 LMC |
| 68 |
C |
| 69 |
INCLUDE 'MID_INCLUDE:DEANZAH.INC' |
| 70 |
INCLUDE 'MID_INCLUDE:DEANZAS.INC' |
| 71 |
INCLUDE 'MID_INCLUDE:IDIDEV.INC' |
| 72 |
INCLUDE 'MID_INCLUDE:IDIMEM.INC' |
| 73 |
C |
| 74 |
EXTERNAL LMC |
| 75 |
C |
| 76 |
DATA C1 /"176000/ |
| 77 |
C |
| 78 |
SCRTOP = QDSZY - 1 !top line on screen |
| 79 |
C |
| 80 |
UNIT = DISPLAY |
| 81 |
NSCX = - SCX !offsets from 0,0 are |
| 82 |
NSCY = SCRTOP - SCY !to DeAnza 0,511 business... |
| 83 |
C |
| 84 |
C set up scroll value in DeAnza memory |
| 85 |
C bits X9 - X0 in reg.0 and bits Y9 - Y0 in reg. 1 |
| 86 |
C |
| 87 |
DO NN=1,NOCHAN |
| 88 |
N = CHAN(NN) + 1 |
| 89 |
C |
| 90 |
MEMREG(1,N) = IAND(MEMREG(1,N),C1) !clear scroll |
| 91 |
SC = IAND(NSCX,"001777) !cut out last 10 bits |
| 92 |
MEMREG(1,N) = IOR(MEMREG(1,N),SC) |
| 93 |
C |
| 94 |
MEMREG(2,N) = IAND(MEMREG(2,N),C1) !clear scroll |
| 95 |
SC = IAND(NSCY,"001777) !cut out last 10 bits |
| 96 |
MEMREG(2,N) = IOR(MEMREG(2,N),SC) |
| 97 |
C |
| 98 |
C and send it to the DeAnza |
| 99 |
CALL IP8QW(LMC,UNIT,DZIOSB,,,MEMREG(1,N),4,CHAN(NN),0) |
| 100 |
ENDDO |
| 101 |
C |
| 102 |
C alright then... |
| 103 |
IDST = 0 |
| 104 |
RETURN |
| 105 |
END |
| 106 |
|
| 107 |
SUBROUTINE GD8013(DISPLAY,CHAN,NOCHAN,ZOOM,IDST) |
| 108 |
C |
| 109 |
C++++++++++++++++++++++++++++++++++++++++++++++++++ |
| 110 |
C |
| 111 |
C.IDENTIFICATION |
| 112 |
C subroutine IIZWZM version 1.00 880118 |
| 113 |
C K. Banse ESO - Garching |
| 114 |
C |
| 115 |
C.KEYWORDS |
| 116 |
C DeAnza, memory, scroll |
| 117 |
C |
| 118 |
C.PURPOSE |
| 119 |
C fulfill the requirements as described in the IDI document |
| 120 |
C |
| 121 |
C.ALGORITHM |
| 122 |
C use DeAnza level 0 software |
| 123 |
C |
| 124 |
C.INPUT/OUTPUT |
| 125 |
C call as IIDZWZM(DISPLAY,CHAN,NOCHAN,ZOOM,IDST) |
| 126 |
C |
| 127 |
C input par: |
| 128 |
C DISPLAY: I*4 display id. |
| 129 |
C CHAN: I*4 array memory ids |
| 130 |
C NOCHAN: I*4 no. of memory ids |
| 131 |
C ZOOM: I*4 zoom factor |
| 132 |
C |
| 133 |
C output par: |
| 134 |
C IDST: I*4 return status |
| 135 |
C |
| 136 |
C-------------------------------------------------- |
| 137 |
C |
| 138 |
IMPLICIT NONE |
| 139 |
C |
| 140 |
INTEGER*4 DISPLAY,CHAN(1),NOCHAN,ZOOM,IDST |
| 141 |
INTEGER*4 N,NN |
| 142 |
C |
| 143 |
INTEGER*2 UNIT,IZ,IZO |
| 144 |
INTEGER*2 LMC |
| 145 |
C |
| 146 |
INCLUDE 'MID_INCLUDE:DEANZAH.INC' |
| 147 |
INCLUDE 'MID_INCLUDE:DEANZAS.INC' |
| 148 |
C |
| 149 |
EXTERNAL LMC |
| 150 |
C |
| 151 |
UNIT = DISPLAY |
| 152 |
C |
| 153 |
C set up zoom value in DeAnza memory |
| 154 |
C bits Z3 - Z0 (15 - 13) in reg.0 and bits Z3 - Z0 (15 - 13) in reg. 1 |
| 155 |
C |
| 156 |
DO NN=1,NOCHAN |
| 157 |
N = CHAN(NN) + 1 |
| 158 |
IZ = IAND((ZOOM-1),"000007) !cut out last 3 bits of ZOOM - 1 |
| 159 |
IZO = ISHFT(IZ,13) |
| 160 |
MEMREG(1,N) = IAND(MEMREG(1,N),"017777) !clear zoom |
| 161 |
MEMREG(1,N) = IOR(MEMREG(1,N),IZO) |
| 162 |
MEMREG(2,N) = IAND(MEMREG(2,N),"017777) |
| 163 |
MEMREG(2,N) = IOR(MEMREG(2,N),IZO) |
| 164 |
C |
| 165 |
C and send it to the DeAnza |
| 166 |
CALL IP8QW(LMC,UNIT,DZIOSB,,,MEMREG(1,N),4,CHAN(NN),0) |
| 167 |
ENDDO |
| 168 |
C |
| 169 |
C alright then... |
| 170 |
IDST = 0 |
| 171 |
RETURN |
| 172 |
END |