source: buchla-68k/orig/RAM/KBOBJ.C@ 30c03a4

Last change on this file since 30c03a4 was 3ae31e9, checked in by Thomas Lopatic <thomas@…>, 8 years ago

Imported original source code.

  • Property mode set to 100755
File size: 6.8 KB
Line 
1/*
2 =============================================================================
3 kbobj.c -- keyboard object display data
4 Version 6 -- 1988-02-02 -- D.N. Lynx Crowe
5
6 Defines the data for the Keyboard object. Includes the "new data"
7 label.
8
9 Each group of keys is made up of groups of patterns KA..KD,
10 organized in 4 types of groups, 0..3, in 4 ways, W..Z.
11 =============================================================================
12*/
13
14#define K_BLK 0 /* black keys */
15#define K_WHT 1 /* white keys */
16#define K_GRY 2 /* lines between keys */
17
18#define LFC ((K_WHT << 12) | (K_WHT << 8) | (K_WHT << 4) | K_WHT)
19#define LFB ((K_GRY << 12) | (K_GRY << 8) | (K_GRY << 4) | K_GRY)
20
21#define LM(c) ((c & LFC) | ((~c) & LFB))
22
23#define KA ((K_GRY << 12) | (K_GRY << 8) | (K_GRY << 4) | K_GRY)
24#define KB ((K_WHT << 12) | (K_WHT << 8) | (K_WHT << 4) | K_WHT)
25#define KC ((K_GRY << 12) | (K_WHT << 8) | (K_WHT << 4) | K_WHT)
26#define KD ((K_BLK << 12) | (K_BLK << 8) | (K_BLK << 4) | K_BLK)
27
28int kbobj[] = {
29
30 KA, KA, KA, KA, /* 0 */ /* W */ /* C7 */
31 KB, KB, KB, KC,
32 KB, KB, KB, KC,
33 KB, KB, KB, KC,
34
35/*
36 */
37
38 KA, KA, KA, KA, /* 1 */ /* X */ /* B */
39 KB, KB, KB, KC,
40 KB, KB, KB, KC,
41 KD, KD, KB, KC,
42
43 KD, KD, KA, KA, /* 1 */ /* A7 */
44 KD, KD, KB, KC,
45 KB, KB, KB, KC,
46 KD, KD, KB, KC,
47
48 KD, KD, KA, KA, /* 2 */ /* G6 */
49 KD, KD, KB, KC,
50 KB, KB ,KB, KC,
51 KD, KD, KB, KC,
52
53 KD, KD, KA, KA, /* 2 */ /* F */
54 KD, KD, KB, KC,
55 KB, KB ,KB, KC,
56 KB, KB, KB, KC,
57
58 KA, KA, KA, KA, /* 1 */ /* Y */ /* E */
59 KB, KB, KB, KC,
60 KB, KB, KB, KC,
61 KD, KD, KB, KC,
62
63 KD, KD, KA, KA, /* 0 */ /* D */
64 KD, KD, KB, KC,
65 KB, KB, KB, KC,
66 KD, KD, KB, KC,
67
68 KD, KD, KA, KA, /* 2 */ /* C6 */
69 KD, KD, KB, KC,
70 KB, KB ,KB, KC,
71 KB, KB, KB, KC,
72
73/*
74 */
75
76 KA, KA, KA, KA, /* 1 */ /* X */ /* B */
77 KB, KB, KB, KC,
78 KB, KB, KB, KC,
79 KD, KD, KB, KC,
80
81 KD, KD, KA, KA, /* 1 */ /* A6 */
82 KD, KD, KB, KC,
83 KB, KB, KB, KC,
84 KD, KD, KB, KC,
85
86 KD, KD, KA, KA, /* 2 */ /* G5 */
87 KD, KD, KB, KC,
88 KB, KB ,KB, KC,
89 KD, KD, KB, KC,
90
91 KD, KD, KA, KA, /* 2 */ /* F */
92 KD, KD, KB, KC,
93 KB, KB ,KB, KC,
94 KB, KB, KB, KC,
95
96 KA, KA, KA, KA, /* 1 */ /* Y */ /* E */
97 KB, KB, KB, KC,
98 KB, KB, KB, KC,
99 KD, KD, KB, KC,
100
101 KD, KD, KA, KA, /* 0 */ /* D */
102 KD, KD, KB, KC,
103 KB, KB, KB, KC,
104 KD, KD, KB, KC,
105
106 KD, KD, KA, KA, /* 2 */ /* C5 */
107 KD, KD, KB, KC,
108 KB, KB ,KB, KC,
109 KB, KB, KB, KC,
110
111/*
112 */
113
114 KA, KA, KA, KA, /* 1 */ /* X */ /* B */
115 KB, KB, KB, KC,
116 KB, KB, KB, KC,
117 KD, KD, KB, KC,
118
119 KD, KD, KA, KA, /* 1 */ /* A5 */
120 KD, KD, KB, KC,
121 KB, KB, KB, KC,
122 KD, KD, KB, KC,
123
124 KD, KD, KA, KA, /* 2 */ /* G4 */
125 KD, KD, KB, KC,
126 KB, KB ,KB, KC,
127 KD, KD, KB, KC,
128
129 KD, KD, KA, KA, /* 2 */ /* F */
130 KD, KD, KB, KC,
131 KB, KB ,KB, KC,
132 KB, KB, KB, KC,
133
134 KA, KA, KA, KA, /* 1 */ /* Y */ /* E */
135 KB, KB, KB, KC,
136 KB, KB, KB, KC,
137 KD, KD, KB, KC,
138
139 KD, KD, KA, KA, /* 0 */ /* D */
140 KD, KD, KB, KC,
141 KB, KB, KB, KC,
142 KD, KD, KB, KC,
143
144 KD, KD, KA, KA, /* 2 */ /* C4 */
145 KD, KD, KB, KC,
146 KB, KB ,KB, KC,
147 KB, KB, KB, KC,
148
149/*
150 */
151
152 KA, KA, KA, KA, /* 1 */ /* X */ /* B */
153 KB, KB, KB, KC,
154 KB, KB, KB, KC,
155 KD, KD, KB, KC,
156
157 KD, KD, KA, KA, /* 1 */ /* A4 */
158 KD, KD, KB, KC,
159 KB, KB, KB, KC,
160 KD, KD, KB, KC,
161
162 KD, KD, KA, KA, /* 2 */ /* G3 */
163 KD, KD, KB, KC,
164 KB, KB ,KB, KC,
165 KD, KD, KB, KC,
166
167 KD, KD, KA, KA, /* 2 */ /* F */
168 KD, KD, KB, KC,
169 KB, KB ,KB, KC,
170 KB, KB, KB, KC,
171
172 KA, KA, KA, KA, /* 1 */ /* Y */ /* E */
173 KB, KB, KB, KC,
174 KB, KB, KB, KC,
175 KD, KD, KB, KC,
176
177 KD, KD, KA, KA, /* 0 */ /* D */
178 KD, KD, KB, KC,
179 KB, KB, KB, KC,
180 KD, KD, KB, KC,
181
182 KD, KD, KA, KA, /* 2 */ /* C3 */
183 KD, KD, KB, KC,
184 KB, KB ,KB, KC,
185 KB, KB, KB, KC,
186
187/*
188 */
189
190 KA, KA, KA, KA, /* 1 */ /* X */ /* B */
191 KB, KB, KB, KC,
192 KB, KB, KB, KC,
193 KD, KD, KB, KC,
194
195 KD, KD, KA, KA, /* 1 */ /* A3 */
196 KD, KD, KB, KC,
197 KB, KB, KB, KC,
198 KD, KD, KB, KC,
199
200 KD, KD, KA, KA, /* 2 */ /* G2 */
201 KD, KD, KB, KC,
202 KB, KB ,KB, KC,
203 KD, KD, KB, KC,
204
205 KD, KD, KA, KA, /* 2 */ /* F */
206 KD, KD, KB, KC,
207 KB, KB ,KB, KC,
208 KB, KB, KB, KC,
209
210 KA, KA, KA, KA, /* 1 */ /* Y */ /* E */
211 KB, KB, KB, KC,
212 KB, KB, KB, KC,
213 KD, KD, KB, KC,
214
215 KD, KD, KA, KA, /* 0 */ /* D */
216 KD, KD, KB, KC,
217 KB, KB, KB, KC,
218 KD, KD, KB, KC,
219
220 KD, KD, KA, KA, /* 2 */ /* C2 */
221 KD, KD, KB, KC,
222 KB, KB ,KB, KC,
223 KB, KB, KB, KC,
224
225/*
226 */
227
228 KA, KA, KA, KA, /* 1 */ /* X */ /* B */
229 KB, KB, KB, KC,
230 KB, KB, KB, KC,
231 KD, KD, KB, KC,
232
233 KD, KD, KA, KA, /* 1 */ /* A2 */
234 KD, KD, KB, KC,
235 KB, KB, KB, KC,
236 KD, KD, KB, KC,
237
238 KD, KD, KA, KA, /* 2 */ /* G1 */
239 KD, KD, KB, KC,
240 KB, KB ,KB, KC,
241 KD, KD, KB, KC,
242
243 KD, KD, KA, KA, /* 2 */ /* F */
244 KD, KD, KB, KC,
245 KB, KB ,KB, KC,
246 KB, KB, KB, KC,
247
248 KA, KA, KA, KA, /* 1 */ /* Y */ /* E */
249 KB, KB, KB, KC,
250 KB, KB, KB, KC,
251 KD, KD, KB, KC,
252
253 KD, KD, KA, KA, /* 0 */ /* D */
254 KD, KD, KB, KC,
255 KB, KB, KB, KC,
256 KD, KD, KB, KC,
257
258 KD, KD, KA, KA, /* 2 */ /* C1 */
259 KD, KD, KB, KC,
260 KB, KB ,KB, KC,
261 KB, KB, KB, KC,
262
263/*
264 */
265
266 KA, KA, KA, KA, /* 1 */ /* X */ /* B */
267 KB, KB, KB, KC,
268 KB, KB, KB, KC,
269 KD, KD, KB, KC,
270
271 KD, KD, KA, KA, /* 1 */ /* A1 */
272 KD, KD, KB, KC,
273 KB, KB, KB, KC,
274 KD, KD, KB, KC,
275
276 KD, KD, KA, KA, /* 2 */ /* G0 */
277 KD, KD, KB, KC,
278 KB, KB ,KB, KC,
279 KD, KD, KB, KC,
280
281 KD, KD, KA, KA, /* 2 */ /* F */
282 KD, KD, KB, KC,
283 KB, KB ,KB, KC,
284 KB, KB, KB, KC,
285
286 KA, KA, KA, KA, /* 1 */ /* Y */ /* E */
287 KB, KB, KB, KC,
288 KB, KB, KB, KC,
289 KD, KD, KB, KC,
290
291 KD, KD, KA, KA, /* 0 */ /* D */
292 KD, KD, KB, KC,
293 KB, KB, KB, KC,
294 KD, KD, KB, KC,
295
296 KD, KD, KA, KA, /* 2 */ /* C0 */
297 KD, KD, KB, KC,
298 KB, KB ,KB, KC,
299 KB, KB, KB, KC,
300
301/*
302 */
303
304 KA, KA, KA, KA, /* 1 */ /* Z */ /* B */
305 KB, KB, KB, KC,
306 KB, KB, KB, KC,
307 KD, KD, KB, KC,
308
309 KD, KD, KA, KA, /* 2 */ /* A0 */
310 KD, KD, KB, KC,
311 KB, KB ,KB, KC,
312 KB, KB, KB, KC,
313
314 KA, KA, KA, KA, /* 3 */ /* Bottom border */
315 KD, KD, KD, KD,
316
317 /* New Data label */
318
319 LM(0x0000), LM(0x0000), LM(0x0000), LM(0x0000),
320 LM(0x00F0), LM(0xFF0F), LM(0x0F0F), LM(0x0F00),
321 LM(0x0FF0), LM(0x0F0F), LM(0x0F00), LM(0x0F00),
322 LM(0xF0F0), LM(0xFF0F), LM(0x0F00), LM(0x0F0F),
323 LM(0x00F0), LM(0x0F0F), LM(0xFF00), LM(0x0FF0),
324 LM(0x00F0), LM(0xFF0F), LM(0x0F0F), LM(0x0F00),
325 LM(0x0000), LM(0x0000), LM(0x0000), LM(0x0000),
326 LM(0x0000), LM(0x0000), LM(0x0000), LM(0x0000),
327 LM(0x0FF0), LM(0xFF00), LM(0xFFF0), LM(0x0FF0),
328 LM(0xF0F0), LM(0x00F0), LM(0x0F0F), LM(0xF00F),
329 LM(0xF0F0), LM(0xFFF0), LM(0x0F0F), LM(0xFFFF),
330 LM(0xF0F0), LM(0x00F0), LM(0x0F0F), LM(0xF00F),
331 LM(0x0FF0), LM(0x00F0), LM(0x0F0F), LM(0xF00F),
332 LM(0x0000), LM(0x0000), LM(0x0000), LM(0x0000)
333};
Note: See TracBrowser for help on using the repository browser.