-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathuserin26.scr
176 lines (126 loc) · 4.42 KB
/
userin26.scr
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
\ Electron Drift Instrument 17:17 12-13-90
(
Source Files
FOR THE USER INTERFACE
MULTITASKING SYSTEM FOR HIGH VOLTAGE CONTROL FOR EDI OPTICS
BY JOE RITTER, SLOBODAN BEROS, SCOTT WEISMAN
USER23.SCR
)
\ 15:47 10-08-90
: BEAM-ADJUST-LOW ( 'I,J/'i,j/^I,^J --- VAL )
DUP 96 AND 0= IF
DROP -1 \ CONTROL
ELSE DUP 96 AND 64 = IF
DROP -10 \ NORMAL
ELSE DUP 96 AND 96 = IF
DROP -1 \ SHIFT
THEN
THEN
THEN
;
\ 15:48 10-08-90
: BEAM-ADJUST-HI ( 'I,J/'i,j/^I,^J --- VAL )
DUP 96 AND 0= IF
DROP 1 \ CONTROL
ELSE DUP 96 AND 64 = IF
DROP 10 \ NORMAL
ELSE DUP 96 AND 96 = IF
DROP 1 \ SHIFT
THEN
THEN
THEN
;
\ 20:52 11-13-90
: X-ADJUST ( VAL --- )
XX +! XX @ 2000 < IF 2000 XX ! THEN
XX @ 9999 > IF 9999 XX ! THEN
;
: Y-ADJUST ( VAL --- )
YY +! YY @ 2000 < IF 2000 YY ! THEN
YY @ 9999 > IF 9999 YY ! THEN
;
\ 16:30 11-21-90
: SHIFTER-OLD \ SHIFT BEAM SHIFTER MANUALLY | KEY ---
DUP 31 AND 9 = IF BEAM-ADJUST-HI Y-ADJUST ELSE
DUP 31 AND 10 = IF BEAM-ADJUST-LOW X-ADJUST ELSE
DUP 31 AND 11 = IF BEAM-ADJUST-HI X-ADJUST ELSE
DUP 31 AND 13 = IF BEAM-ADJUST-LOW Y-ADJUST
THEN
THEN
THEN
THEN
CLRSTK
DISP-VALUES
XX @ IWX YY @ IWY
;
\ 22:23 12-03-90
: WX SHIFT-COMP @ IF CWX ELSE IWX THEN ;
: WY SHIFT-COMP @ IF CWY ELSE IWY THEN ;
: SHIFT-TOGGLE
SHIFT-COMP @ NOT SHIFT-COMP !
;
\ 22:19 12-03-90
: SHIFTER \ SHIFT BEAM SHIFTER MANUALLY | KEY ---
DUP 31 AND 13 = IF BEAM-ADJUST-HI Y-ADJUST ELSE
DUP 31 AND 10 = IF BEAM-ADJUST-LOW X-ADJUST ELSE
DUP 31 AND 11 = IF BEAM-ADJUST-HI X-ADJUST ELSE
DUP 31 AND 9 = IF BEAM-ADJUST-LOW Y-ADJUST
THEN
THEN
THEN
THEN
CLRSTK
DISP-VALUES
XX @ WX YY @ WY
;
\ 10:05 12-28-90
DECIMAL
: CHKKEY-OLD ( N --- 0-F HEX OR G-Z ASCII )
DUP 13 = IF DROP 32 0 ELSE \ IF CR THEN GOOD,BUT MAKE SPACE
DUP 47 <= IF DROP -1 ELSE \ IF < '0' THEN ERROR
DUP 57 <= IF 48 - 0 ELSE \ IF '0'-'9' THEN CONVERT
DUP 64 <= IF DROP -1 ELSE \ IF BET '0' & 'A' THEN ERROR
DUP 70 <= IF 55 - 0 ELSE \ IF 'A'-'F' THEN CONVERT
DUP 91 >= IF DROP -1 ELSE \ IF > 'Z' THEN ERROR
0 \ ELSE BET 'G' & 'Z'
THEN THEN THEN THEN THEN \ 0 IS FLAG FOR VALID INPUT
THEN ;
\ 14:24 10-08-90
DECIMAL
: CHKKEY ( N --- 0-F HEX OR G-Z ASCII )
DUP 13 = IF DROP 32 0 ELSE \ IF CR THEN GOOD,BUT MAKE SPACE
DUP 47 <= IF 0 ELSE \ IF <'0' THEN LEAVE ALONE
DUP 57 <= IF 48 - 0 ELSE \ IF '0'-'9' THEN CONVERT
DUP 64 <= IF DROP -1 ELSE \ IF BET '0' & 'A' THEN ERROR
DUP 70 <= IF 55 - 0 ELSE \ IF 'A'-'F' THEN CONVERT
0 \ ELSE BET 'G' & 'Z'
THEN THEN THEN THEN THEN \ 0 IS FLAG FOR VALID INPUT
;
\ 14:24 10-08-90
DECIMAL
: INKEY ( --- KEY 0/-1 )
?TERMINAL \ CHECK FOR KEYPRESS
IF
KEY CHKKEY \ CHECK IF VALID RANGE
IF 7 EMIT 0 \ CHECK FOR VALID IN
ELSE -1 THEN
ELSE
0 \ MARK AS NO KEYPRESS
THEN
;
\ 16:10 01-21-91
: INPUT-DATA INKEY IF ( MENU SELECTION ROUTINE )
DUP 1 >= IF DUP 14 <= IF TRODE-SELECT EXIT THEN THEN
DUP 32 = IF ENTER-VALUE THEN \ CHANGE VALUE
DUP 72 = IF ANU-CONTROL ( ) THEN \ HISTOGRAMS ETC.
DUP 80 = IF CCP-CONTROL ( ) THEN \ CCP CONTROL
DUP 82 = IF R ( RIGHT-MENU ) THEN \ RASTER CONTROL
DUP 83 = IF SV THEN DUP 76 = IF LD THEN \ LOAD&SAVE CASES
DUP 71 = IF SHIFT-TOGGLE THEN \ TOGGLE COMP/UNCOMP
DUP 84 = IF PID-TOGGLE THEN \ TURN PID ON/OFF
DUP 88 = IF AUTO-ACCUM-PRINT THEN \ DO OPERATION
DUP 79 = IF AUTO-CONTROL1 THEN \ AUTO MENU 1
DUP 85 = IF AUTO-CONTROL2 THEN \ SEARCHES
DUP 31 AND 17 = IF TRODE-ADJUST-LOW THEN \ ^Q, 'Q, 'q
DUP 31 AND 23 = IF TRODE-ADJUST-HI THEN \ ^W, 'W, 'w
SHIFTER THEN RASTER ;