1 |
2 |
alfik |
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
2 |
|
|
<html xmlns="http://www.w3.org/1999/xhtml">
|
3 |
|
|
<head>
|
4 |
|
|
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
5 |
|
|
<title>aoOCS: ocs_input.v Source File</title>
|
6 |
|
|
<link href="tabs.css" rel="stylesheet" type="text/css"/>
|
7 |
|
|
<link href="doxygen.css" rel="stylesheet" type="text/css"/>
|
8 |
|
|
</head>
|
9 |
|
|
<body>
|
10 |
|
|
<!-- Generated by Doxygen 1.7.2 -->
|
11 |
|
|
<div class="navigation" id="top">
|
12 |
|
|
<div class="tabs">
|
13 |
|
|
<ul class="tablist">
|
14 |
|
|
<li><a href="index.html"><span>Main Page</span></a></li>
|
15 |
|
|
<li><a href="annotated.html"><span>Design Unit List</span></a></li>
|
16 |
|
|
<li class="current"><a href="files.html"><span>Files</span></a></li>
|
17 |
|
|
</ul>
|
18 |
|
|
</div>
|
19 |
|
|
<div class="tabs2">
|
20 |
|
|
<ul class="tablist">
|
21 |
|
|
<li><a href="files.html"><span>File List</span></a></li>
|
22 |
|
|
<li><a href="globals.html"><span>File Members</span></a></li>
|
23 |
|
|
</ul>
|
24 |
|
|
</div>
|
25 |
|
|
<div class="header">
|
26 |
|
|
<div class="headertitle">
|
27 |
|
|
<h1>ocs_input.v</h1> </div>
|
28 |
|
|
</div>
|
29 |
|
|
<div class="contents">
|
30 |
|
|
<a href="ocs__input_8v.html">Go to the documentation of this file.</a><div class="fragment"><pre class="fragment"><a name="l00001"></a>00001 <span class="keyword">/*</span>
|
31 |
|
|
<a name="l00002"></a>00002 <span class="keyword"> Copyright 2010, Aleksander Osman, alfik@poczta.fm. All rights reserved.</span>
|
32 |
|
|
<a name="l00003"></a>00003 <span class="keyword"> </span>
|
33 |
|
|
<a name="l00004"></a>00004 <span class="keyword"> Redistribution and use in source and binary forms, with or without modification, are</span>
|
34 |
|
|
<a name="l00005"></a>00005 <span class="keyword"> permitted provided that the following conditions are met:</span>
|
35 |
|
|
<a name="l00006"></a>00006 <span class="keyword"> </span>
|
36 |
|
|
<a name="l00007"></a>00007 <span class="keyword"> 1. Redistributions of source code must retain the above copyright notice, this list of</span>
|
37 |
|
|
<a name="l00008"></a>00008 <span class="keyword"> conditions and the following disclaimer.</span>
|
38 |
|
|
<a name="l00009"></a>00009 <span class="keyword"> </span>
|
39 |
|
|
<a name="l00010"></a>00010 <span class="keyword"> 2. Redistributions in binary form must reproduce the above copyright notice, this list</span>
|
40 |
|
|
<a name="l00011"></a>00011 <span class="keyword"> of conditions and the following disclaimer in the documentation and/or other materials</span>
|
41 |
|
|
<a name="l00012"></a>00012 <span class="keyword"> provided with the distribution.</span>
|
42 |
|
|
<a name="l00013"></a>00013 <span class="keyword"> </span>
|
43 |
|
|
<a name="l00014"></a>00014 <span class="keyword"> THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED</span>
|
44 |
|
|
<a name="l00015"></a>00015 <span class="keyword"> WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND</span>
|
45 |
|
|
<a name="l00016"></a>00016 <span class="keyword"> FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR</span>
|
46 |
|
|
<a name="l00017"></a>00017 <span class="keyword"> CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR</span>
|
47 |
|
|
<a name="l00018"></a>00018 <span class="keyword"> CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR</span>
|
48 |
|
|
<a name="l00019"></a>00019 <span class="keyword"> SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON</span>
|
49 |
|
|
<a name="l00020"></a>00020 <span class="keyword"> ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING</span>
|
50 |
|
|
<a name="l00021"></a>00021 <span class="keyword"> NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF</span>
|
51 |
|
|
<a name="l00022"></a>00022 <span class="keyword"> ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.</span>
|
52 |
|
|
<a name="l00023"></a>00023 <span class="keyword"> */</span>
|
53 |
|
|
<a name="l00024"></a>00024
|
54 |
|
|
<a name="l00025"></a>00025 <span class="keyword">/*! \file</span>
|
55 |
|
|
<a name="l00026"></a>00026 <span class="keyword"> \brief OCS user input implementation with WISHBONE slave interface.</span>
|
56 |
|
|
<a name="l00027"></a>00027 <span class="keyword"> */</span>
|
57 |
|
|
<a name="l00028"></a>00028
|
58 |
|
|
<a name="l00029"></a>00029 <span class="keyword">/*! \brief \copybrief ocs_input.v</span>
|
59 |
|
|
<a name="l00030"></a>00030 <span class="keyword"></span>
|
60 |
|
|
<a name="l00031"></a>00031 <span class="keyword">List of user input registers:</span>
|
61 |
|
|
<a name="l00032"></a>00032 <span class="keyword">\verbatim</span>
|
62 |
|
|
<a name="l00033"></a>00033 <span class="keyword">Implemented:</span>
|
63 |
|
|
<a name="l00034"></a>00034 <span class="keyword"> [DSKDATR & *008 ER P Disk data early read (dummy address) not implemented]</span>
|
64 |
|
|
<a name="l00035"></a>00035 <span class="keyword"> JOY0DAT *00A R D Joystick-mouse 0 data (vert,horiz) read implemented here</span>
|
65 |
|
|
<a name="l00036"></a>00036 <span class="keyword"> </span>
|
66 |
|
|
<a name="l00037"></a>00037 <span class="keyword"> JOY1DAT *00C R D Joystick-mouse 1 data (vert,horiz) read implemented here</span>
|
67 |
|
|
<a name="l00038"></a>00038 <span class="keyword"> [CLXDAT *00E R D Collision data register (read and clear) read implemented here]</span>
|
68 |
|
|
<a name="l00039"></a>00039 <span class="keyword"> </span>
|
69 |
|
|
<a name="l00040"></a>00040 <span class="keyword"> JOYTEST *036 W D Write to all four joystick-mouse counters at once</span>
|
70 |
|
|
<a name="l00041"></a>00041 <span class="keyword"></span>
|
71 |
|
|
<a name="l00042"></a>00042 <span class="keyword">Not implemented:</span>
|
72 |
|
|
<a name="l00043"></a>00043 <span class="keyword"> [ADKCONR *010 R P Audio, disk control register read read not implemented here]</span>
|
73 |
|
|
<a name="l00044"></a>00044 <span class="keyword"> POT0DAT *012 R P( E ) Pot counter pair 0 data (vert,horiz) read not implemented here</span>
|
74 |
|
|
<a name="l00045"></a>00045 <span class="keyword"> </span>
|
75 |
|
|
<a name="l00046"></a>00046 <span class="keyword"> POT1DAT *014 R P( E ) Pot counter pair 1 data (vert,horiz) </span>
|
76 |
|
|
<a name="l00047"></a>00047 <span class="keyword"> POTGOR *016 R P Pot port data read (formerly POTINP)</span>
|
77 |
|
|
<a name="l00048"></a>00048 <span class="keyword"> POTGO *034 W P Pot port data write and start</span>
|
78 |
|
|
<a name="l00049"></a>00049 <span class="keyword">\endverbatim</span>
|
79 |
|
|
<a name="l00050"></a>00050 <span class="keyword">*/</span>
|
80 |
|
|
<a name="l00051"></a><a class="code" href="classocs__input.html">00051</a> <span class="vhdlkeyword">module</span> <a class="code" href="classocs__input.html">ocs_input</a>(
|
81 |
|
|
<a name="l00052"></a>00052 <span class="keyword">//% \name Clock and reset
|
82 |
|
|
</span>
|
83 |
|
|
<a name="l00053"></a>00053 <span class="keyword">//% @{</span>
|
84 |
|
|
<a name="l00054"></a><a class="code" href="classocs__input.html#a4097ecb98b3486fbfb7e2b2354299e38">00054</a> <span class="vhdlkeyword">input</span> <a class="code" href="classocs__input.html#a4097ecb98b3486fbfb7e2b2354299e38">CLK_I</a>,
|
85 |
|
|
<a name="l00055"></a><a class="code" href="classocs__input.html#a19d0cfb3cf1132c9faae0217a1af82a9">00055</a> <span class="vhdlkeyword">input</span> <a class="code" href="classocs__input.html#a19d0cfb3cf1132c9faae0217a1af82a9">reset_n</a>,
|
86 |
|
|
<a name="l00056"></a>00056 <span class="keyword">//% @}</span>
|
87 |
|
|
<a name="l00057"></a>00057
|
88 |
|
|
<a name="l00058"></a>00058 <span class="keyword">//% \name On-Screen-Display management interface
|
89 |
|
|
</span>
|
90 |
|
|
<a name="l00059"></a>00059 <span class="keyword">//% @{</span>
|
91 |
|
|
<a name="l00060"></a><a class="code" href="classocs__input.html#aa93b8e862d09f357d3051b77f7729a5b">00060</a> <span class="vhdlkeyword">input</span> <a class="code" href="classocs__input.html#aa93b8e862d09f357d3051b77f7729a5b">on_screen_display</a>,
|
92 |
|
|
<a name="l00061"></a><a class="code" href="classocs__input.html#ad0086d7ef7043c9684dce50476516b07">00061</a> <span class="vhdlkeyword">input</span> <a class="code" href="classocs__input.html#ad0086d7ef7043c9684dce50476516b07">enable_joystick_1</a>,
|
93 |
|
|
<a name="l00062"></a>00062 <span class="keyword">//% @}</span>
|
94 |
|
|
<a name="l00063"></a>00063
|
95 |
|
|
<a name="l00064"></a>00064 <span class="keyword">//% \name WISHBONE slave
|
96 |
|
|
</span>
|
97 |
|
|
<a name="l00065"></a>00065 <span class="keyword">//% @{</span>
|
98 |
|
|
<a name="l00066"></a><a class="code" href="classocs__input.html#a63add4610448cadee61e25e90f8ad230">00066</a> <span class="vhdlkeyword">input</span> <a class="code" href="classocs__input.html#a63add4610448cadee61e25e90f8ad230">CYC_I</a>,
|
99 |
|
|
<a name="l00067"></a><a class="code" href="classocs__input.html#a0195704c730e8409598612d24b132638">00067</a> <span class="vhdlkeyword">input</span> <a class="code" href="classocs__input.html#a0195704c730e8409598612d24b132638">STB_I</a>,
|
100 |
|
|
<a name="l00068"></a><a class="code" href="classocs__input.html#a0f5def2e35084feb5c4c865cb035a69b">00068</a> <span class="vhdlkeyword">input</span> <a class="code" href="classocs__input.html#a0f5def2e35084feb5c4c865cb035a69b">WE_I</a>,
|
101 |
|
|
<a name="l00069"></a><a class="code" href="classocs__input.html#adadf762e792187ce934c130d857406dd">00069</a> <span class="vhdlkeyword">input</span> [<span class="vhdllogic">8</span>:<span class="vhdllogic">2</span>] <a class="code" href="classocs__input.html#adadf762e792187ce934c130d857406dd">ADR_I</a>,
|
102 |
|
|
<a name="l00070"></a><a class="code" href="classocs__input.html#a4a73b8f2dadbf0d6fd507e8cac3e60be">00070</a> <span class="vhdlkeyword">input</span> [<span class="vhdllogic">3</span>:<span class="vhdllogic">0</span>] <a class="code" href="classocs__input.html#a4a73b8f2dadbf0d6fd507e8cac3e60be">SEL_I</a>,
|
103 |
|
|
<a name="l00071"></a><a class="code" href="classocs__input.html#a5c942679add23334af2d790a3bd5c40b">00071</a> <span class="vhdlkeyword">input</span> [<span class="vhdllogic">31</span>:<span class="vhdllogic">0</span>] <a class="code" href="classocs__input.html#a5c942679add23334af2d790a3bd5c40b">DAT_I</a>,
|
104 |
|
|
<a name="l00072"></a><a class="code" href="classocs__input.html#a6000765cc199349aaad0e03fe0180b28">00072</a> <span class="vhdlkeyword">output</span> <span class="vhdlkeyword">reg</span> [<span class="vhdllogic">31</span>:<span class="vhdllogic">0</span>] <a class="code" href="classocs__input.html#a6000765cc199349aaad0e03fe0180b28">DAT_O</a>,
|
105 |
|
|
<a name="l00073"></a><a class="code" href="classocs__input.html#af910719de637b73f108aa9b5802fb752">00073</a> <span class="vhdlkeyword">output</span> <span class="vhdlkeyword">reg</span> <a class="code" href="classocs__input.html#af910719de637b73f108aa9b5802fb752">ACK_O</a>,
|
106 |
|
|
<a name="l00074"></a>00074 <span class="keyword">//% @}</span>
|
107 |
|
|
<a name="l00075"></a>00075
|
108 |
|
|
<a name="l00076"></a>00076 <span class="keyword">//% \name Not aligned register access on a 32-bit WISHBONE bus
|
109 |
|
|
</span>
|
110 |
|
|
<a name="l00077"></a>00077 <span class="keyword">//% @{</span>
|
111 |
|
|
<a name="l00078"></a>00078 <span class="keyword">// CLXDAT read implemented here</span>
|
112 |
|
|
<a name="l00079"></a><a class="code" href="classocs__input.html#a8699f751f090e01f2d03e95bdf4e957f">00079</a> <span class="vhdlkeyword">output</span> <a class="code" href="classocs__input.html#a8699f751f090e01f2d03e95bdf4e957f">na_clx_dat_read</a>,
|
113 |
|
|
<a name="l00080"></a><a class="code" href="classocs__input.html#a9766cf787373f3fdefea5eae308f9822">00080</a> <span class="vhdlkeyword">input</span> [<span class="vhdllogic">15</span>:<span class="vhdllogic">0</span>] <a class="code" href="classocs__input.html#a9766cf787373f3fdefea5eae308f9822">na_clx_dat</a>,
|
114 |
|
|
<a name="l00081"></a>00081 <span class="keyword">// POT0DAT read not implemented here</span>
|
115 |
|
|
<a name="l00082"></a><a class="code" href="classocs__input.html#a1de5afd46d7f97d4a56bc3e5ce199a89">00082</a> <span class="vhdlkeyword">input</span> <a class="code" href="classocs__input.html#a1de5afd46d7f97d4a56bc3e5ce199a89">na_pot0dat_read</a>,
|
116 |
|
|
<a name="l00083"></a><a class="code" href="classocs__input.html#a61718b31aa58d788924985eac70334a4">00083</a> <span class="vhdlkeyword">output</span> [<span class="vhdllogic">15</span>:<span class="vhdllogic">0</span>] <a class="code" href="classocs__input.html#a61718b31aa58d788924985eac70334a4">na_pot0dat</a>,
|
117 |
|
|
<a name="l00084"></a>00084 <span class="keyword">//% @}</span>
|
118 |
|
|
<a name="l00085"></a>00085
|
119 |
|
|
<a name="l00086"></a>00086 <span class="keyword">//% \name User input CIA interface
|
120 |
|
|
</span>
|
121 |
|
|
<a name="l00087"></a>00087 <span class="keyword">//% @{</span>
|
122 |
|
|
<a name="l00088"></a>00088 <span class="keyword">// keyboard output</span>
|
123 |
|
|
<a name="l00089"></a><a class="code" href="classocs__input.html#a0fa9f11b067c96f7175ded9a8c5f158e">00089</a> <span class="vhdlkeyword">input</span> <a class="code" href="classocs__input.html#a0fa9f11b067c96f7175ded9a8c5f158e">sp_from_cia</a>,
|
124 |
|
|
<a name="l00090"></a><a class="code" href="classocs__input.html#aa168bfc6e82811a06fad37852e44ba33">00090</a> <span class="vhdlkeyword">output</span> <a class="code" href="classocs__input.html#aa168bfc6e82811a06fad37852e44ba33">sp_to_cia</a>,
|
125 |
|
|
<a name="l00091"></a><a class="code" href="classocs__input.html#ae43882f1c230365641bd96aa4478967a">00091</a> <span class="vhdlkeyword">output</span> <span class="vhdlkeyword">reg</span> <a class="code" href="classocs__input.html#ae43882f1c230365641bd96aa4478967a">cnt_to_cia</a>,
|
126 |
|
|
<a name="l00092"></a>00092
|
127 |
|
|
<a name="l00093"></a>00093 <span class="keyword">// CIA-A fire buttons</span>
|
128 |
|
|
<a name="l00094"></a><a class="code" href="classocs__input.html#a57aaae6a32563490c2a7e22aa86935c2">00094</a> <span class="vhdlkeyword">output</span> <span class="vhdlkeyword">reg</span> <a class="code" href="classocs__input.html#a57aaae6a32563490c2a7e22aa86935c2">ciaa_fire_0_n</a>,
|
129 |
|
|
<a name="l00095"></a><a class="code" href="classocs__input.html#a6f401ee89b8343868c96a03e9df59ec4">00095</a> <span class="vhdlkeyword">output</span> <a class="code" href="classocs__input.html#a6f401ee89b8343868c96a03e9df59ec4">ciaa_fire_1_n</a>,
|
130 |
|
|
<a name="l00096"></a>00096 <span class="keyword">//% @}</span>
|
131 |
|
|
<a name="l00097"></a>00097
|
132 |
|
|
<a name="l00098"></a>00098 <span class="keyword">//% \name drv_keyboard interface
|
133 |
|
|
</span>
|
134 |
|
|
<a name="l00099"></a>00099 <span class="keyword">//% @{</span>
|
135 |
|
|
<a name="l00100"></a><a class="code" href="classocs__input.html#afdc7af614b83ee930342c25bda91a4b3">00100</a> <span class="vhdlkeyword">output</span> <a class="code" href="classocs__input.html#afdc7af614b83ee930342c25bda91a4b3">keyboard_ready</a>,
|
136 |
|
|
<a name="l00101"></a><a class="code" href="classocs__input.html#a77547e436c339e958e169ccee8c1dc69">00101</a> <span class="vhdlkeyword">input</span> <a class="code" href="classocs__input.html#a77547e436c339e958e169ccee8c1dc69">keyboard_event</a>,
|
137 |
|
|
<a name="l00102"></a><a class="code" href="classocs__input.html#a19f8bd6a94b8097c719d800565e606d8">00102</a> <span class="vhdlkeyword">input</span> [<span class="vhdllogic">7</span>:<span class="vhdllogic">0</span>] <a class="code" href="classocs__input.html#a19f8bd6a94b8097c719d800565e606d8">keyboard_scancode</a>,
|
138 |
|
|
<a name="l00103"></a>00103
|
139 |
|
|
<a name="l00104"></a>00104 <span class="keyword">// joystick on port 1</span>
|
140 |
|
|
<a name="l00105"></a><a class="code" href="classocs__input.html#acdbaf74eac667d96f9513f12e3b3b8f2">00105</a> <span class="vhdlkeyword">input</span> <a class="code" href="classocs__input.html#acdbaf74eac667d96f9513f12e3b3b8f2">joystick_1_up</a>,
|
141 |
|
|
<a name="l00106"></a><a class="code" href="classocs__input.html#aa7dd38a5809543d625453b6fe34ff975">00106</a> <span class="vhdlkeyword">input</span> <a class="code" href="classocs__input.html#aa7dd38a5809543d625453b6fe34ff975">joystick_1_down</a>,
|
142 |
|
|
<a name="l00107"></a><a class="code" href="classocs__input.html#af59aaf36ae35866073aaf1ad6cf3d0ab">00107</a> <span class="vhdlkeyword">input</span> <a class="code" href="classocs__input.html#af59aaf36ae35866073aaf1ad6cf3d0ab">joystick_1_left</a>,
|
143 |
|
|
<a name="l00108"></a><a class="code" href="classocs__input.html#aecf900811a4bd3b33eb68f2bc1f0fa4b">00108</a> <span class="vhdlkeyword">input</span> <a class="code" href="classocs__input.html#aecf900811a4bd3b33eb68f2bc1f0fa4b">joystick_1_right</a>,
|
144 |
|
|
<a name="l00109"></a><a class="code" href="classocs__input.html#a7181fb20f607314bb1adb7b2e87f8ffb">00109</a> <span class="vhdlkeyword">input</span> <a class="code" href="classocs__input.html#a7181fb20f607314bb1adb7b2e87f8ffb">joystick_1_fire</a>,
|
145 |
|
|
<a name="l00110"></a>00110 <span class="keyword">//% @}</span>
|
146 |
|
|
<a name="l00111"></a>00111
|
147 |
|
|
<a name="l00112"></a>00112 <span class="keyword">//% \name drv_mouse interface
|
148 |
|
|
</span>
|
149 |
|
|
<a name="l00113"></a>00113 <span class="keyword">//% @{</span>
|
150 |
|
|
<a name="l00114"></a><a class="code" href="classocs__input.html#a6c1420349b39d1da8dd088cd5d011f1a">00114</a> <span class="vhdlkeyword">input</span> <a class="code" href="classocs__input.html#a6c1420349b39d1da8dd088cd5d011f1a">mouse_moved</a>,
|
151 |
|
|
<a name="l00115"></a><a class="code" href="classocs__input.html#a33f252f3d12c92f30fedb23105116f57">00115</a> <span class="vhdlkeyword">input</span> [<span class="vhdllogic">8</span>:<span class="vhdllogic">0</span>] <a class="code" href="classocs__input.html#a33f252f3d12c92f30fedb23105116f57">mouse_y_move</a>,
|
152 |
|
|
<a name="l00116"></a><a class="code" href="classocs__input.html#ae7856c7d789112c571ab5a911182f772">00116</a> <span class="vhdlkeyword">input</span> [<span class="vhdllogic">8</span>:<span class="vhdllogic">0</span>] <a class="code" href="classocs__input.html#ae7856c7d789112c571ab5a911182f772">mouse_x_move</a>,
|
153 |
|
|
<a name="l00117"></a><a class="code" href="classocs__input.html#ad1a969d2559b895471a9622ebbe72bac">00117</a> <span class="vhdlkeyword">input</span> <a class="code" href="classocs__input.html#ad1a969d2559b895471a9622ebbe72bac">mouse_left_button</a>,
|
154 |
|
|
<a name="l00118"></a><a class="code" href="classocs__input.html#ab940629f6aca8ebb676f9109161ac567">00118</a> <span class="vhdlkeyword">input</span> <a class="code" href="classocs__input.html#ab940629f6aca8ebb676f9109161ac567">mouse_right_button</a>,
|
155 |
|
|
<a name="l00119"></a><a class="code" href="classocs__input.html#aadba9a1aceecda48b561adfd42983f4c">00119</a> <span class="vhdlkeyword">input</span> <a class="code" href="classocs__input.html#aadba9a1aceecda48b561adfd42983f4c">mouse_middle_button</a>
|
156 |
|
|
<a name="l00120"></a>00120 <span class="keyword">//% @}</span>
|
157 |
|
|
<a name="l00121"></a>00121 );
|
158 |
|
|
<a name="l00122"></a>00122
|
159 |
|
|
<a name="l00123"></a>00123 <span class="keyword">//-------------------- keyboard start</span>
|
160 |
|
|
<a name="l00124"></a>00124 <span class="vhdlkeyword">assign</span> <a class="code" href="classocs__input.html#aa168bfc6e82811a06fad37852e44ba33">sp_to_cia</a> = ~<a class="code" href="classocs__input.html#a73080e1cc32872450bc2ea70235e2099">sp_shift</a>[<span class="vhdllogic">7</span>];
|
161 |
|
|
<a name="l00125"></a>00125
|
162 |
|
|
<a name="l00126"></a>00126 <span class="vhdlkeyword">assign</span> <a class="code" href="classocs__input.html#afdc7af614b83ee930342c25bda91a4b3">keyboard_ready</a> = (<a class="code" href="classocs__input.html#ac65746b5ef6a9ce4782ebf1eca626b30">cnt_counter</a> == <span class="vhdllogic">16'd0</span>);
|
163 |
|
|
<a name="l00127"></a>00127
|
164 |
|
|
<a name="l00128"></a>00128
|
165 |
|
|
<a name="l00129"></a><a class="code" href="classocs__input.html#ac65746b5ef6a9ce4782ebf1eca626b30">00129</a> <span class="vhdlkeyword">reg</span> [<span class="vhdllogic">15</span>:<span class="vhdllogic">0</span>] <a class="code" href="classocs__input.html#ac65746b5ef6a9ce4782ebf1eca626b30">cnt_counter</a>;
|
166 |
|
|
<a name="l00130"></a><a class="code" href="classocs__input.html#a73080e1cc32872450bc2ea70235e2099">00130</a> <span class="vhdlkeyword">reg</span> [<span class="vhdllogic">7</span>:<span class="vhdllogic">0</span>] <a class="code" href="classocs__input.html#a73080e1cc32872450bc2ea70235e2099">sp_shift</a>;
|
167 |
|
|
<a name="l00131"></a><a class="code" href="classocs__input.html#a0cc6604e25d987cd33dbc16ea249080c">00131</a> <span class="vhdlkeyword">always</span> @(<span class="vhdlkeyword">posedge</span> <a class="code" href="classocs__input.html#a4097ecb98b3486fbfb7e2b2354299e38">CLK_I</a> <span class="vhdlkeyword">or</span> <span class="vhdlkeyword">negedge</span> <a class="code" href="classocs__input.html#a19d0cfb3cf1132c9faae0217a1af82a9">reset_n</a>) <span class="vhdlkeyword">begin</span>
|
168 |
|
|
<a name="l00132"></a>00132 <span class="vhdlkeyword">if</span>(<a class="code" href="classocs__input.html#a19d0cfb3cf1132c9faae0217a1af82a9">reset_n</a> == <span class="vhdllogic">1'b0</span>) <span class="vhdlkeyword">begin</span>
|
169 |
|
|
<a name="l00133"></a>00133 <a class="code" href="classocs__input.html#ae43882f1c230365641bd96aa4478967a">cnt_to_cia</a> <= <span class="vhdllogic">1'b1</span>;
|
170 |
|
|
<a name="l00134"></a>00134 <a class="code" href="classocs__input.html#ac65746b5ef6a9ce4782ebf1eca626b30">cnt_counter</a> <= <span class="vhdllogic">16'd0</span>;
|
171 |
|
|
<a name="l00135"></a>00135 <a class="code" href="classocs__input.html#a73080e1cc32872450bc2ea70235e2099">sp_shift</a> <= <span class="vhdllogic">8'hFF</span>;
|
172 |
|
|
<a name="l00136"></a>00136 <span class="vhdlkeyword">end</span>
|
173 |
|
|
<a name="l00137"></a>00137 <span class="vhdlkeyword">else</span> <span class="vhdlkeyword">if</span>(<a class="code" href="classocs__input.html#a77547e436c339e958e169ccee8c1dc69">keyboard_event</a> == <span class="vhdllogic">1'b1</span> && <a class="code" href="classocs__input.html#aa93b8e862d09f357d3051b77f7729a5b">on_screen_display</a> == <span class="vhdllogic">1'b0</span>) <span class="vhdlkeyword">begin</span>
|
174 |
|
|
<a name="l00138"></a>00138 <a class="code" href="classocs__input.html#a73080e1cc32872450bc2ea70235e2099">sp_shift</a> <= <a class="code" href="classocs__input.html#a19f8bd6a94b8097c719d800565e606d8">keyboard_scancode</a>;
|
175 |
|
|
<a name="l00139"></a>00139 <a class="code" href="classocs__input.html#ac65746b5ef6a9ce4782ebf1eca626b30">cnt_counter</a> <= <a class="code" href="classocs__input.html#ac65746b5ef6a9ce4782ebf1eca626b30">cnt_counter</a> + <span class="vhdllogic">16'd1</span>;
|
176 |
|
|
<a name="l00140"></a>00140 <a class="code" href="classocs__input.html#ae43882f1c230365641bd96aa4478967a">cnt_to_cia</a> <= <span class="vhdllogic">1'b0</span>;
|
177 |
|
|
<a name="l00141"></a>00141 <span class="vhdlkeyword">end</span>
|
178 |
|
|
<a name="l00142"></a>00142 <span class="vhdlkeyword">else</span> <span class="vhdlkeyword">if</span>(<a class="code" href="classocs__input.html#ac65746b5ef6a9ce4782ebf1eca626b30">cnt_counter</a> >= <span class="vhdllogic">16'd1</span> && <a class="code" href="classocs__input.html#ac65746b5ef6a9ce4782ebf1eca626b30">cnt_counter</a> <= <span class="vhdllogic">16'd15</span>) <span class="vhdlkeyword">begin</span>
|
179 |
|
|
<a name="l00143"></a>00143 <a class="code" href="classocs__input.html#ac65746b5ef6a9ce4782ebf1eca626b30">cnt_counter</a> <= <a class="code" href="classocs__input.html#ac65746b5ef6a9ce4782ebf1eca626b30">cnt_counter</a> + <span class="vhdllogic">16'd1</span>;
|
180 |
|
|
<a name="l00144"></a>00144 <a class="code" href="classocs__input.html#ae43882f1c230365641bd96aa4478967a">cnt_to_cia</a> <= ~<a class="code" href="classocs__input.html#ae43882f1c230365641bd96aa4478967a">cnt_to_cia</a>;
|
181 |
|
|
<a name="l00145"></a>00145 <span class="vhdlkeyword">if</span>(<a class="code" href="classocs__input.html#ae43882f1c230365641bd96aa4478967a">cnt_to_cia</a> == <span class="vhdllogic">1'b1</span>) <a class="code" href="classocs__input.html#a73080e1cc32872450bc2ea70235e2099">sp_shift</a> <= { <a class="code" href="classocs__input.html#a73080e1cc32872450bc2ea70235e2099">sp_shift</a>[<span class="vhdllogic">6</span>:<span class="vhdllogic">0</span>], <span class="vhdllogic">1'b0</span> };
|
182 |
|
|
<a name="l00146"></a>00146 <span class="vhdlkeyword">end</span>
|
183 |
|
|
<a name="l00147"></a>00147 <span class="vhdlkeyword">else</span> <span class="vhdlkeyword">if</span>(<a class="code" href="classocs__input.html#ac65746b5ef6a9ce4782ebf1eca626b30">cnt_counter</a> == <span class="vhdllogic">16'd16</span> && <a class="code" href="classocs__input.html#a0fa9f11b067c96f7175ded9a8c5f158e">sp_from_cia</a> == <span class="vhdllogic">1'b0</span>) <span class="vhdlkeyword">begin</span>
|
184 |
|
|
<a name="l00148"></a>00148 <a class="code" href="classocs__input.html#ac65746b5ef6a9ce4782ebf1eca626b30">cnt_counter</a> <= <a class="code" href="classocs__input.html#ac65746b5ef6a9ce4782ebf1eca626b30">cnt_counter</a> + <span class="vhdllogic">16'd1</span>;
|
185 |
|
|
<a name="l00149"></a>00149 <span class="vhdlkeyword">end</span>
|
186 |
|
|
<a name="l00150"></a>00150 <span class="vhdlkeyword">else</span> <span class="vhdlkeyword">if</span>(<a class="code" href="classocs__input.html#ac65746b5ef6a9ce4782ebf1eca626b30">cnt_counter</a> == <span class="vhdllogic">16'd17</span> && <a class="code" href="classocs__input.html#a0fa9f11b067c96f7175ded9a8c5f158e">sp_from_cia</a> == <span class="vhdllogic">1'b1</span>) <span class="vhdlkeyword">begin</span>
|
187 |
|
|
<a name="l00151"></a>00151 <a class="code" href="classocs__input.html#ac65746b5ef6a9ce4782ebf1eca626b30">cnt_counter</a> <= <span class="vhdllogic">16'd0</span>;
|
188 |
|
|
<a name="l00152"></a>00152 <span class="vhdlkeyword">end</span>
|
189 |
|
|
<a name="l00153"></a>00153 <span class="keyword">/* synchronization</span>
|
190 |
|
|
<a name="l00154"></a>00154 <span class="keyword"> else if(cnt_counter == 16'd65535 && sp_from_cia == 1'b1) begin</span>
|
191 |
|
|
<a name="l00155"></a>00155 <span class="keyword"> cnt_to_cia <= ~cnt_to_cia;</span>
|
192 |
|
|
<a name="l00156"></a>00156 <span class="keyword"> cnt_counter <= 16'd16;</span>
|
193 |
|
|
<a name="l00157"></a>00157 <span class="keyword"> end</span>
|
194 |
|
|
<a name="l00158"></a>00158 <span class="keyword"> else if(cnt_counter >= 16'd16 && sp_from_cia == 1'b1) begin</span>
|
195 |
|
|
<a name="l00159"></a>00159 <span class="keyword"> cnt_counter <= cnt_counter + 16'd1;</span>
|
196 |
|
|
<a name="l00160"></a>00160 <span class="keyword"> end</span>
|
197 |
|
|
<a name="l00161"></a>00161 <span class="keyword"> else sp_from_cia == 1'b0 -> sp_from_cia == 1'b0 begin</span>
|
198 |
|
|
<a name="l00162"></a>00162 <span class="keyword"> cnt_counter <= 16'd0;</span>
|
199 |
|
|
<a name="l00163"></a>00163 <span class="keyword"> end</span>
|
200 |
|
|
<a name="l00164"></a>00164 <span class="keyword">*/</span>
|
201 |
|
|
<a name="l00165"></a>00165 <span class="vhdlkeyword">end</span>
|
202 |
|
|
<a name="l00166"></a>00166 <span class="keyword">//-------------------- keyboard end</span>
|
203 |
|
|
<a name="l00167"></a>00167
|
204 |
|
|
<a name="l00168"></a>00168
|
205 |
|
|
<a name="l00169"></a>00169 <span class="vhdlkeyword">assign</span> <a class="code" href="classocs__input.html#a61718b31aa58d788924985eac70334a4">na_pot0dat</a> = <span class="vhdllogic">16'd0</span>;
|
206 |
|
|
<a name="l00170"></a>00170
|
207 |
|
|
<a name="l00171"></a>00171 <span class="vhdlkeyword">assign</span> <a class="code" href="classocs__input.html#a8699f751f090e01f2d03e95bdf4e957f">na_clx_dat_read</a> =
|
208 |
|
|
<a name="l00172"></a>00172 (<a class="code" href="classocs__input.html#a63add4610448cadee61e25e90f8ad230">CYC_I</a> == <span class="vhdllogic">1'b1</span> && <a class="code" href="classocs__input.html#a0195704c730e8409598612d24b132638">STB_I</a> == <span class="vhdllogic">1'b1</span> && <a class="code" href="classocs__input.html#af910719de637b73f108aa9b5802fb752">ACK_O</a> == <span class="vhdllogic">1'b0</span> && <a class="code" href="classocs__input.html#a0f5def2e35084feb5c4c865cb035a69b">WE_I</a> == <span class="vhdllogic">1'b0</span> && { <a class="code" href="classocs__input.html#adadf762e792187ce934c130d857406dd">ADR_I</a>, <span class="vhdllogic">2'b0</span> } == <span class="vhdllogic">9'h018</span> && <a class="code" href="classocs__input.html#a4a73b8f2dadbf0d6fd507e8cac3e60be">SEL_I</a>[<span class="vhdllogic">1</span>:<span class="vhdllogic">0</span>] != <span class="vhdllogic">2'b00</span>);
|
209 |
|
|
<a name="l00173"></a>00173
|
210 |
|
|
<a name="l00174"></a><a class="code" href="classocs__input.html#a07f63851f6195cf877d80837996eae8a">00174</a> <span class="vhdlkeyword">reg</span> [<span class="vhdllogic">15</span>:<span class="vhdllogic">0</span>] <a class="code" href="classocs__input.html#a07f63851f6195cf877d80837996eae8a">potgo</a>;
|
211 |
|
|
<a name="l00175"></a><a class="code" href="classocs__input.html#aa73ed28d5c045ca4237b59bb5d81e1ba">00175</a> <span class="vhdlkeyword">reg</span> [<span class="vhdllogic">15</span>:<span class="vhdllogic">0</span>] <a class="code" href="classocs__input.html#aa73ed28d5c045ca4237b59bb5d81e1ba">joy0dat</a>;
|
212 |
|
|
<a name="l00176"></a><a class="code" href="classocs__input.html#ae161410b2c480aa12521d289ea73e072">00176</a> <span class="vhdlkeyword">reg</span> [<span class="vhdllogic">15</span>:<span class="vhdllogic">0</span>] <a class="code" href="classocs__input.html#ae161410b2c480aa12521d289ea73e072">joy1dat</a>;
|
213 |
|
|
<a name="l00177"></a><a class="code" href="classocs__input.html#a7e32f39227c244a369b6a4d758fe5bea">00177</a> <span class="vhdlkeyword">reg</span> <a class="code" href="classocs__input.html#a7e32f39227c244a369b6a4d758fe5bea">right_button_n</a>;
|
214 |
|
|
<a name="l00178"></a><a class="code" href="classocs__input.html#ac2df99f917f50e1213002937aba64059">00178</a> <span class="vhdlkeyword">reg</span> <a class="code" href="classocs__input.html#ac2df99f917f50e1213002937aba64059">middle_button_n</a>;
|
215 |
|
|
<a name="l00179"></a>00179
|
216 |
|
|
<a name="l00180"></a><a class="code" href="classocs__input.html#a000c86f2ec73eb492223357b22bea156">00180</a> <span class="vhdlkeyword">wire</span> [<span class="vhdllogic">15</span>:<span class="vhdllogic">0</span>] <a class="code" href="classocs__input.html#a000c86f2ec73eb492223357b22bea156">joy1dat_final</a>;
|
217 |
|
|
<a name="l00181"></a>00181 <span class="vhdlkeyword">assign</span> <a class="code" href="classocs__input.html#a000c86f2ec73eb492223357b22bea156">joy1dat_final</a> =
|
218 |
|
|
<a name="l00182"></a>00182 (<a class="code" href="classocs__input.html#ad0086d7ef7043c9684dce50476516b07">enable_joystick_1</a> == <span class="vhdllogic">1'b1</span>)?
|
219 |
|
|
<a name="l00183"></a>00183 { <span class="vhdllogic">6'b0</span>, <span class="keyword">//15-10</span>
|
220 |
|
|
<a name="l00184"></a>00184 <a class="code" href="classocs__input.html#af59aaf36ae35866073aaf1ad6cf3d0ab">joystick_1_left</a>, <span class="keyword">//9</span>
|
221 |
|
|
<a name="l00185"></a>00185 <a class="code" href="classocs__input.html#acdbaf74eac667d96f9513f12e3b3b8f2">joystick_1_up</a> ^ <a class="code" href="classocs__input.html#af59aaf36ae35866073aaf1ad6cf3d0ab">joystick_1_left</a>, <span class="keyword">//8</span>
|
222 |
|
|
<a name="l00186"></a>00186 <span class="vhdllogic">6'b0</span>, <span class="keyword">//7-2</span>
|
223 |
|
|
<a name="l00187"></a>00187 <a class="code" href="classocs__input.html#aecf900811a4bd3b33eb68f2bc1f0fa4b">joystick_1_right</a>, <span class="keyword">//1</span>
|
224 |
|
|
<a name="l00188"></a>00188 <a class="code" href="classocs__input.html#aa7dd38a5809543d625453b6fe34ff975">joystick_1_down</a> ^ <a class="code" href="classocs__input.html#aecf900811a4bd3b33eb68f2bc1f0fa4b">joystick_1_right</a> <span class="keyword">//0</span>
|
225 |
|
|
<a name="l00189"></a>00189 } :
|
226 |
|
|
<a name="l00190"></a>00190 <a class="code" href="classocs__input.html#ae161410b2c480aa12521d289ea73e072">joy1dat</a>;
|
227 |
|
|
<a name="l00191"></a>00191
|
228 |
|
|
<a name="l00192"></a>00192 <span class="vhdlkeyword">assign</span> <a class="code" href="classocs__input.html#a6f401ee89b8343868c96a03e9df59ec4">ciaa_fire_1_n</a> = (<a class="code" href="classocs__input.html#ad0086d7ef7043c9684dce50476516b07">enable_joystick_1</a> == <span class="vhdllogic">1'b1</span> && <a class="code" href="classocs__input.html#a7181fb20f607314bb1adb7b2e87f8ffb">joystick_1_fire</a> == <span class="vhdllogic">1'b1</span>)? <span class="vhdllogic">1'b0</span> : <span class="vhdllogic">1'b1</span>;
|
229 |
|
|
<a name="l00193"></a>00193
|
230 |
|
|
<a name="l00194"></a><a class="code" href="classocs__input.html#a615e9602b96fba12455352bb5d52c47f">00194</a> <span class="vhdlkeyword">wire</span> [<span class="vhdllogic">15</span>:<span class="vhdllogic">0</span>] <a class="code" href="classocs__input.html#a615e9602b96fba12455352bb5d52c47f">potgo_final</a>;
|
231 |
|
|
<a name="l00195"></a>00195 <span class="vhdlkeyword">assign</span> <a class="code" href="classocs__input.html#a615e9602b96fba12455352bb5d52c47f">potgo_final</a> = { <span class="vhdllogic">1'b0</span>, <a class="code" href="classocs__input.html#a07f63851f6195cf877d80837996eae8a">potgo</a>[<span class="vhdllogic">14</span>], <span class="vhdllogic">1'b0</span>, <a class="code" href="classocs__input.html#a07f63851f6195cf877d80837996eae8a">potgo</a>[<span class="vhdllogic">12</span>], <span class="vhdllogic">1'b0</span>, <a class="code" href="classocs__input.html#a7e32f39227c244a369b6a4d758fe5bea">right_button_n</a>, <span class="vhdllogic">1'b0</span>, <a class="code" href="classocs__input.html#ac2df99f917f50e1213002937aba64059">middle_button_n</a>, <span class="vhdllogic">7'b0</span>, <span class="vhdllogic">1'b0</span> };
|
232 |
|
|
<a name="l00196"></a>00196
|
233 |
|
|
<a name="l00197"></a><a class="code" href="classocs__input.html#af2631e25f91cae19f22e01fd94526097">00197</a> <span class="vhdlkeyword">wire</span> [<span class="vhdllogic">8</span>:<span class="vhdllogic">0</span>] <a class="code" href="classocs__input.html#af2631e25f91cae19f22e01fd94526097">joy0dat_y</a>;
|
234 |
|
|
<a name="l00198"></a>00198 <span class="vhdlkeyword">assign</span> <a class="code" href="classocs__input.html#af2631e25f91cae19f22e01fd94526097">joy0dat_y</a> = { <a class="code" href="classocs__input.html#aa73ed28d5c045ca4237b59bb5d81e1ba">joy0dat</a>[<span class="vhdllogic">15</span>], <a class="code" href="classocs__input.html#aa73ed28d5c045ca4237b59bb5d81e1ba">joy0dat</a>[<span class="vhdllogic">15</span>:<span class="vhdllogic">8</span>] } - <a class="code" href="classocs__input.html#a33f252f3d12c92f30fedb23105116f57">mouse_y_move</a>;
|
235 |
|
|
<a name="l00199"></a>00199
|
236 |
|
|
<a name="l00200"></a><a class="code" href="classocs__input.html#a2f80bbdba33918a9aa046e3de136de61">00200</a> <span class="vhdlkeyword">wire</span> [<span class="vhdllogic">8</span>:<span class="vhdllogic">0</span>] <a class="code" href="classocs__input.html#a2f80bbdba33918a9aa046e3de136de61">joy0dat_x</a>;
|
237 |
|
|
<a name="l00201"></a>00201 <span class="vhdlkeyword">assign</span> <a class="code" href="classocs__input.html#a2f80bbdba33918a9aa046e3de136de61">joy0dat_x</a> = { <a class="code" href="classocs__input.html#aa73ed28d5c045ca4237b59bb5d81e1ba">joy0dat</a>[<span class="vhdllogic">7</span>], <a class="code" href="classocs__input.html#aa73ed28d5c045ca4237b59bb5d81e1ba">joy0dat</a>[<span class="vhdllogic">7</span>:<span class="vhdllogic">0</span>] } + <a class="code" href="classocs__input.html#ae7856c7d789112c571ab5a911182f772">mouse_x_move</a>;
|
238 |
|
|
<a name="l00202"></a>00202
|
239 |
|
|
<a name="l00203"></a><a class="code" href="classocs__input.html#a720996df667095a781e30edeb045aae3">00203</a> <span class="vhdlkeyword">always</span> @(<span class="vhdlkeyword">posedge</span> <a class="code" href="classocs__input.html#a4097ecb98b3486fbfb7e2b2354299e38">CLK_I</a> <span class="vhdlkeyword">or</span> <span class="vhdlkeyword">negedge</span> <a class="code" href="classocs__input.html#a19d0cfb3cf1132c9faae0217a1af82a9">reset_n</a>) <span class="vhdlkeyword">begin</span>
|
240 |
|
|
<a name="l00204"></a>00204 <span class="vhdlkeyword">if</span>(<a class="code" href="classocs__input.html#a19d0cfb3cf1132c9faae0217a1af82a9">reset_n</a> == <span class="vhdllogic">1'b0</span>) <span class="vhdlkeyword">begin</span>
|
241 |
|
|
<a name="l00205"></a>00205 <a class="code" href="classocs__input.html#a6000765cc199349aaad0e03fe0180b28">DAT_O</a> <= <span class="vhdllogic">32'd0</span>;
|
242 |
|
|
<a name="l00206"></a>00206 <a class="code" href="classocs__input.html#af910719de637b73f108aa9b5802fb752">ACK_O</a> <= <span class="vhdllogic">1'b0</span>;
|
243 |
|
|
<a name="l00207"></a>00207
|
244 |
|
|
<a name="l00208"></a>00208 <a class="code" href="classocs__input.html#a57aaae6a32563490c2a7e22aa86935c2">ciaa_fire_0_n</a> <= <span class="vhdllogic">1'b1</span>;
|
245 |
|
|
<a name="l00209"></a>00209
|
246 |
|
|
<a name="l00210"></a>00210 <a class="code" href="classocs__input.html#a07f63851f6195cf877d80837996eae8a">potgo</a> <= <span class="vhdllogic">16'd0</span>;
|
247 |
|
|
<a name="l00211"></a>00211 <a class="code" href="classocs__input.html#aa73ed28d5c045ca4237b59bb5d81e1ba">joy0dat</a> <= <span class="vhdllogic">16'd0</span>;
|
248 |
|
|
<a name="l00212"></a>00212 <a class="code" href="classocs__input.html#ae161410b2c480aa12521d289ea73e072">joy1dat</a> <= <span class="vhdllogic">16'd0</span>;
|
249 |
|
|
<a name="l00213"></a>00213
|
250 |
|
|
<a name="l00214"></a>00214 <a class="code" href="classocs__input.html#a7e32f39227c244a369b6a4d758fe5bea">right_button_n</a> <= <span class="vhdllogic">1'b1</span>;
|
251 |
|
|
<a name="l00215"></a>00215 <a class="code" href="classocs__input.html#ac2df99f917f50e1213002937aba64059">middle_button_n</a> <= <span class="vhdllogic">1'b1</span>;
|
252 |
|
|
<a name="l00216"></a>00216 <span class="vhdlkeyword">end</span>
|
253 |
|
|
<a name="l00217"></a>00217 <span class="vhdlkeyword">else</span> <span class="vhdlkeyword">begin</span>
|
254 |
|
|
<a name="l00218"></a>00218 <span class="vhdlkeyword">if</span>(<a class="code" href="classocs__input.html#a63add4610448cadee61e25e90f8ad230">CYC_I</a> == <span class="vhdllogic">1'b1</span> && <a class="code" href="classocs__input.html#a0195704c730e8409598612d24b132638">STB_I</a> == <span class="vhdllogic">1'b1</span> && <a class="code" href="classocs__input.html#af910719de637b73f108aa9b5802fb752">ACK_O</a> == <span class="vhdllogic">1'b0</span>) <a class="code" href="classocs__input.html#af910719de637b73f108aa9b5802fb752">ACK_O</a> <= <span class="vhdllogic">1'b1</span>;
|
255 |
|
|
<a name="l00219"></a>00219 <span class="vhdlkeyword">else</span> <a class="code" href="classocs__input.html#af910719de637b73f108aa9b5802fb752">ACK_O</a> <= <span class="vhdllogic">1'b0</span>;
|
256 |
|
|
<a name="l00220"></a>00220
|
257 |
|
|
<a name="l00221"></a>00221 <span class="vhdlkeyword">if</span>(<a class="code" href="classocs__input.html#a6c1420349b39d1da8dd088cd5d011f1a">mouse_moved</a> == <span class="vhdllogic">1'b1</span>) <span class="vhdlkeyword">begin</span>
|
258 |
|
|
<a name="l00222"></a>00222 <a class="code" href="classocs__input.html#aa73ed28d5c045ca4237b59bb5d81e1ba">joy0dat</a>[<span class="vhdllogic">15</span>:<span class="vhdllogic">8</span>] <= <a class="code" href="classocs__input.html#af2631e25f91cae19f22e01fd94526097">joy0dat_y</a>[<span class="vhdllogic">7</span>:<span class="vhdllogic">0</span>];
|
259 |
|
|
<a name="l00223"></a>00223 <a class="code" href="classocs__input.html#aa73ed28d5c045ca4237b59bb5d81e1ba">joy0dat</a>[<span class="vhdllogic">7</span>:<span class="vhdllogic">0</span>] <= <a class="code" href="classocs__input.html#a2f80bbdba33918a9aa046e3de136de61">joy0dat_x</a>[<span class="vhdllogic">7</span>:<span class="vhdllogic">0</span>];
|
260 |
|
|
<a name="l00224"></a>00224
|
261 |
|
|
<a name="l00225"></a>00225 <a class="code" href="classocs__input.html#a57aaae6a32563490c2a7e22aa86935c2">ciaa_fire_0_n</a> <= ~<a class="code" href="classocs__input.html#ad1a969d2559b895471a9622ebbe72bac">mouse_left_button</a>;
|
262 |
|
|
<a name="l00226"></a>00226 <a class="code" href="classocs__input.html#a7e32f39227c244a369b6a4d758fe5bea">right_button_n</a> <= ~<a class="code" href="classocs__input.html#ab940629f6aca8ebb676f9109161ac567">mouse_right_button</a>;
|
263 |
|
|
<a name="l00227"></a>00227 <a class="code" href="classocs__input.html#ac2df99f917f50e1213002937aba64059">middle_button_n</a> <= ~<a class="code" href="classocs__input.html#aadba9a1aceecda48b561adfd42983f4c">mouse_middle_button</a>;
|
264 |
|
|
<a name="l00228"></a>00228 <span class="vhdlkeyword">end</span>
|
265 |
|
|
<a name="l00229"></a>00229
|
266 |
|
|
<a name="l00230"></a>00230 <span class="vhdlkeyword">if</span>(<a class="code" href="classocs__input.html#a63add4610448cadee61e25e90f8ad230">CYC_I</a> == <span class="vhdllogic">1'b1</span> && <a class="code" href="classocs__input.html#a0195704c730e8409598612d24b132638">STB_I</a> == <span class="vhdllogic">1'b1</span> && <a class="code" href="classocs__input.html#a0f5def2e35084feb5c4c865cb035a69b">WE_I</a> == <span class="vhdllogic">1'b0</span>) <span class="vhdlkeyword">begin</span>
|
267 |
|
|
<a name="l00231"></a>00231 <span class="vhdlkeyword">if</span>({ <a class="code" href="classocs__input.html#adadf762e792187ce934c130d857406dd">ADR_I</a>, <span class="vhdllogic">2'b0</span> } == <span class="vhdllogic">9'h008</span>) <a class="code" href="classocs__input.html#a6000765cc199349aaad0e03fe0180b28">DAT_O</a>[<span class="vhdllogic">31</span>:<span class="vhdllogic">0</span>] <= { <span class="vhdllogic">16'd0</span> <span class="keyword">/*DSKDATR**/</span>, <a class="code" href="classocs__input.html#aa73ed28d5c045ca4237b59bb5d81e1ba">joy0dat</a> };
|
268 |
|
|
<a name="l00232"></a>00232 <span class="vhdlkeyword">if</span>({ <a class="code" href="classocs__input.html#adadf762e792187ce934c130d857406dd">ADR_I</a>, <span class="vhdllogic">2'b0</span> } == <span class="vhdllogic">9'h00C</span>) <a class="code" href="classocs__input.html#a6000765cc199349aaad0e03fe0180b28">DAT_O</a>[<span class="vhdllogic">31</span>:<span class="vhdllogic">0</span>] <= { <a class="code" href="classocs__input.html#a000c86f2ec73eb492223357b22bea156">joy1dat_final</a>, <a class="code" href="classocs__input.html#a9766cf787373f3fdefea5eae308f9822">na_clx_dat</a> };
|
269 |
|
|
<a name="l00233"></a>00233 <span class="vhdlkeyword">if</span>({ <a class="code" href="classocs__input.html#adadf762e792187ce934c130d857406dd">ADR_I</a>, <span class="vhdllogic">2'b0</span> } == <span class="vhdllogic">9'h014</span>) <a class="code" href="classocs__input.html#a6000765cc199349aaad0e03fe0180b28">DAT_O</a>[<span class="vhdllogic">31</span>:<span class="vhdllogic">0</span>] <= { <span class="vhdllogic">16'd0</span> <span class="keyword">/*POT1DAT**/</span>, <a class="code" href="classocs__input.html#a615e9602b96fba12455352bb5d52c47f">potgo_final</a> };
|
270 |
|
|
<a name="l00234"></a>00234 <span class="vhdlkeyword">end</span>
|
271 |
|
|
<a name="l00235"></a>00235 <span class="vhdlkeyword">else</span> <span class="vhdlkeyword">if</span>(<a class="code" href="classocs__input.html#a63add4610448cadee61e25e90f8ad230">CYC_I</a> == <span class="vhdllogic">1'b1</span> && <a class="code" href="classocs__input.html#a0195704c730e8409598612d24b132638">STB_I</a> == <span class="vhdllogic">1'b1</span> && <a class="code" href="classocs__input.html#a0f5def2e35084feb5c4c865cb035a69b">WE_I</a> == <span class="vhdllogic">1'b1</span>) <span class="vhdlkeyword">begin</span>
|
272 |
|
|
<a name="l00236"></a>00236 <span class="vhdlkeyword">if</span>({ <a class="code" href="classocs__input.html#adadf762e792187ce934c130d857406dd">ADR_I</a>, <span class="vhdllogic">2'b0</span> } == <span class="vhdllogic">9'h034</span> && <a class="code" href="classocs__input.html#a4a73b8f2dadbf0d6fd507e8cac3e60be">SEL_I</a>[<span class="vhdllogic">3</span>] == <span class="vhdllogic">1'b1</span>) <a class="code" href="classocs__input.html#a07f63851f6195cf877d80837996eae8a">potgo</a>[<span class="vhdllogic">15</span>:<span class="vhdllogic">8</span>] <= <a class="code" href="classocs__input.html#a5c942679add23334af2d790a3bd5c40b">DAT_I</a>[<span class="vhdllogic">31</span>:<span class="vhdllogic">24</span>];
|
273 |
|
|
<a name="l00237"></a>00237 <span class="vhdlkeyword">if</span>({ <a class="code" href="classocs__input.html#adadf762e792187ce934c130d857406dd">ADR_I</a>, <span class="vhdllogic">2'b0</span> } == <span class="vhdllogic">9'h034</span> && <a class="code" href="classocs__input.html#a4a73b8f2dadbf0d6fd507e8cac3e60be">SEL_I</a>[<span class="vhdllogic">2</span>] == <span class="vhdllogic">1'b1</span>) <a class="code" href="classocs__input.html#a07f63851f6195cf877d80837996eae8a">potgo</a>[<span class="vhdllogic">7</span>:<span class="vhdllogic">0</span>] <= <a class="code" href="classocs__input.html#a5c942679add23334af2d790a3bd5c40b">DAT_I</a>[<span class="vhdllogic">23</span>:<span class="vhdllogic">16</span>];
|
274 |
|
|
<a name="l00238"></a>00238 <span class="vhdlkeyword">if</span>({ <a class="code" href="classocs__input.html#adadf762e792187ce934c130d857406dd">ADR_I</a>, <span class="vhdllogic">2'b0</span> } == <span class="vhdllogic">9'h034</span> && <a class="code" href="classocs__input.html#a4a73b8f2dadbf0d6fd507e8cac3e60be">SEL_I</a>[<span class="vhdllogic">1</span>] == <span class="vhdllogic">1'b1</span>) { <a class="code" href="classocs__input.html#aa73ed28d5c045ca4237b59bb5d81e1ba">joy0dat</a>[<span class="vhdllogic">15</span>:<span class="vhdllogic">8</span>], <a class="code" href="classocs__input.html#ae161410b2c480aa12521d289ea73e072">joy1dat</a>[<span class="vhdllogic">15</span>:<span class="vhdllogic">8</span>] } <= { <a class="code" href="classocs__input.html#a5c942679add23334af2d790a3bd5c40b">DAT_I</a>[<span class="vhdllogic">15</span>:<span class="vhdllogic">8</span>], <a class="code" href="classocs__input.html#a5c942679add23334af2d790a3bd5c40b">DAT_I</a>[<span class="vhdllogic">15</span>:<span class="vhdllogic">8</span>] };
|
275 |
|
|
<a name="l00239"></a>00239 <span class="vhdlkeyword">if</span>({ <a class="code" href="classocs__input.html#adadf762e792187ce934c130d857406dd">ADR_I</a>, <span class="vhdllogic">2'b0</span> } == <span class="vhdllogic">9'h034</span> && <a class="code" href="classocs__input.html#a4a73b8f2dadbf0d6fd507e8cac3e60be">SEL_I</a>[<span class="vhdllogic">0</span>] == <span class="vhdllogic">1'b1</span>) { <a class="code" href="classocs__input.html#aa73ed28d5c045ca4237b59bb5d81e1ba">joy0dat</a>[<span class="vhdllogic">7</span>:<span class="vhdllogic">0</span>], <a class="code" href="classocs__input.html#ae161410b2c480aa12521d289ea73e072">joy1dat</a>[<span class="vhdllogic">7</span>:<span class="vhdllogic">0</span>] } <= { <a class="code" href="classocs__input.html#a5c942679add23334af2d790a3bd5c40b">DAT_I</a>[<span class="vhdllogic">7</span>:<span class="vhdllogic">0</span>], <a class="code" href="classocs__input.html#a5c942679add23334af2d790a3bd5c40b">DAT_I</a>[<span class="vhdllogic">7</span>:<span class="vhdllogic">0</span>] };
|
276 |
|
|
<a name="l00240"></a>00240 <span class="vhdlkeyword">end</span>
|
277 |
|
|
<a name="l00241"></a>00241 <span class="vhdlkeyword">end</span>
|
278 |
|
|
<a name="l00242"></a>00242 <span class="vhdlkeyword">end</span>
|
279 |
|
|
<a name="l00243"></a>00243
|
280 |
|
|
<a name="l00244"></a>00244 <span class="vhdlkeyword">endmodule</span>
|
281 |
|
|
</pre></div></div>
|
282 |
|
|
</div>
|
283 |
|
|
<hr class="footer"/><address class="footer"><small>Generated on Mon Dec 20 2010 21:20:19 for aoOCS by 
|
284 |
|
|
<a href="http://www.doxygen.org/index.html">
|
285 |
|
|
<img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.7.2 </small></address>
|
286 |
|
|
</body>
|
287 |
|
|
</html>
|