]> git.sur5r.net Git - cc65/blob - doc/gamate.sgml
Changed the wording of the doc/da65.sgml.
[cc65] / doc / gamate.sgml
1 <!doctype linuxdoc system>
2
3 <article>
4
5 <title>Gamate System specific information for cc65
6 <author>
7 <url url="mailto:groepaz@gmx.net" name="Groepaz/Hitmen">
8 <date>2015-11-29
9
10 <abstract>
11 An overview over the Gamate runtime system as it is implemented for the
12 cc65 C compiler.
13 </abstract>
14
15 <!-- Table of contents -->
16 <toc>
17
18 <!-- Begin the document -->
19
20 <sect>Overview<p>
21
22 This file contains an overview of the Gamate runtime system as it comes
23 with the cc65 C compiler. It describes the memory layout, Gamate specific header
24 files, available drivers, and any pitfalls specific to that platform.
25
26 Please note that Gamate specific functions are just mentioned here, they are
27 described in detail in the separate <url url="funcref.html" name="function
28 reference">. Even functions marked as "platform dependent" may be available on
29 more than one platform. Please see the function reference for more
30 information.
31
32
33 <sect>Binary format<p>
34
35 The standard binary output format generated by the linker for the Gamate target
36 is a cartridge image with header. It is of course possible to change this
37 behaviour by using a modified startup file and linker config.
38
39 Note: the first two bytes of the header contain a checksum that must be inserted
40 by an external program. Such an utility is provided in util/gamate/gamate-fixcart.c
41
42 <sect>Platform specific header files<p>
43
44 Programs containing Gamate specific code may use the <tt/gamate.h/ header file.
45
46
47 <sect1>Gamate specific functions<p>
48
49 <itemize>
50 <item>waitvsync</item>
51 </itemize>
52
53
54 <sect1>Hardware access<p>
55
56 The following pseudo variables declared in the <tt/gamate.inc/ include file do
57 allow access to hardware located in the address space.
58
59 <descrip>
60
61 </descrip><p>
62
63
64
65 <sect>Loadable drivers<p>
66
67 All drivers must be statically linked because no file I/O is available.
68 The names in the parentheses denote the symbols to be used for static linking of the drivers.
69
70
71 <sect1>Graphics drivers<p>
72
73 No TGI graphics drivers are currently available for the Gamate.
74
75
76 <sect1>Extended memory drivers<p>
77
78 No extended memory drivers are currently available for the Gamate.
79
80
81 <sect1>Joystick drivers<p>
82
83 <descrip>
84
85   <tag><tt/gamate-stdjoy.joy (gamate_stdjoy)/</tag>
86   A joystick driver for the standard two buttons joypad is available.
87
88 </descrip><p>
89
90
91 <sect1>Mouse drivers<p>
92
93 No mouse drivers are currently available for the Gamate.
94
95
96 <sect1>RS232 device drivers<p>
97
98 No serial drivers are currently available for the Gamate.
99
100
101
102 <sect>Limitations<p>
103
104 <itemize>
105 <item>When using the C-compiler, keep in mind that only 0x200 bytes RAM in total
106 can be used for variables and the runtime stack.
107 </itemize>
108
109 <sect1>Disk I/O<p>
110
111 The existing library for the Gamate doesn't implement C file
112 I/O. There are no hacks for the <tt/read()/ and <tt/write()/ routines.
113
114 To be more concrete, this limitation means that you cannot use any of the
115 following functions (and a few others):
116
117 <itemize>
118 <item>printf
119 <item>fclose
120 <item>fopen
121 <item>fread
122 <item>fprintf
123 <item>fputc
124 <item>fscanf
125 <item>fwrite
126 <item>...
127 </itemize>
128
129 <sect>Other hints<p>
130
131 <itemize>
132 <item>The Gamate is emulated by MESS (<url url="http://www.mess.org/">),
133 run like this: <tt>mess gamate -debug -window -skip_gameinfo -cart test.bin</tt>
134 </itemize>
135
136 some resources on the Gamate:
137
138 <itemize>
139 <item><url url="http://en.wikipedia.org/wiki/Gamate">
140 </itemize>
141
142 <sect>License<p>
143
144 This software is provided 'as-is', without any expressed or implied
145 warranty.  In no event will the authors be held liable for any damages
146 arising from the use of this software.
147
148 Permission is granted to anyone to use this software for any purpose,
149 including commercial applications, and to alter it and redistribute it
150 freely, subject to the following restrictions:
151
152 <enum>
153 <item>  The origin of this software must not be misrepresented; you must not
154         claim that you wrote the original software. If you use this software
155         in a product, an acknowledgment in the product documentation would be
156         appreciated but is not required.
157 <item>  Altered source versions must be plainly marked as such, and must not
158         be misrepresented as being the original software.
159 <item>  This notice may not be removed or altered from any source
160         distribution.
161 </enum>
162
163 </article>
164
165
166