|
|
1.1 root 1: #ifndef lint
2: static char *rcsid_apa16_c = "$Header: apa16.c,v 10.1 86/11/19 10:39:18 jg Exp $";
3: #endif lint
4: /* apa16.c - APA16 controller initialization
5: *
6: * apa16_init APA16 initialization routine
7: *
8: * Author:
9: * Scott Bates
10: * Brown University
11: * IRIS, Box 1946
12: * Providence, RI 02912
13: *
14: *
15: * Copyright (c) 1986 Brown University
16: *
17: * Permission to use, copy, modify and distribute this software and its
18: * documentation for any purpose and without fee is hereby granted, provided
19: * that the above copyright notice appear in all copies, and that both
20: * that copyright notice and this permission notice appear in supporting
21: * documentation, and that the name of Brown University not be used in
22: * advertising or publicity pertaining to distribution of the software
23: * without specific, written prior permission. Brown University makes no
24: * representations about the suitability of this software for any purpose.
25: * It is provided "as-is" without express or implied warranty.
26: */
27:
28: #include "private.h"
29: #include "bitblt.h"
30: #include "apa16.h"
31:
32: /*
33: * Initialize APA16
34: */
35:
36: apa16_init()
37: {
38:
39: #ifdef TRACE_X
40: fprintf (stderr, "In apa16_init\n");
41: fflush (stderr);
42: #endif TRACE_X
43:
44: /*
45: * Initialize (reset) the APA16 screen
46: */
47:
48: RESET_APA16();
49: *(short *)MR = MR_DEFAULT;
50: *(short *)CSR = WHITE_ON_BLACK;
51: ENABLE_VD_OUT();
52:
53: /*
54: * Test for the APA16 screen.
55: */
56:
57: *(char *)SCREEN_BASE = 0x0F;
58: if (*(char *)SCREEN_BASE != 0x0F) {
59: /*
60: * Log error and exit
61: */
62:
63: DeviceError("apa16 not found !!");
64: exit(2);
65: }
66: }
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.