source: buchla-68k/ram/kbobj.c@ 14ad9c9

Last change on this file since 14ad9c9 was b28a12e, checked in by Thomas Lopatic <thomas@…>, 7 years ago

Zero redundant declarations.

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