1<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> 2<html> 3 <head> 4 <meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1"> 5 <title>File Index</title> 6 <link href="doxygen.css" rel="stylesheet" type="text/css"> 7 </head> 8 <body> 9<!-- Generated by Doxygen 1.7.4 --> 10 <div id="navrow1" class="tabs"> 11 <ul class="tablist"> 12 <li><a href="index.html"><span>Main Page</span></a></li> 13 <li><a href="annotated.html"><span>Data Structures</span></a></li> 14 <li class="current"><a href="files.html"><span>Files</span></a></li> 15 </ul> 16 </div> 17 <div id="navrow2" class="tabs2"> 18 <ul class="tablist"> 19 <li><a href="files.html"><span>File List</span></a></li> 20 <li><a href="globals.html"><span>Globals</span></a></li> 21 </ul> 22 </div> 23</div> 24<div id="side-nav" class="ui-resizable side-nav-resizable"> 25 <div id="nav-tree"> 26 <div id="nav-tree-contents"> 27 </div> 28 </div> 29 <div id="splitbar" style="-moz-user-select:none;" 30 class="ui-resizable-handle"> 31 </div> 32</div> 33<script type="text/javascript"> 34 initNavTree('lnx-ps2_8c.html',''); 35</script> 36<div id="doc-content"> 37<div class="header"> 38 <div class="summary"> 39<a href="#nested-classes">Data Structures</a> | 40<a href="#define-members">Defines</a> | 41<a href="#typedef-members">Typedefs</a> | 42<a href="#func-members">Functions</a> </div> 43 <div class="headertitle"> 44<div class="title">lnx-ps2.c File Reference</div> </div> 45</div> 46<div class="contents"> 47<div class="textblock"><code>#include "inputstr.h"</code><br/> 48<code>#include <X11/Xos.h></code><br/> 49<code>#include <errno.h></code><br/> 50<code>#include <termios.h></code><br/> 51<code>#include "<a class="el" href="dmxinputinit_8h_source.html">dmxinputinit.h</a>"</code><br/> 52<code>#include "<a class="el" href="lnx-ps2_8h_source.html">lnx-ps2.h</a>"</code><br/> 53</div><table class="memberdecls"> 54<tr><td colspan="2"><h2><a name="nested-classes"></a> 55Data Structures</h2></td></tr> 56<tr><td class="memItemLeft" align="right" valign="top">struct  </td><td class="memItemRight" valign="bottom"><a class="el" href="struct__myPrivate.html">_myPrivate</a></td></tr> 57<tr><td colspan="2"><h2><a name="define-members"></a> 58Defines</h2></td></tr> 59<tr><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="lnx-ps2_8c.html#aacf069d346230dd96812d5395728eef2">GETPRIV</a></td></tr> 60<tr><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="lnx-ps2_8c.html#a837722a322e811d5e42242655f277b87">LOG0</a>(f)   dmxLog(dmxDebug,f)</td></tr> 61<tr><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="lnx-ps2_8c.html#aab4b3434c36117a2ecdddec40716d97a">LOG1</a>(f, a)   dmxLog(dmxDebug,f,a)</td></tr> 62<tr><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="lnx-ps2_8c.html#a16da5d597d9bfb9e569a9bfb6996382c">LOG2</a>(f, a, b)   dmxLog(dmxDebug,f,a,b)</td></tr> 63<tr><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="lnx-ps2_8c.html#a8247f0bca25789d2ac27674eb26e223f">LOG3</a>(f, a, b, c)   dmxLog(dmxDebug,f,a,b,c)</td></tr> 64<tr><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="lnx-ps2_8c.html#a6bce6020b913db8afe5d94bc63d1b355">FATAL0</a>(f)   dmxLog(dmxFatal,f)</td></tr> 65<tr><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="lnx-ps2_8c.html#a11bcea7c6bc7dbe400a3855f5b8676ce">FATAL1</a>(f, a)   dmxLog(dmxFatal,f,a)</td></tr> 66<tr><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="lnx-ps2_8c.html#a7952c9e9fe9c75be4964fc53a4299183">FATAL2</a>(f, a, b)   dmxLog(dmxFatal,f,a,b)</td></tr> 67<tr><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="lnx-ps2_8c.html#a11a17082bee3b1b8217ce8a12adcf814">MOTIONPROC</a>   <a class="el" href="dmxinputinit_8h.html#a1279820425966adabf5c77357e4a289c">dmxMotionProcPtr</a></td></tr> 68<tr><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="lnx-ps2_8c.html#a017080ce5e42667a6582cf858e7185cd">ENQUEUEPROC</a>   <a class="el" href="dmxinputinit_8h.html#adbd955b9ddbc5ffe38ff65e3f068f205">dmxEnqueueProcPtr</a></td></tr> 69<tr><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="lnx-ps2_8c.html#aa35a985e998ad5e2187e13434dca118a">CHECKPROC</a>   <a class="el" href="dmxinputinit_8h.html#a838cb45fd92d5cf506e4179b601f7dbc">dmxCheckSpecialProcPtr</a></td></tr> 70<tr><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="lnx-ps2_8c.html#a52220397ecea855b3a99746e451426e1">BLOCK</a>   <a class="el" href="dmxinput_8h.html#a3a7195ab3516c5354bac4ca80b2eedb7">DMXBlockType</a></td></tr> 71<tr><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="lnx-ps2_8c.html#a7581da9bfd7ebf4fe3703352df521931">PRESS</a>(b)</td></tr> 72<tr><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="lnx-ps2_8c.html#a2b4d2480737f9eb52f80998518486f01">RELEASE</a>(b)</td></tr> 73<tr><td colspan="2"><h2><a name="typedef-members"></a> 74Typedefs</h2></td></tr> 75<tr><td class="memItemLeft" align="right" valign="top">typedef struct <a class="el" href="struct__myPrivate.html">_myPrivate</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="lnx-ps2_8c.html#a25692217bddf2b6c089525b325afccf1">myPrivate</a></td></tr> 76<tr><td colspan="2"><h2><a name="func-members"></a> 77Functions</h2></td></tr> 78<tr><td class="memItemLeft" align="right" valign="top">static int </td><td class="memItemRight" valign="bottom"><a class="el" href="lnx-ps2_8c.html#ad806e9804e49f47d75f252ab0b14c075">ps2LinuxReadBytes</a> (int fd, unsigned char *buf, int len, int min)</td></tr> 79<tr><td class="memItemLeft" align="right" valign="top">static void </td><td class="memItemRight" valign="bottom"><a class="el" href="lnx-ps2_8c.html#af3ff29bf7e70049ca978bc8fbff4aab6">ps2LinuxButton</a> (DevicePtr pDev, ENQUEUEPROC enqueue, int buttons, BLOCK block)</td></tr> 80<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="lnx-ps2_8c.html#a373ac6b94ea32ce3f7329404ba1ae382">ps2LinuxRead</a> (DevicePtr pDev, MOTIONPROC motion, ENQUEUEPROC enqueue, CHECKPROC checkspecial, BLOCK block)</td></tr> 81<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="lnx-ps2_8c.html#aa0f0b690de9e5c3a958909000c7f787d">ps2LinuxInit</a> (DevicePtr pDev)</td></tr> 82<tr><td class="memItemLeft" align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="lnx-ps2_8c.html#aaf9aaca79e044d91f072901ad3be1863">ps2LinuxOn</a> (DevicePtr pDev)</td></tr> 83<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="lnx-ps2_8c.html#af955e539213ec85f5b6d5d7b38dae89e">ps2LinuxOff</a> (DevicePtr pDev)</td></tr> 84<tr><td class="memItemLeft" align="right" valign="top">static void </td><td class="memItemRight" valign="bottom"><a class="el" href="lnx-ps2_8c.html#a0f65c382ff39d64cd881a919eb566964">ps2LinuxGetMap</a> (DevicePtr pDev, unsigned char *<a class="el" href="usb-keyboard_8c.html#a2187a19657fb0b38c67dbafc7dd74c4d">map</a>, int *nButtons)</td></tr> 85<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="lnx-ps2_8c.html#a3a9ac063b46a191b38d92881367d74d4">ps2LinuxVTPreSwitch</a> (pointer p)</td></tr> 86<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="lnx-ps2_8c.html#a11a5bfc4866f86dfe3ea5acb788c4afe">ps2LinuxVTPostSwitch</a> (pointer p)</td></tr> 87<tr><td class="memItemLeft" align="right" valign="top">pointer </td><td class="memItemRight" valign="bottom"><a class="el" href="lnx-ps2_8c.html#ab6e438a481e24f8c6ef7d731b8ee4fb8">ps2LinuxCreatePrivate</a> (DeviceIntPtr pMouse)</td></tr> 88<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="lnx-ps2_8c.html#af67bcdd060164de0c3a0d3e69c8483ac">ps2LinuxDestroyPrivate</a> (pointer priv)</td></tr> 89<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="lnx-ps2_8c.html#ab914e24acbae5ce49174e06842ac684b">ps2LinuxGetInfo</a> (DevicePtr pDev, <a class="el" href="struct__DMXLocalInitInfo.html">DMXLocalInitInfoPtr</a> info)</td></tr> 90</table> 91<hr/><a name="details" id="details"></a><h2>Detailed Description</h2> 92<div class="textblock"><p>This code implements a low-level device driver for a serial MS mouse. The code is derived from code by Keith Packard (see the source code for complete references). </p> 93</div><hr/><h2>Define Documentation</h2> 94<a class="anchor" id="a52220397ecea855b3a99746e451426e1"></a><!-- doxytag: member="lnx-ps2.c::BLOCK" ref="a52220397ecea855b3a99746e451426e1" args="" --> 95<div class="memitem"> 96<div class="memproto"> 97 <table class="memname"> 98 <tr> 99 <td class="memname">#define BLOCK   <a class="el" href="dmxinput_8h.html#a3a7195ab3516c5354bac4ca80b2eedb7">DMXBlockType</a></td> 100 </tr> 101 </table> 102</div> 103<div class="memdoc"> 104 105</div> 106</div> 107<a class="anchor" id="aa35a985e998ad5e2187e13434dca118a"></a><!-- doxytag: member="lnx-ps2.c::CHECKPROC" ref="aa35a985e998ad5e2187e13434dca118a" args="" --> 108<div class="memitem"> 109<div class="memproto"> 110 <table class="memname"> 111 <tr> 112 <td class="memname">#define CHECKPROC   <a class="el" href="dmxinputinit_8h.html#a838cb45fd92d5cf506e4179b601f7dbc">dmxCheckSpecialProcPtr</a></td> 113 </tr> 114 </table> 115</div> 116<div class="memdoc"> 117 118</div> 119</div> 120<a class="anchor" id="a017080ce5e42667a6582cf858e7185cd"></a><!-- doxytag: member="lnx-ps2.c::ENQUEUEPROC" ref="a017080ce5e42667a6582cf858e7185cd" args="" --> 121<div class="memitem"> 122<div class="memproto"> 123 <table class="memname"> 124 <tr> 125 <td class="memname">#define ENQUEUEPROC   <a class="el" href="dmxinputinit_8h.html#adbd955b9ddbc5ffe38ff65e3f068f205">dmxEnqueueProcPtr</a></td> 126 </tr> 127 </table> 128</div> 129<div class="memdoc"> 130 131</div> 132</div> 133<a class="anchor" id="a6bce6020b913db8afe5d94bc63d1b355"></a><!-- doxytag: member="lnx-ps2.c::FATAL0" ref="a6bce6020b913db8afe5d94bc63d1b355" args="(f)" --> 134<div class="memitem"> 135<div class="memproto"> 136 <table class="memname"> 137 <tr> 138 <td class="memname">#define FATAL0</td> 139 <td>(</td> 140 <td class="paramtype"> </td> 141 <td class="paramname">f</td><td>)</td> 142 <td>   dmxLog(dmxFatal,f)</td> 143 </tr> 144 </table> 145</div> 146<div class="memdoc"> 147 148</div> 149</div> 150<a class="anchor" id="a11bcea7c6bc7dbe400a3855f5b8676ce"></a><!-- doxytag: member="lnx-ps2.c::FATAL1" ref="a11bcea7c6bc7dbe400a3855f5b8676ce" args="(f, a)" --> 151<div class="memitem"> 152<div class="memproto"> 153 <table class="memname"> 154 <tr> 155 <td class="memname">#define FATAL1</td> 156 <td>(</td> 157 <td class="paramtype"> </td> 158 <td class="paramname">f, </td> 159 </tr> 160 <tr> 161 <td class="paramkey"></td> 162 <td></td> 163 <td class="paramtype"> </td> 164 <td class="paramname">a </td> 165 </tr> 166 <tr> 167 <td></td> 168 <td>)</td> 169 <td></td><td>   dmxLog(dmxFatal,f,a)</td> 170 </tr> 171 </table> 172</div> 173<div class="memdoc"> 174 175<p>Referenced by <a class="el" href="lnx-ps2_8h.html#aa0f0b690de9e5c3a958909000c7f787d">ps2LinuxInit()</a>.</p> 176 177</div> 178</div> 179<a class="anchor" id="a7952c9e9fe9c75be4964fc53a4299183"></a><!-- doxytag: member="lnx-ps2.c::FATAL2" ref="a7952c9e9fe9c75be4964fc53a4299183" args="(f, a, b)" --> 180<div class="memitem"> 181<div class="memproto"> 182 <table class="memname"> 183 <tr> 184 <td class="memname">#define FATAL2</td> 185 <td>(</td> 186 <td class="paramtype"> </td> 187 <td class="paramname">f, </td> 188 </tr> 189 <tr> 190 <td class="paramkey"></td> 191 <td></td> 192 <td class="paramtype"> </td> 193 <td class="paramname">a, </td> 194 </tr> 195 <tr> 196 <td class="paramkey"></td> 197 <td></td> 198 <td class="paramtype"> </td> 199 <td class="paramname">b </td> 200 </tr> 201 <tr> 202 <td></td> 203 <td>)</td> 204 <td></td><td>   dmxLog(dmxFatal,f,a,b)</td> 205 </tr> 206 </table> 207</div> 208<div class="memdoc"> 209 210</div> 211</div> 212<a class="anchor" id="aacf069d346230dd96812d5395728eef2"></a><!-- doxytag: member="lnx-ps2.c::GETPRIV" ref="aacf069d346230dd96812d5395728eef2" args="" --> 213<div class="memitem"> 214<div class="memproto"> 215 <table class="memname"> 216 <tr> 217 <td class="memname">#define GETPRIV</td> 218 </tr> 219 </table> 220</div> 221<div class="memdoc"> 222<b>Value:</b><div class="fragment"><pre class="fragment"><a class="code" href="struct__myPrivate.html">myPrivate</a> *priv \ 223 = ((<a class="code" href="dmxinput_8h.html#adb148db00fe0adf1938b815b9b934d26">DMXLocalInputInfoPtr</a>)(pDev->devicePrivate))->private 224</pre></div> 225<p>Referenced by <a class="el" href="lnx-ps2_8c.html#af3ff29bf7e70049ca978bc8fbff4aab6">ps2LinuxButton()</a>, <a class="el" href="lnx-ps2_8h.html#aa0f0b690de9e5c3a958909000c7f787d">ps2LinuxInit()</a>, <a class="el" href="lnx-ps2_8h.html#af955e539213ec85f5b6d5d7b38dae89e">ps2LinuxOff()</a>, <a class="el" href="lnx-ps2_8h.html#aaf9aaca79e044d91f072901ad3be1863">ps2LinuxOn()</a>, and <a class="el" href="lnx-ps2_8c.html#a373ac6b94ea32ce3f7329404ba1ae382">ps2LinuxRead()</a>.</p> 226 227</div> 228</div> 229<a class="anchor" id="a837722a322e811d5e42242655f277b87"></a><!-- doxytag: member="lnx-ps2.c::LOG0" ref="a837722a322e811d5e42242655f277b87" args="(f)" --> 230<div class="memitem"> 231<div class="memproto"> 232 <table class="memname"> 233 <tr> 234 <td class="memname">#define LOG0</td> 235 <td>(</td> 236 <td class="paramtype"> </td> 237 <td class="paramname">f</td><td>)</td> 238 <td>   dmxLog(dmxDebug,f)</td> 239 </tr> 240 </table> 241</div> 242<div class="memdoc"> 243 244</div> 245</div> 246<a class="anchor" id="aab4b3434c36117a2ecdddec40716d97a"></a><!-- doxytag: member="lnx-ps2.c::LOG1" ref="aab4b3434c36117a2ecdddec40716d97a" args="(f, a)" --> 247<div class="memitem"> 248<div class="memproto"> 249 <table class="memname"> 250 <tr> 251 <td class="memname">#define LOG1</td> 252 <td>(</td> 253 <td class="paramtype"> </td> 254 <td class="paramname">f, </td> 255 </tr> 256 <tr> 257 <td class="paramkey"></td> 258 <td></td> 259 <td class="paramtype"> </td> 260 <td class="paramname">a </td> 261 </tr> 262 <tr> 263 <td></td> 264 <td>)</td> 265 <td></td><td>   dmxLog(dmxDebug,f,a)</td> 266 </tr> 267 </table> 268</div> 269<div class="memdoc"> 270 271</div> 272</div> 273<a class="anchor" id="a16da5d597d9bfb9e569a9bfb6996382c"></a><!-- doxytag: member="lnx-ps2.c::LOG2" ref="a16da5d597d9bfb9e569a9bfb6996382c" args="(f, a, b)" --> 274<div class="memitem"> 275<div class="memproto"> 276 <table class="memname"> 277 <tr> 278 <td class="memname">#define LOG2</td> 279 <td>(</td> 280 <td class="paramtype"> </td> 281 <td class="paramname">f, </td> 282 </tr> 283 <tr> 284 <td class="paramkey"></td> 285 <td></td> 286 <td class="paramtype"> </td> 287 <td class="paramname">a, </td> 288 </tr> 289 <tr> 290 <td class="paramkey"></td> 291 <td></td> 292 <td class="paramtype"> </td> 293 <td class="paramname">b </td> 294 </tr> 295 <tr> 296 <td></td> 297 <td>)</td> 298 <td></td><td>   dmxLog(dmxDebug,f,a,b)</td> 299 </tr> 300 </table> 301</div> 302<div class="memdoc"> 303 304</div> 305</div> 306<a class="anchor" id="a8247f0bca25789d2ac27674eb26e223f"></a><!-- doxytag: member="lnx-ps2.c::LOG3" ref="a8247f0bca25789d2ac27674eb26e223f" args="(f, a, b, c)" --> 307<div class="memitem"> 308<div class="memproto"> 309 <table class="memname"> 310 <tr> 311 <td class="memname">#define LOG3</td> 312 <td>(</td> 313 <td class="paramtype"> </td> 314 <td class="paramname">f, </td> 315 </tr> 316 <tr> 317 <td class="paramkey"></td> 318 <td></td> 319 <td class="paramtype"> </td> 320 <td class="paramname">a, </td> 321 </tr> 322 <tr> 323 <td class="paramkey"></td> 324 <td></td> 325 <td class="paramtype"> </td> 326 <td class="paramname">b, </td> 327 </tr> 328 <tr> 329 <td class="paramkey"></td> 330 <td></td> 331 <td class="paramtype"> </td> 332 <td class="paramname">c </td> 333 </tr> 334 <tr> 335 <td></td> 336 <td>)</td> 337 <td></td><td>   dmxLog(dmxDebug,f,a,b,c)</td> 338 </tr> 339 </table> 340</div> 341<div class="memdoc"> 342 343</div> 344</div> 345<a class="anchor" id="a11a17082bee3b1b8217ce8a12adcf814"></a><!-- doxytag: member="lnx-ps2.c::MOTIONPROC" ref="a11a17082bee3b1b8217ce8a12adcf814" args="" --> 346<div class="memitem"> 347<div class="memproto"> 348 <table class="memname"> 349 <tr> 350 <td class="memname">#define MOTIONPROC   <a class="el" href="dmxinputinit_8h.html#a1279820425966adabf5c77357e4a289c">dmxMotionProcPtr</a></td> 351 </tr> 352 </table> 353</div> 354<div class="memdoc"> 355 356</div> 357</div> 358<a class="anchor" id="a7581da9bfd7ebf4fe3703352df521931"></a><!-- doxytag: member="lnx-ps2.c::PRESS" ref="a7581da9bfd7ebf4fe3703352df521931" args="(b)" --> 359<div class="memitem"> 360<div class="memproto"> 361 <table class="memname"> 362 <tr> 363 <td class="memname">#define PRESS</td> 364 <td>(</td> 365 <td class="paramtype"> </td> 366 <td class="paramname">b</td><td>)</td> 367 <td></td> 368 </tr> 369 </table> 370</div> 371<div class="memdoc"> 372<b>Value:</b><div class="fragment"><pre class="fragment"><span class="keywordflow">do</span> { \ 373 enqueue(pDev, ButtonPress, 0, 0, NULL, block); \ 374 } <span class="keywordflow">while</span> (0) 375</pre></div> 376</div> 377</div> 378<a class="anchor" id="a2b4d2480737f9eb52f80998518486f01"></a><!-- doxytag: member="lnx-ps2.c::RELEASE" ref="a2b4d2480737f9eb52f80998518486f01" args="(b)" --> 379<div class="memitem"> 380<div class="memproto"> 381 <table class="memname"> 382 <tr> 383 <td class="memname">#define RELEASE</td> 384 <td>(</td> 385 <td class="paramtype"> </td> 386 <td class="paramname">b</td><td>)</td> 387 <td></td> 388 </tr> 389 </table> 390</div> 391<div class="memdoc"> 392<b>Value:</b><div class="fragment"><pre class="fragment"><span class="keywordflow">do</span> { \ 393 enqueue(pDev, ButtonRelease, 0, 0, NULL, block); \ 394 } <span class="keywordflow">while</span> (0) 395</pre></div> 396</div> 397</div> 398<hr/><h2>Typedef Documentation</h2> 399<a class="anchor" id="a25692217bddf2b6c089525b325afccf1"></a><!-- doxytag: member="lnx-ps2.c::myPrivate" ref="a25692217bddf2b6c089525b325afccf1" args="" --> 400<div class="memitem"> 401<div class="memproto"> 402 <table class="memname"> 403 <tr> 404 <td class="memname">typedef struct <a class="el" href="struct__myPrivate.html">_myPrivate</a> <a class="el" href="struct__myPrivate.html">myPrivate</a></td> 405 </tr> 406 </table> 407</div> 408<div class="memdoc"> 409 410</div> 411</div> 412<hr/><h2>Function Documentation</h2> 413<a class="anchor" id="af3ff29bf7e70049ca978bc8fbff4aab6"></a><!-- doxytag: member="lnx-ps2.c::ps2LinuxButton" ref="af3ff29bf7e70049ca978bc8fbff4aab6" args="(DevicePtr pDev, ENQUEUEPROC enqueue, int buttons, BLOCK block)" --> 414<div class="memitem"> 415<div class="memproto"> 416 <table class="memname"> 417 <tr> 418 <td class="memname">static void ps2LinuxButton </td> 419 <td>(</td> 420 <td class="paramtype">DevicePtr </td> 421 <td class="paramname"><em>pDev</em>, </td> 422 </tr> 423 <tr> 424 <td class="paramkey"></td> 425 <td></td> 426 <td class="paramtype">ENQUEUEPROC </td> 427 <td class="paramname"><em>enqueue</em>, </td> 428 </tr> 429 <tr> 430 <td class="paramkey"></td> 431 <td></td> 432 <td class="paramtype">int </td> 433 <td class="paramname"><em>buttons</em>, </td> 434 </tr> 435 <tr> 436 <td class="paramkey"></td> 437 <td></td> 438 <td class="paramtype">BLOCK </td> 439 <td class="paramname"><em>block</em> </td> 440 </tr> 441 <tr> 442 <td></td> 443 <td>)</td> 444 <td></td><td><code> [static]</code></td> 445 </tr> 446 </table> 447</div> 448<div class="memdoc"> 449 450<p>References <a class="el" href="lnx-ps2_8c.html#aacf069d346230dd96812d5395728eef2">GETPRIV</a>, <a class="el" href="lnx-ms_8c.html#a7581da9bfd7ebf4fe3703352df521931">PRESS</a>, and <a class="el" href="lnx-ms_8c.html#a2b4d2480737f9eb52f80998518486f01">RELEASE</a>.</p> 451 452<p>Referenced by <a class="el" href="lnx-ps2_8c.html#a373ac6b94ea32ce3f7329404ba1ae382">ps2LinuxRead()</a>.</p> 453 454</div> 455</div> 456<a class="anchor" id="ab6e438a481e24f8c6ef7d731b8ee4fb8"></a><!-- doxytag: member="lnx-ps2.c::ps2LinuxCreatePrivate" ref="ab6e438a481e24f8c6ef7d731b8ee4fb8" args="(DeviceIntPtr pMouse)" --> 457<div class="memitem"> 458<div class="memproto"> 459 <table class="memname"> 460 <tr> 461 <td class="memname">pointer ps2LinuxCreatePrivate </td> 462 <td>(</td> 463 <td class="paramtype">DeviceIntPtr </td> 464 <td class="paramname"><em>pMouse</em></td><td>)</td> 465 <td></td> 466 </tr> 467 </table> 468</div> 469<div class="memdoc"> 470<p>Create a private structure for use within this file. </p> 471 472<p>References <a class="el" href="struct__myPrivate.html#a6b26eb0acc0b932c8dee8277501e6273">_myPrivate::fd</a>, and <a class="el" href="struct__myPrivate.html#a3e46e1ccb546bbadfa5ebb165a8b11d4">_myPrivate::pMouse</a>.</p> 473 474</div> 475</div> 476<a class="anchor" id="af67bcdd060164de0c3a0d3e69c8483ac"></a><!-- doxytag: member="lnx-ps2.c::ps2LinuxDestroyPrivate" ref="af67bcdd060164de0c3a0d3e69c8483ac" args="(pointer priv)" --> 477<div class="memitem"> 478<div class="memproto"> 479 <table class="memname"> 480 <tr> 481 <td class="memname">void ps2LinuxDestroyPrivate </td> 482 <td>(</td> 483 <td class="paramtype">pointer </td> 484 <td class="paramname"><em>priv</em></td><td>)</td> 485 <td></td> 486 </tr> 487 </table> 488</div> 489<div class="memdoc"> 490<p>Destroy a private structure. </p> 491 492</div> 493</div> 494<a class="anchor" id="ab914e24acbae5ce49174e06842ac684b"></a><!-- doxytag: member="lnx-ps2.c::ps2LinuxGetInfo" ref="ab914e24acbae5ce49174e06842ac684b" args="(DevicePtr pDev, DMXLocalInitInfoPtr info)" --> 495<div class="memitem"> 496<div class="memproto"> 497 <table class="memname"> 498 <tr> 499 <td class="memname">void ps2LinuxGetInfo </td> 500 <td>(</td> 501 <td class="paramtype">DevicePtr </td> 502 <td class="paramname"><em>pDev</em>, </td> 503 </tr> 504 <tr> 505 <td class="paramkey"></td> 506 <td></td> 507 <td class="paramtype"><a class="el" href="struct__DMXLocalInitInfo.html">DMXLocalInitInfoPtr</a> </td> 508 <td class="paramname"><em>info</em> </td> 509 </tr> 510 <tr> 511 <td></td> 512 <td>)</td> 513 <td></td><td></td> 514 </tr> 515 </table> 516</div> 517<div class="memdoc"> 518<p>Fill the <em>info</em> structure with information needed to initialize <em>pDev</em>. </p> 519 520<p>References <a class="el" href="struct__DMXLocalInitInfo.html#a58b2e6764967add7eda1c1f2f0860abc">_DMXLocalInitInfo::buttonClass</a>, <a class="el" href="struct__DMXLocalInitInfo.html#a43d86cc82219794bba7ba1ee66472a45">_DMXLocalInitInfo::map</a>, <a class="el" href="struct__DMXLocalInitInfo.html#a5de8a5ac80a30840cba0d9f3074289ca">_DMXLocalInitInfo::maxres</a>, <a class="el" href="struct__DMXLocalInitInfo.html#a63477e691c43eca2dbf569fb0feb74be">_DMXLocalInitInfo::maxval</a>, <a class="el" href="struct__DMXLocalInitInfo.html#a139fed62b89a92d80997166c8cfcdebf">_DMXLocalInitInfo::minres</a>, <a class="el" href="struct__DMXLocalInitInfo.html#a0c47ee21909227a1ea5d40ba473e0e25">_DMXLocalInitInfo::minval</a>, <a class="el" href="struct__DMXLocalInitInfo.html#a9264f367a1c1e252679299b00f94458c">_DMXLocalInitInfo::numButtons</a>, <a class="el" href="struct__DMXLocalInitInfo.html#a5e192625179bbed020a720e448c789aa">_DMXLocalInitInfo::numRelAxes</a>, <a class="el" href="lnx-ps2_8c.html#a0f65c382ff39d64cd881a919eb566964">ps2LinuxGetMap()</a>, <a class="el" href="struct__DMXLocalInitInfo.html#a1c52bc6e1c328ef9e808a111dd050fc2">_DMXLocalInitInfo::ptrFeedbackClass</a>, <a class="el" href="struct__DMXLocalInitInfo.html#abb910012dc1abde90f954354f8ceb2a1">_DMXLocalInitInfo::res</a>, and <a class="el" href="struct__DMXLocalInitInfo.html#a9af277d2da1ade2138488a413e9c5ceb">_DMXLocalInitInfo::valuatorClass</a>.</p> 521 522</div> 523</div> 524<a class="anchor" id="a0f65c382ff39d64cd881a919eb566964"></a><!-- doxytag: member="lnx-ps2.c::ps2LinuxGetMap" ref="a0f65c382ff39d64cd881a919eb566964" args="(DevicePtr pDev, unsigned char *map, int *nButtons)" --> 525<div class="memitem"> 526<div class="memproto"> 527 <table class="memname"> 528 <tr> 529 <td class="memname">static void ps2LinuxGetMap </td> 530 <td>(</td> 531 <td class="paramtype">DevicePtr </td> 532 <td class="paramname"><em>pDev</em>, </td> 533 </tr> 534 <tr> 535 <td class="paramkey"></td> 536 <td></td> 537 <td class="paramtype">unsigned char * </td> 538 <td class="paramname"><em>map</em>, </td> 539 </tr> 540 <tr> 541 <td class="paramkey"></td> 542 <td></td> 543 <td class="paramtype">int * </td> 544 <td class="paramname"><em>nButtons</em> </td> 545 </tr> 546 <tr> 547 <td></td> 548 <td>)</td> 549 <td></td><td><code> [static]</code></td> 550 </tr> 551 </table> 552</div> 553<div class="memdoc"> 554 555<p>Referenced by <a class="el" href="lnx-ps2_8h.html#ab914e24acbae5ce49174e06842ac684b">ps2LinuxGetInfo()</a>.</p> 556 557</div> 558</div> 559<a class="anchor" id="aa0f0b690de9e5c3a958909000c7f787d"></a><!-- doxytag: member="lnx-ps2.c::ps2LinuxInit" ref="aa0f0b690de9e5c3a958909000c7f787d" args="(DevicePtr pDev)" --> 560<div class="memitem"> 561<div class="memproto"> 562 <table class="memname"> 563 <tr> 564 <td class="memname">void ps2LinuxInit </td> 565 <td>(</td> 566 <td class="paramtype">DevicePtr </td> 567 <td class="paramname"><em>pDev</em></td><td>)</td> 568 <td></td> 569 </tr> 570 </table> 571</div> 572<div class="memdoc"> 573<p>Initialize <em>pDev</em>. </p> 574 575<p>References <a class="el" href="lnx-ps2_8c.html#a11bcea7c6bc7dbe400a3855f5b8676ce">FATAL1</a>, <a class="el" href="lnx-ps2_8c.html#aacf069d346230dd96812d5395728eef2">GETPRIV</a>, and <a class="el" href="dmxsigio_8c.html#a39d33ce33804efd4d52606d59071c6d8">O_NONBLOCK</a>.</p> 576 577<p>Referenced by <a class="el" href="lnx-ps2_8h.html#aaf9aaca79e044d91f072901ad3be1863">ps2LinuxOn()</a>.</p> 578 579</div> 580</div> 581<a class="anchor" id="af955e539213ec85f5b6d5d7b38dae89e"></a><!-- doxytag: member="lnx-ps2.c::ps2LinuxOff" ref="af955e539213ec85f5b6d5d7b38dae89e" args="(DevicePtr pDev)" --> 582<div class="memitem"> 583<div class="memproto"> 584 <table class="memname"> 585 <tr> 586 <td class="memname">void ps2LinuxOff </td> 587 <td>(</td> 588 <td class="paramtype">DevicePtr </td> 589 <td class="paramname"><em>pDev</em></td><td>)</td> 590 <td></td> 591 </tr> 592 </table> 593</div> 594<div class="memdoc"> 595<p>Turn <em>pDev</em> off (i.e., stop taking input from <em>pDev</em>). </p> 596 597<p>References <a class="el" href="lnx-ps2_8c.html#aacf069d346230dd96812d5395728eef2">GETPRIV</a>.</p> 598 599</div> 600</div> 601<a class="anchor" id="aaf9aaca79e044d91f072901ad3be1863"></a><!-- doxytag: member="lnx-ps2.c::ps2LinuxOn" ref="aaf9aaca79e044d91f072901ad3be1863" args="(DevicePtr pDev)" --> 602<div class="memitem"> 603<div class="memproto"> 604 <table class="memname"> 605 <tr> 606 <td class="memname">int ps2LinuxOn </td> 607 <td>(</td> 608 <td class="paramtype">DevicePtr </td> 609 <td class="paramname"><em>pDev</em></td><td>)</td> 610 <td></td> 611 </tr> 612 </table> 613</div> 614<div class="memdoc"> 615<p>Turn <em>pDev</em> on (i.e., take input from <em>pDev</em>). </p> 616 617<p>References <a class="el" href="lnx-ps2_8c.html#aacf069d346230dd96812d5395728eef2">GETPRIV</a>, and <a class="el" href="lnx-ps2_8c.html#aa0f0b690de9e5c3a958909000c7f787d">ps2LinuxInit()</a>.</p> 618 619</div> 620</div> 621<a class="anchor" id="a373ac6b94ea32ce3f7329404ba1ae382"></a><!-- doxytag: member="lnx-ps2.c::ps2LinuxRead" ref="a373ac6b94ea32ce3f7329404ba1ae382" args="(DevicePtr pDev, MOTIONPROC motion, ENQUEUEPROC enqueue, CHECKPROC checkspecial, BLOCK block)" --> 622<div class="memitem"> 623<div class="memproto"> 624 <table class="memname"> 625 <tr> 626 <td class="memname">void ps2LinuxRead </td> 627 <td>(</td> 628 <td class="paramtype">DevicePtr </td> 629 <td class="paramname"><em>pDev</em>, </td> 630 </tr> 631 <tr> 632 <td class="paramkey"></td> 633 <td></td> 634 <td class="paramtype">MOTIONPROC </td> 635 <td class="paramname"><em>motion</em>, </td> 636 </tr> 637 <tr> 638 <td class="paramkey"></td> 639 <td></td> 640 <td class="paramtype">ENQUEUEPROC </td> 641 <td class="paramname"><em>enqueue</em>, </td> 642 </tr> 643 <tr> 644 <td class="paramkey"></td> 645 <td></td> 646 <td class="paramtype">CHECKPROC </td> 647 <td class="paramname"><em>checkspecial</em>, </td> 648 </tr> 649 <tr> 650 <td class="paramkey"></td> 651 <td></td> 652 <td class="paramtype">BLOCK </td> 653 <td class="paramname"><em>block</em> </td> 654 </tr> 655 <tr> 656 <td></td> 657 <td>)</td> 658 <td></td><td></td> 659 </tr> 660 </table> 661</div> 662<div class="memdoc"> 663<p>Read an event from the <em>pDev</em> device. If the event is a motion event, enqueue it with the <em>motion</em> function. Otherwise, check for special keys with the <em>checkspecial</em> function and enqueue the event with the <em>enqueue</em> function. The <em>block</em> type is passed to the functions so that they may block SIGIO handling as appropriate to the caller of this function. </p> 664 665<p>References <a class="el" href="lnx-ps2_8c.html#aacf069d346230dd96812d5395728eef2">GETPRIV</a>, <a class="el" href="lnx-ps2_8c.html#af3ff29bf7e70049ca978bc8fbff4aab6">ps2LinuxButton()</a>, and <a class="el" href="lnx-ps2_8c.html#ad806e9804e49f47d75f252ab0b14c075">ps2LinuxReadBytes()</a>.</p> 666 667</div> 668</div> 669<a class="anchor" id="ad806e9804e49f47d75f252ab0b14c075"></a><!-- doxytag: member="lnx-ps2.c::ps2LinuxReadBytes" ref="ad806e9804e49f47d75f252ab0b14c075" args="(int fd, unsigned char *buf, int len, int min)" --> 670<div class="memitem"> 671<div class="memproto"> 672 <table class="memname"> 673 <tr> 674 <td class="memname">static int ps2LinuxReadBytes </td> 675 <td>(</td> 676 <td class="paramtype">int </td> 677 <td class="paramname"><em>fd</em>, </td> 678 </tr> 679 <tr> 680 <td class="paramkey"></td> 681 <td></td> 682 <td class="paramtype">unsigned char * </td> 683 <td class="paramname"><em>buf</em>, </td> 684 </tr> 685 <tr> 686 <td class="paramkey"></td> 687 <td></td> 688 <td class="paramtype">int </td> 689 <td class="paramname"><em>len</em>, </td> 690 </tr> 691 <tr> 692 <td class="paramkey"></td> 693 <td></td> 694 <td class="paramtype">int </td> 695 <td class="paramname"><em>min</em> </td> 696 </tr> 697 <tr> 698 <td></td> 699 <td>)</td> 700 <td></td><td><code> [static]</code></td> 701 </tr> 702 </table> 703</div> 704<div class="memdoc"> 705 706<p>Referenced by <a class="el" href="lnx-ps2_8c.html#a373ac6b94ea32ce3f7329404ba1ae382">ps2LinuxRead()</a>.</p> 707 708</div> 709</div> 710<a class="anchor" id="a11a5bfc4866f86dfe3ea5acb788c4afe"></a><!-- doxytag: member="lnx-ps2.c::ps2LinuxVTPostSwitch" ref="a11a5bfc4866f86dfe3ea5acb788c4afe" args="(pointer p)" --> 711<div class="memitem"> 712<div class="memproto"> 713 <table class="memname"> 714 <tr> 715 <td class="memname">void ps2LinuxVTPostSwitch </td> 716 <td>(</td> 717 <td class="paramtype">pointer </td> 718 <td class="paramname"><em>p</em></td><td>)</td> 719 <td></td> 720 </tr> 721 </table> 722</div> 723<div class="memdoc"> 724<p>Currently unused hook called after returning from a VT switch. </p> 725 726</div> 727</div> 728<a class="anchor" id="a3a9ac063b46a191b38d92881367d74d4"></a><!-- doxytag: member="lnx-ps2.c::ps2LinuxVTPreSwitch" ref="a3a9ac063b46a191b38d92881367d74d4" args="(pointer p)" --> 729<div class="memitem"> 730<div class="memproto"> 731 <table class="memname"> 732 <tr> 733 <td class="memname">void ps2LinuxVTPreSwitch </td> 734 <td>(</td> 735 <td class="paramtype">pointer </td> 736 <td class="paramname"><em>p</em></td><td>)</td> 737 <td></td> 738 </tr> 739 </table> 740</div> 741<div class="memdoc"> 742<p>Currently unused hook called prior to an VT switch. </p> 743 744</div> 745</div> 746</div> 747</div> 748 <div id="nav-path" class="navpath"> 749 <ul> 750 <li class="navelem"><a class="el" href="lnx-ps2_8c.html">lnx-ps2.c</a> </li> 751 <hr> 752 <address> 753 <small> 754 Generated June 29, 2004 for <a 755 href="http://dmx.sourceforge.net">Distributed Multihead X</a> by 756 <a href="http://www.doxygen.org/index.html">doxygen</a> 757 1.3.4. 758 </small> 759 </addres> 760 </hr> 761 </body> 762</html> 763