1 \hypertarget{canOpenDriver_8c}{ |
|
2 \section{/home/epimerde/documents/tc11/Can\-Festival-3/drivers/hcs12/can\-Open\-Driver.c File Reference} |
|
3 \label{canOpenDriver_8c}\index{/home/epimerde/documents/tc11/CanFestival-3/drivers/hcs12/canOpenDriver.c@{/home/epimerde/documents/tc11/CanFestival-3/drivers/hcs12/canOpenDriver.c}} |
|
4 } |
|
5 {\tt \#include $<$stddef.h$>$}\par |
|
6 {\tt \#include \char`\"{}../include/hcs12/asm-m68hc12/portsaccess.h\char`\"{}}\par |
|
7 {\tt \#include \char`\"{}../include/hcs12/asm-m68hc12/ports\_\-def.h\char`\"{}}\par |
|
8 {\tt \#include \char`\"{}../include/hcs12/asm-m68hc12/ports.h\char`\"{}}\par |
|
9 {\tt \#include \char`\"{}../include/data.h\char`\"{}}\par |
|
10 {\tt \#include \char`\"{}../include/hcs12/applicfg.h\char`\"{}}\par |
|
11 {\tt \#include \char`\"{}../include/hcs12/candriver.h\char`\"{}}\par |
|
12 {\tt \#include \char`\"{}../include/hcs12/interrupt.h\char`\"{}}\par |
|
13 {\tt \#include \char`\"{}../include/hcs12/can\-Open\-Driver.h\char`\"{}}\par |
|
14 {\tt \#include \char`\"{}../include/can.h\char`\"{}}\par |
|
15 {\tt \#include \char`\"{}../include/objdictdef.h\char`\"{}}\par |
|
16 {\tt \#include \char`\"{}../include/timer.h\char`\"{}}\par |
|
17 \subsection*{Defines} |
|
18 \begin{CompactItemize} |
|
19 \item |
|
20 \#define \hyperlink{canOpenDriver_8c_4f52c00ab0d519e2965ebaa533975904}{DEBUG\_\-WAR\_\-CONSOLE\_\-ON} |
|
21 \item |
|
22 \#define \hyperlink{canOpenDriver_8c_bb416887a32f7e4333e095356774f07f}{DEBUG\_\-ERR\_\-CONSOLE\_\-ON} |
|
23 \item |
|
24 \#define \hyperlink{canOpenDriver_8c_ffe776513b24d84b39af8ab0930fef7f}{max}(a, b)~a$>$b?a:b |
|
25 \end{CompactItemize} |
|
26 \subsection*{Functions} |
|
27 \begin{CompactItemize} |
|
28 \item |
|
29 UNS8 \hyperlink{canOpenDriver_8c_0bf58f014d47581c9ffd1b2db9a858d7}{f\_\-can\_\-receive} (UNS8 notused, \hyperlink{structMessage}{Message} $\ast$m) |
|
30 \item |
|
31 UNS8 \hyperlink{canOpenDriver_8c_b57b4b3c000e9f61135175495e874977}{can\-Send} (UNS8 notused, \hyperlink{structMessage}{Message} $\ast$m) |
|
32 \item |
|
33 void \hyperlink{canOpenDriver_8c_445500277ba0e363873b34cffc015745}{\_\-\_\-attribute\_\-\_\-} ((interrupt)) |
|
34 \item |
|
35 TIMEVAL \hyperlink{canOpenDriver_8c_24dbe63e88d184388542037d16a8208d}{get\-Elapsed\-Time} () |
|
36 \item |
|
37 void \hyperlink{canOpenDriver_8c_339b24f4eee897d3c45d88de9a4901e8}{reset\-Timer} (void) |
|
38 \item |
|
39 void \hyperlink{canOpenDriver_8c_02922529b60419a94afe8f369dda070b}{init\-Timer} (void) |
|
40 \item |
|
41 void \hyperlink{canOpenDriver_8c_f86db4b817c1a59a819cbdd51779bfaa}{init\-SCI\_\-0} (void) |
|
42 \begin{CompactList}\small\item\em Initialisation of the serial port 0. \item\end{CompactList}\item |
|
43 void \hyperlink{canOpenDriver_8c_b56fa1754706a57059103710178bdb68}{init\-SCI\_\-1} (void) |
|
44 \begin{CompactList}\small\item\em Initialisation of the serial port 1. \item\end{CompactList}\item |
|
45 char $\ast$ \hyperlink{canOpenDriver_8c_2a9aef0efc98c5b41ef97ef91ad403e5}{hex\_\-convert} (char $\ast$buf, unsigned long value, char last\-Car) |
|
46 \item |
|
47 void \hyperlink{canOpenDriver_8c_6e3075ae435e83aefc018e5218c197d0}{print\-SCI\_\-str} (char sci, const char $\ast$str) |
|
48 \item |
|
49 void \hyperlink{canOpenDriver_8c_80f5dbbc046cba0e5e9cf2bcc4c1e78e}{print\-SCI\_\-nbr} (char sci, unsigned long nbr, char last\-Car) |
|
50 \item |
|
51 void \hyperlink{canOpenDriver_8c_51e71c727eb7a49e2fde962a3d190a6b}{init\-PLL} (void) |
|
52 \item |
|
53 void \hyperlink{canOpenDriver_8c_c71399958d35a7f703416f025603ee26}{init\-HCS12} (void) |
|
54 \begin{CompactList}\small\item\em Put here all the code to init the HCS12. \item\end{CompactList}\item |
|
55 char \hyperlink{canOpenDriver_8c_acfd181d5b055d1403930442e28ac643}{can\-Add\-Id\-To\-Filter} (UNS16 adr\-CAN, UNS8 n\-Filter, UNS16 id) |
|
56 \item |
|
57 char \hyperlink{canOpenDriver_8c_751a41c9747b96ab400b5599370cea83}{can\-Change\-Filter} (UNS16 adr\-CAN, \hyperlink{structcanBusFilterInit}{can\-Bus\-Filter\-Init} fi) |
|
58 \item |
|
59 char \hyperlink{canOpenDriver_8c_5a53a89d2e348d70331e6ebe269d155a}{can\-Enable} (UNS16 adr\-CAN) |
|
60 \item |
|
61 char \hyperlink{canOpenDriver_8c_3c4f7a31d94e5e7c7322535467b806de}{can\-Init} (UNS16 adr\-CAN, \hyperlink{structcanBusInit}{can\-Bus\-Init} \hyperlink{candriver_8h_c731fd3e22e0f2c414b1e3f511c85423}{bi}) |
|
62 \item |
|
63 char \hyperlink{canOpenDriver_8c_6ec3ce6d79012dd8a08fa5aeb6a0489f}{can\-Init\-Clock} (UNS16 adr\-CAN, \hyperlink{structcanBusTime}{can\-Bus\-Time} clk) |
|
64 \item |
|
65 char \hyperlink{canOpenDriver_8c_5fb549697afb7918607aa113e01c543d}{can\-Init1Filter} (UNS16 adr\-CAN, UNS8 n\-Filter, UNS16 ar, UNS16 mr) |
|
66 \item |
|
67 char \hyperlink{canOpenDriver_8c_b4502eef7616b25c74b1ac5a2245b085}{can\-Init\-Filter} (UNS16 adr\-CAN, \hyperlink{structcanBusFilterInit}{can\-Bus\-Filter\-Init} fi) |
|
68 \item |
|
69 char \hyperlink{canOpenDriver_8c_0b98e4800c82d99981833aa4207f1eb9}{can\-Init\-Mode} (UNS16 adr\-CAN) |
|
70 \item |
|
71 char \hyperlink{canOpenDriver_8c_00ffb46abacfdfa56ebc70e15164113e}{can\-Init\-Mode\-Q} (UNS16 adr\-CAN) |
|
72 \item |
|
73 char \hyperlink{canOpenDriver_8c_2f2d1ed55cfd9d7f85883f8d70d318ba}{can\-Msg\-Transmit} (UNS16 adr\-CAN, \hyperlink{structMessage}{Message} msg) |
|
74 \item |
|
75 char \hyperlink{canOpenDriver_8c_5ad8616a3276f7f40149b551f09aa6a1}{can\-Set\-Interrupt} (UNS16 adr\-CAN) |
|
76 \item |
|
77 char \hyperlink{canOpenDriver_8c_c7773223579ec7e0fab5238df214da89}{can\-Sleep\-Mode} (UNS16 adr\-CAN) |
|
78 \item |
|
79 char \hyperlink{canOpenDriver_8c_a89f28005eea54f5b216eb72a18d45f3}{can\-Sleep\-Mode\-Q} (UNS16 adr\-CAN) |
|
80 \item |
|
81 char \hyperlink{canOpenDriver_8c_1ae1ad5d66ac87085baf5b9d0a4e62ca}{can\-Sleep\-Wup\-Mode} (UNS16 adr\-CAN) |
|
82 \item |
|
83 char \hyperlink{canOpenDriver_8c_6beefe951b3c9de786c585257488fa82}{can\-Test\-Init\-Mode} (UNS16 adr\-CAN) |
|
84 \item |
|
85 char \hyperlink{canOpenDriver_8c_fa79f2ac95a8143c2fb087260df39820}{can\-Test\-Sleep\-Mode} (UNS16 adr\-CAN) |
|
86 \end{CompactItemize} |
|
87 |
|
88 |
|
89 \subsection{Define Documentation} |
|
90 \hypertarget{canOpenDriver_8c_bb416887a32f7e4333e095356774f07f}{ |
|
91 \index{canOpenDriver.c@{can\-Open\-Driver.c}!DEBUG_ERR_CONSOLE_ON@{DEBUG\_\-ERR\_\-CONSOLE\_\-ON}} |
|
92 \index{DEBUG_ERR_CONSOLE_ON@{DEBUG\_\-ERR\_\-CONSOLE\_\-ON}!canOpenDriver.c@{can\-Open\-Driver.c}} |
|
93 \subsubsection[DEBUG\_\-ERR\_\-CONSOLE\_\-ON]{\setlength{\rightskip}{0pt plus 5cm}\#define DEBUG\_\-ERR\_\-CONSOLE\_\-ON}} |
|
94 \label{canOpenDriver_8c_bb416887a32f7e4333e095356774f07f} |
|
95 |
|
96 |
|
97 |
|
98 |
|
99 Definition at line 24 of file can\-Open\-Driver.c.\hypertarget{canOpenDriver_8c_4f52c00ab0d519e2965ebaa533975904}{ |
|
100 \index{canOpenDriver.c@{can\-Open\-Driver.c}!DEBUG_WAR_CONSOLE_ON@{DEBUG\_\-WAR\_\-CONSOLE\_\-ON}} |
|
101 \index{DEBUG_WAR_CONSOLE_ON@{DEBUG\_\-WAR\_\-CONSOLE\_\-ON}!canOpenDriver.c@{can\-Open\-Driver.c}} |
|
102 \subsubsection[DEBUG\_\-WAR\_\-CONSOLE\_\-ON]{\setlength{\rightskip}{0pt plus 5cm}\#define DEBUG\_\-WAR\_\-CONSOLE\_\-ON}} |
|
103 \label{canOpenDriver_8c_4f52c00ab0d519e2965ebaa533975904} |
|
104 |
|
105 |
|
106 |
|
107 |
|
108 Definition at line 23 of file can\-Open\-Driver.c.\hypertarget{canOpenDriver_8c_ffe776513b24d84b39af8ab0930fef7f}{ |
|
109 \index{canOpenDriver.c@{can\-Open\-Driver.c}!max@{max}} |
|
110 \index{max@{max}!canOpenDriver.c@{can\-Open\-Driver.c}} |
|
111 \subsubsection[max]{\setlength{\rightskip}{0pt plus 5cm}\#define max(a, b)~a$>$b?a:b}} |
|
112 \label{canOpenDriver_8c_ffe776513b24d84b39af8ab0930fef7f} |
|
113 |
|
114 |
|
115 |
|
116 |
|
117 \subsection{Function Documentation} |
|
118 \hypertarget{canOpenDriver_8c_445500277ba0e363873b34cffc015745}{ |
|
119 \index{canOpenDriver.c@{can\-Open\-Driver.c}!__attribute__@{\_\-\_\-attribute\_\-\_\-}} |
|
120 \index{__attribute__@{\_\-\_\-attribute\_\-\_\-}!canOpenDriver.c@{can\-Open\-Driver.c}} |
|
121 \subsubsection[\_\-\_\-attribute\_\-\_\-]{\setlength{\rightskip}{0pt plus 5cm}void \_\-\_\-attribute\_\-\_\- ((interrupt))}} |
|
122 \label{canOpenDriver_8c_445500277ba0e363873b34cffc015745} |
|
123 |
|
124 |
|
125 \hyperlink{structMessage}{Message} transmitted on MSCAN 0 |
|
126 |
|
127 Definition at line 54 of file can\-Open\-Driver.c. |
|
128 |
|
129 References IO\_\-PORTS\_\-16, and TC4H.\hypertarget{canOpenDriver_8c_acfd181d5b055d1403930442e28ac643}{ |
|
130 \index{canOpenDriver.c@{can\-Open\-Driver.c}!canAddIdToFilter@{canAddIdToFilter}} |
|
131 \index{canAddIdToFilter@{canAddIdToFilter}!canOpenDriver.c@{can\-Open\-Driver.c}} |
|
132 \subsubsection[canAddIdToFilter]{\setlength{\rightskip}{0pt plus 5cm}char can\-Add\-Id\-To\-Filter (UNS16 {\em adr\-CAN}, UNS8 {\em n\-Filter}, UNS16 {\em id})}} |
|
133 \label{canOpenDriver_8c_acfd181d5b055d1403930442e28ac643} |
|
134 |
|
135 |
|
136 |
|
137 |
|
138 Definition at line 210 of file can\-Open\-Driver.c. |
|
139 |
|
140 References CANIDAR0, CANIDAR2, CANIDAR4, CANIDAR6, can\-Test\-Init\-Mode(), IO\_\-PORTS\_\-16, IO\_\-PORTS\_\-8, MSG\_\-WAR, and UNS8.\hypertarget{canOpenDriver_8c_751a41c9747b96ab400b5599370cea83}{ |
|
141 \index{canOpenDriver.c@{can\-Open\-Driver.c}!canChangeFilter@{canChangeFilter}} |
|
142 \index{canChangeFilter@{canChangeFilter}!canOpenDriver.c@{can\-Open\-Driver.c}} |
|
143 \subsubsection[canChangeFilter]{\setlength{\rightskip}{0pt plus 5cm}char can\-Change\-Filter (UNS16 {\em adr\-CAN}, \hyperlink{structcanBusFilterInit}{can\-Bus\-Filter\-Init} {\em fi})}} |
|
144 \label{canOpenDriver_8c_751a41c9747b96ab400b5599370cea83} |
|
145 |
|
146 |
|
147 |
|
148 |
|
149 Definition at line 250 of file can\-Open\-Driver.c. |
|
150 |
|
151 References can\-Init\-Filter(), can\-Init\-Mode(), can\-Init\-Mode\-Q(), can\-Set\-Interrupt(), can\-Sleep\-Mode(), can\-Sleep\-Mode\-Q(), and can\-Test\-Init\-Mode().\hypertarget{canOpenDriver_8c_5a53a89d2e348d70331e6ebe269d155a}{ |
|
152 \index{canOpenDriver.c@{can\-Open\-Driver.c}!canEnable@{canEnable}} |
|
153 \index{canEnable@{canEnable}!canOpenDriver.c@{can\-Open\-Driver.c}} |
|
154 \subsubsection[canEnable]{\setlength{\rightskip}{0pt plus 5cm}char can\-Enable (UNS16 {\em adr\-CAN})}} |
|
155 \label{canOpenDriver_8c_5a53a89d2e348d70331e6ebe269d155a} |
|
156 |
|
157 |
|
158 |
|
159 |
|
160 Definition at line 266 of file can\-Open\-Driver.c. |
|
161 |
|
162 References CANCTL1, and IO\_\-PORTS\_\-8.\hypertarget{canOpenDriver_8c_3c4f7a31d94e5e7c7322535467b806de}{ |
|
163 \index{canOpenDriver.c@{can\-Open\-Driver.c}!canInit@{canInit}} |
|
164 \index{canInit@{canInit}!canOpenDriver.c@{can\-Open\-Driver.c}} |
|
165 \subsubsection[canInit]{\setlength{\rightskip}{0pt plus 5cm}char can\-Init (UNS16 {\em adr\-CAN}, \hyperlink{structcanBusInit}{can\-Bus\-Init} {\em bi})}} |
|
166 \label{canOpenDriver_8c_3c4f7a31d94e5e7c7322535467b806de} |
|
167 |
|
168 |
|
169 |
|
170 |
|
171 Definition at line 277 of file can\-Open\-Driver.c. |
|
172 |
|
173 References CANCTL0, CANCTL1, can\-Bus\-Init::cane, can\-Enable(), can\-Init\-Clock(), can\-Init\-Filter(), can\-Init\-Mode(), can\-Init\-Mode\-Q(), can\-Set\-Interrupt(), can\-Sleep\-Mode(), can\-Sleep\-Mode\-Q(), can\-Test\-Init\-Mode(), can\-Bus\-Init::clk, can\-Bus\-Init::cswai, can\-Bus\-Init::fi, IO\_\-PORTS\_\-8, can\-Bus\-Init::listen, can\-Bus\-Init::loopb, can\-Bus\-Init::time, and can\-Bus\-Init::wupm.\hypertarget{canOpenDriver_8c_5fb549697afb7918607aa113e01c543d}{ |
|
174 \index{canOpenDriver.c@{can\-Open\-Driver.c}!canInit1Filter@{canInit1Filter}} |
|
175 \index{canInit1Filter@{canInit1Filter}!canOpenDriver.c@{can\-Open\-Driver.c}} |
|
176 \subsubsection[canInit1Filter]{\setlength{\rightskip}{0pt plus 5cm}char can\-Init1Filter (UNS16 {\em adr\-CAN}, UNS8 {\em n\-Filter}, UNS16 {\em ar}, UNS16 {\em mr})}} |
|
177 \label{canOpenDriver_8c_5fb549697afb7918607aa113e01c543d} |
|
178 |
|
179 |
|
180 |
|
181 |
|
182 Definition at line 335 of file can\-Open\-Driver.c. |
|
183 |
|
184 References CANIDAR0, CANIDAR2, CANIDAR4, CANIDAR6, can\-Test\-Init\-Mode(), IO\_\-PORTS\_\-8, MSG\_\-WAR, and UNS8.\hypertarget{canOpenDriver_8c_6ec3ce6d79012dd8a08fa5aeb6a0489f}{ |
|
185 \index{canOpenDriver.c@{can\-Open\-Driver.c}!canInitClock@{canInitClock}} |
|
186 \index{canInitClock@{canInitClock}!canOpenDriver.c@{can\-Open\-Driver.c}} |
|
187 \subsubsection[canInitClock]{\setlength{\rightskip}{0pt plus 5cm}char can\-Init\-Clock (UNS16 {\em adr\-CAN}, \hyperlink{structcanBusTime}{can\-Bus\-Time} {\em clk})}} |
|
188 \label{canOpenDriver_8c_6ec3ce6d79012dd8a08fa5aeb6a0489f} |
|
189 |
|
190 |
|
191 |
|
192 |
|
193 Definition at line 313 of file can\-Open\-Driver.c. |
|
194 |
|
195 References can\-Bus\-Time::brp, CANBTR0, CANBTR1, CANCTL1, can\-Test\-Init\-Mode(), can\-Bus\-Time::clksrc, IO\_\-PORTS\_\-8, MSG\_\-WAR, can\-Bus\-Time::samp, can\-Bus\-Time::sjw, can\-Bus\-Time::tseg1, and can\-Bus\-Time::tseg2.\hypertarget{canOpenDriver_8c_b4502eef7616b25c74b1ac5a2245b085}{ |
|
196 \index{canOpenDriver.c@{can\-Open\-Driver.c}!canInitFilter@{canInitFilter}} |
|
197 \index{canInitFilter@{canInitFilter}!canOpenDriver.c@{can\-Open\-Driver.c}} |
|
198 \subsubsection[canInitFilter]{\setlength{\rightskip}{0pt plus 5cm}char can\-Init\-Filter (UNS16 {\em adr\-CAN}, \hyperlink{structcanBusFilterInit}{can\-Bus\-Filter\-Init} {\em fi})}} |
|
199 \label{canOpenDriver_8c_b4502eef7616b25c74b1ac5a2245b085} |
|
200 |
|
201 |
|
202 |
|
203 |
|
204 Definition at line 364 of file can\-Open\-Driver.c. |
|
205 |
|
206 References CANIDAC, CANIDAR0, can\-Bus\-Filter\-Init::canidar0, CANIDAR1, can\-Bus\-Filter\-Init::canidar1, CANIDAR2, can\-Bus\-Filter\-Init::canidar2, CANIDAR3, can\-Bus\-Filter\-Init::canidar3, CANIDAR4, can\-Bus\-Filter\-Init::canidar4, CANIDAR5, can\-Bus\-Filter\-Init::canidar5, CANIDAR6, can\-Bus\-Filter\-Init::canidar6, CANIDAR7, can\-Bus\-Filter\-Init::canidar7, CANIDMR0, can\-Bus\-Filter\-Init::canidmr0, CANIDMR1, can\-Bus\-Filter\-Init::canidmr1, CANIDMR2, can\-Bus\-Filter\-Init::canidmr2, CANIDMR3, can\-Bus\-Filter\-Init::canidmr3, CANIDMR4, can\-Bus\-Filter\-Init::canidmr4, CANIDMR5, can\-Bus\-Filter\-Init::canidmr5, CANIDMR6, can\-Bus\-Filter\-Init::canidmr6, CANIDMR7, can\-Bus\-Filter\-Init::canidmr7, can\-Test\-Init\-Mode(), can\-Bus\-Filter\-Init::idam, IO\_\-PORTS\_\-8, and MSG\_\-WAR.\hypertarget{canOpenDriver_8c_0b98e4800c82d99981833aa4207f1eb9}{ |
|
207 \index{canOpenDriver.c@{can\-Open\-Driver.c}!canInitMode@{canInitMode}} |
|
208 \index{canInitMode@{canInitMode}!canOpenDriver.c@{can\-Open\-Driver.c}} |
|
209 \subsubsection[canInitMode]{\setlength{\rightskip}{0pt plus 5cm}char can\-Init\-Mode (UNS16 {\em adr\-CAN})}} |
|
210 \label{canOpenDriver_8c_0b98e4800c82d99981833aa4207f1eb9} |
|
211 |
|
212 |
|
213 |
|
214 |
|
215 Definition at line 392 of file can\-Open\-Driver.c. |
|
216 |
|
217 References CANCTL0, can\-Test\-Init\-Mode(), and IO\_\-PORTS\_\-8.\hypertarget{canOpenDriver_8c_00ffb46abacfdfa56ebc70e15164113e}{ |
|
218 \index{canOpenDriver.c@{can\-Open\-Driver.c}!canInitModeQ@{canInitModeQ}} |
|
219 \index{canInitModeQ@{canInitModeQ}!canOpenDriver.c@{can\-Open\-Driver.c}} |
|
220 \subsubsection[canInitModeQ]{\setlength{\rightskip}{0pt plus 5cm}char can\-Init\-Mode\-Q (UNS16 {\em adr\-CAN})}} |
|
221 \label{canOpenDriver_8c_00ffb46abacfdfa56ebc70e15164113e} |
|
222 |
|
223 |
|
224 |
|
225 |
|
226 Definition at line 401 of file can\-Open\-Driver.c. |
|
227 |
|
228 References CANCTL0, can\-Test\-Init\-Mode(), and IO\_\-PORTS\_\-8.\hypertarget{canOpenDriver_8c_2f2d1ed55cfd9d7f85883f8d70d318ba}{ |
|
229 \index{canOpenDriver.c@{can\-Open\-Driver.c}!canMsgTransmit@{canMsgTransmit}} |
|
230 \index{canMsgTransmit@{canMsgTransmit}!canOpenDriver.c@{can\-Open\-Driver.c}} |
|
231 \subsubsection[canMsgTransmit]{\setlength{\rightskip}{0pt plus 5cm}char can\-Msg\-Transmit (UNS16 {\em adr\-CAN}, \hyperlink{structMessage}{Message} {\em msg})}} |
|
232 \label{canOpenDriver_8c_2f2d1ed55cfd9d7f85883f8d70d318ba} |
|
233 |
|
234 |
|
235 |
|
236 |
|
237 Definition at line 410 of file can\-Open\-Driver.c. |
|
238 |
|
239 References CANTBSEL, CANTFLG, CANTRSDTA, CANTRSID, CANTRSLEN, CANTRSPRI, Message::cob\_\-id, Message::data, IO\_\-PORTS\_\-8, Message::len, MSG\_\-WAR, Message::rtr, UNS8, and SHORT\_\-CAN::w.\hypertarget{canOpenDriver_8c_b57b4b3c000e9f61135175495e874977}{ |
|
240 \index{canOpenDriver.c@{can\-Open\-Driver.c}!canSend@{canSend}} |
|
241 \index{canSend@{canSend}!canOpenDriver.c@{can\-Open\-Driver.c}} |
|
242 \subsubsection[canSend]{\setlength{\rightskip}{0pt plus 5cm}UNS8 can\-Send (UNS8 {\em notused}, \hyperlink{structMessage}{Message} $\ast$ {\em m})}} |
|
243 \label{canOpenDriver_8c_b57b4b3c000e9f61135175495e874977} |
|
244 |
|
245 |
|
246 |
|
247 |
|
248 Definition at line 505 of file can\-Open\-Driver.c. |
|
249 |
|
250 References can\-Msg\-Transmit(), and CANOPEN\_\-LINE\_\-NUMBER\_\-USED.\hypertarget{canOpenDriver_8c_5ad8616a3276f7f40149b551f09aa6a1}{ |
|
251 \index{canOpenDriver.c@{can\-Open\-Driver.c}!canSetInterrupt@{canSetInterrupt}} |
|
252 \index{canSetInterrupt@{canSetInterrupt}!canOpenDriver.c@{can\-Open\-Driver.c}} |
|
253 \subsubsection[canSetInterrupt]{\setlength{\rightskip}{0pt plus 5cm}char can\-Set\-Interrupt (UNS16 {\em adr\-CAN})}} |
|
254 \label{canOpenDriver_8c_5ad8616a3276f7f40149b551f09aa6a1} |
|
255 |
|
256 |
|
257 |
|
258 |
|
259 Definition at line 445 of file can\-Open\-Driver.c. |
|
260 |
|
261 References CANRIER, CANTIER, and IO\_\-PORTS\_\-8.\hypertarget{canOpenDriver_8c_c7773223579ec7e0fab5238df214da89}{ |
|
262 \index{canOpenDriver.c@{can\-Open\-Driver.c}!canSleepMode@{canSleepMode}} |
|
263 \index{canSleepMode@{canSleepMode}!canOpenDriver.c@{can\-Open\-Driver.c}} |
|
264 \subsubsection[canSleepMode]{\setlength{\rightskip}{0pt plus 5cm}char can\-Sleep\-Mode (UNS16 {\em adr\-CAN})}} |
|
265 \label{canOpenDriver_8c_c7773223579ec7e0fab5238df214da89} |
|
266 |
|
267 |
|
268 |
|
269 |
|
270 Definition at line 452 of file can\-Open\-Driver.c. |
|
271 |
|
272 References CANCTL0, can\-Test\-Sleep\-Mode(), and IO\_\-PORTS\_\-8.\hypertarget{canOpenDriver_8c_a89f28005eea54f5b216eb72a18d45f3}{ |
|
273 \index{canOpenDriver.c@{can\-Open\-Driver.c}!canSleepModeQ@{canSleepModeQ}} |
|
274 \index{canSleepModeQ@{canSleepModeQ}!canOpenDriver.c@{can\-Open\-Driver.c}} |
|
275 \subsubsection[canSleepModeQ]{\setlength{\rightskip}{0pt plus 5cm}char can\-Sleep\-Mode\-Q (UNS16 {\em adr\-CAN})}} |
|
276 \label{canOpenDriver_8c_a89f28005eea54f5b216eb72a18d45f3} |
|
277 |
|
278 |
|
279 |
|
280 |
|
281 Definition at line 466 of file can\-Open\-Driver.c. |
|
282 |
|
283 References CANCTL0, can\-Test\-Init\-Mode(), can\-Test\-Sleep\-Mode(), IO\_\-PORTS\_\-8, and MSG\_\-WAR.\hypertarget{canOpenDriver_8c_1ae1ad5d66ac87085baf5b9d0a4e62ca}{ |
|
284 \index{canOpenDriver.c@{can\-Open\-Driver.c}!canSleepWupMode@{canSleepWupMode}} |
|
285 \index{canSleepWupMode@{canSleepWupMode}!canOpenDriver.c@{can\-Open\-Driver.c}} |
|
286 \subsubsection[canSleepWupMode]{\setlength{\rightskip}{0pt plus 5cm}char can\-Sleep\-Wup\-Mode (UNS16 {\em adr\-CAN})}} |
|
287 \label{canOpenDriver_8c_1ae1ad5d66ac87085baf5b9d0a4e62ca} |
|
288 |
|
289 |
|
290 |
|
291 |
|
292 Definition at line 480 of file can\-Open\-Driver.c. |
|
293 |
|
294 References CANCTL0, can\-Test\-Init\-Mode(), can\-Test\-Sleep\-Mode(), IO\_\-PORTS\_\-8, and MSG\_\-WAR.\hypertarget{canOpenDriver_8c_6beefe951b3c9de786c585257488fa82}{ |
|
295 \index{canOpenDriver.c@{can\-Open\-Driver.c}!canTestInitMode@{canTestInitMode}} |
|
296 \index{canTestInitMode@{canTestInitMode}!canOpenDriver.c@{can\-Open\-Driver.c}} |
|
297 \subsubsection[canTestInitMode]{\setlength{\rightskip}{0pt plus 5cm}char can\-Test\-Init\-Mode (UNS16 {\em adr\-CAN})}} |
|
298 \label{canOpenDriver_8c_6beefe951b3c9de786c585257488fa82} |
|
299 |
|
300 |
|
301 |
|
302 |
|
303 Definition at line 493 of file can\-Open\-Driver.c. |
|
304 |
|
305 References CANCTL1, and IO\_\-PORTS\_\-8.\hypertarget{canOpenDriver_8c_fa79f2ac95a8143c2fb087260df39820}{ |
|
306 \index{canOpenDriver.c@{can\-Open\-Driver.c}!canTestSleepMode@{canTestSleepMode}} |
|
307 \index{canTestSleepMode@{canTestSleepMode}!canOpenDriver.c@{can\-Open\-Driver.c}} |
|
308 \subsubsection[canTestSleepMode]{\setlength{\rightskip}{0pt plus 5cm}char can\-Test\-Sleep\-Mode (UNS16 {\em adr\-CAN})}} |
|
309 \label{canOpenDriver_8c_fa79f2ac95a8143c2fb087260df39820} |
|
310 |
|
311 |
|
312 |
|
313 |
|
314 Definition at line 499 of file can\-Open\-Driver.c. |
|
315 |
|
316 References CANCTL1, and IO\_\-PORTS\_\-8.\hypertarget{canOpenDriver_8c_0bf58f014d47581c9ffd1b2db9a858d7}{ |
|
317 \index{canOpenDriver.c@{can\-Open\-Driver.c}!f_can_receive@{f\_\-can\_\-receive}} |
|
318 \index{f_can_receive@{f\_\-can\_\-receive}!canOpenDriver.c@{can\-Open\-Driver.c}} |
|
319 \subsubsection[f\_\-can\_\-receive]{\setlength{\rightskip}{0pt plus 5cm}UNS8 f\_\-can\_\-receive (UNS8 {\em notused}, \hyperlink{structMessage}{Message} $\ast$ {\em m})}} |
|
320 \label{canOpenDriver_8c_0bf58f014d47581c9ffd1b2db9a858d7} |
|
321 |
|
322 |
|
323 |
|
324 |
|
325 Definition at line 513 of file can\-Open\-Driver.c. |
|
326 |
|
327 References CAN0, CAN1, CAN2, CAN3, CAN4, CANOPEN\_\-LINE\_\-NUMBER\_\-USED, Message::cob\_\-id, Message::data, Message::len, MAX\_\-STACK\_\-MSG\_\-RCV, t\_\-pointer\-Stack::r, Message::rtr, UNS8, and SHORT\_\-CAN::w.\hypertarget{canOpenDriver_8c_24dbe63e88d184388542037d16a8208d}{ |
|
328 \index{canOpenDriver.c@{can\-Open\-Driver.c}!getElapsedTime@{getElapsedTime}} |
|
329 \index{getElapsedTime@{getElapsedTime}!canOpenDriver.c@{can\-Open\-Driver.c}} |
|
330 \subsubsection[getElapsedTime]{\setlength{\rightskip}{0pt plus 5cm}TIMEVAL get\-Elapsed\-Time (void)}} |
|
331 \label{canOpenDriver_8c_24dbe63e88d184388542037d16a8208d} |
|
332 |
|
333 |
|
334 |
|
335 |
|
336 Definition at line 66 of file can\-Open\-Driver.c.\hypertarget{canOpenDriver_8c_2a9aef0efc98c5b41ef97ef91ad403e5}{ |
|
337 \index{canOpenDriver.c@{can\-Open\-Driver.c}!hex_convert@{hex\_\-convert}} |
|
338 \index{hex_convert@{hex\_\-convert}!canOpenDriver.c@{can\-Open\-Driver.c}} |
|
339 \subsubsection[hex\_\-convert]{\setlength{\rightskip}{0pt plus 5cm}char$\ast$ hex\_\-convert (char $\ast$ {\em buf}, unsigned long {\em value}, char {\em last\-Car})}} |
|
340 \label{canOpenDriver_8c_2a9aef0efc98c5b41ef97ef91ad403e5} |
|
341 |
|
342 |
|
343 Convert an integer to a string in hexadecimal format If you do not wants to use a last\-Car, put last\-Car = '' (end of string) ex : value = 0XABCDEF and last\-Car = '\par |
|
344 ' buf\mbox{[}0\mbox{]} = '0' buf\mbox{[}1\mbox{]} = 'X' buf\mbox{[}2\mbox{]} = 'A' .... buf\mbox{[}7\mbox{]} = 'F' buf\mbox{[}8\mbox{]} = '\par |
|
345 ' buf\mbox{[}9\mbox{]} = '' |
|
346 |
|
347 Definition at line 135 of file can\-Open\-Driver.c.\hypertarget{canOpenDriver_8c_c71399958d35a7f703416f025603ee26}{ |
|
348 \index{canOpenDriver.c@{can\-Open\-Driver.c}!initHCS12@{initHCS12}} |
|
349 \index{initHCS12@{initHCS12}!canOpenDriver.c@{can\-Open\-Driver.c}} |
|
350 \subsubsection[initHCS12]{\setlength{\rightskip}{0pt plus 5cm}void init\-HCS12 (void)}} |
|
351 \label{canOpenDriver_8c_c71399958d35a7f703416f025603ee26} |
|
352 |
|
353 |
|
354 Put here all the code to init the HCS12. |
|
355 |
|
356 |
|
357 |
|
358 Definition at line 199 of file can\-Open\-Driver.c. |
|
359 |
|
360 References init\-PLL(), and MSG\_\-WAR.\hypertarget{canOpenDriver_8c_51e71c727eb7a49e2fde962a3d190a6b}{ |
|
361 \index{canOpenDriver.c@{can\-Open\-Driver.c}!initPLL@{initPLL}} |
|
362 \index{initPLL@{initPLL}!canOpenDriver.c@{can\-Open\-Driver.c}} |
|
363 \subsubsection[initPLL]{\setlength{\rightskip}{0pt plus 5cm}void init\-PLL (void)}} |
|
364 \label{canOpenDriver_8c_51e71c727eb7a49e2fde962a3d190a6b} |
|
365 |
|
366 |
|
367 to start using the PLL. Bus clock becomes 24 MHz if the quartz on the board is at 16 MHz |
|
368 |
|
369 Definition at line 188 of file can\-Open\-Driver.c. |
|
370 |
|
371 References CLKSEL, CRGFLG, IO\_\-PORTS\_\-8, PLLCTL, REFDV, and SYNR.\hypertarget{canOpenDriver_8c_f86db4b817c1a59a819cbdd51779bfaa}{ |
|
372 \index{canOpenDriver.c@{can\-Open\-Driver.c}!initSCI_0@{initSCI\_\-0}} |
|
373 \index{initSCI_0@{initSCI\_\-0}!canOpenDriver.c@{can\-Open\-Driver.c}} |
|
374 \subsubsection[initSCI\_\-0]{\setlength{\rightskip}{0pt plus 5cm}void init\-SCI\_\-0 (void)}} |
|
375 \label{canOpenDriver_8c_f86db4b817c1a59a819cbdd51779bfaa} |
|
376 |
|
377 |
|
378 Initialisation of the serial port 0. |
|
379 |
|
380 |
|
381 |
|
382 Definition at line 115 of file can\-Open\-Driver.c. |
|
383 |
|
384 References BUS\_\-CLOCK, IO\_\-PORTS\_\-16, IO\_\-PORTS\_\-8, SCI0, SCIBDH, SCICR1, SCICR2, and SERIAL\_\-SCI0\_\-BAUD\_\-RATE.\hypertarget{canOpenDriver_8c_b56fa1754706a57059103710178bdb68}{ |
|
385 \index{canOpenDriver.c@{can\-Open\-Driver.c}!initSCI_1@{initSCI\_\-1}} |
|
386 \index{initSCI_1@{initSCI\_\-1}!canOpenDriver.c@{can\-Open\-Driver.c}} |
|
387 \subsubsection[initSCI\_\-1]{\setlength{\rightskip}{0pt plus 5cm}void init\-SCI\_\-1 (void)}} |
|
388 \label{canOpenDriver_8c_b56fa1754706a57059103710178bdb68} |
|
389 |
|
390 |
|
391 Initialisation of the serial port 1. |
|
392 |
|
393 |
|
394 |
|
395 Definition at line 124 of file can\-Open\-Driver.c. |
|
396 |
|
397 References BUS\_\-CLOCK, IO\_\-PORTS\_\-16, IO\_\-PORTS\_\-8, SCI1, SCIBDH, SCICR1, SCICR2, and SERIAL\_\-SCI1\_\-BAUD\_\-RATE.\hypertarget{canOpenDriver_8c_02922529b60419a94afe8f369dda070b}{ |
|
398 \index{canOpenDriver.c@{can\-Open\-Driver.c}!initTimer@{initTimer}} |
|
399 \index{initTimer@{initTimer}!canOpenDriver.c@{can\-Open\-Driver.c}} |
|
400 \subsubsection[initTimer]{\setlength{\rightskip}{0pt plus 5cm}void init\-Timer (void)}} |
|
401 \label{canOpenDriver_8c_02922529b60419a94afe8f369dda070b} |
|
402 |
|
403 |
|
404 |
|
405 |
|
406 Definition at line 79 of file can\-Open\-Driver.c.\hypertarget{canOpenDriver_8c_80f5dbbc046cba0e5e9cf2bcc4c1e78e}{ |
|
407 \index{canOpenDriver.c@{can\-Open\-Driver.c}!printSCI_nbr@{printSCI\_\-nbr}} |
|
408 \index{printSCI_nbr@{printSCI\_\-nbr}!canOpenDriver.c@{can\-Open\-Driver.c}} |
|
409 \subsubsection[printSCI\_\-nbr]{\setlength{\rightskip}{0pt plus 5cm}void print\-SCI\_\-nbr (char {\em sci}, unsigned long {\em nbr}, char {\em last\-Car})}} |
|
410 \label{canOpenDriver_8c_80f5dbbc046cba0e5e9cf2bcc4c1e78e} |
|
411 |
|
412 |
|
413 Print the number in hexadecimal to the serial port sci (sci takes the values SCI0 or SCI1) |
|
414 |
|
415 Definition at line 179 of file can\-Open\-Driver.c. |
|
416 |
|
417 References hex\_\-convert(), and print\-SCI\_\-str().\hypertarget{canOpenDriver_8c_6e3075ae435e83aefc018e5218c197d0}{ |
|
418 \index{canOpenDriver.c@{can\-Open\-Driver.c}!printSCI_str@{printSCI\_\-str}} |
|
419 \index{printSCI_str@{printSCI\_\-str}!canOpenDriver.c@{can\-Open\-Driver.c}} |
|
420 \subsubsection[printSCI\_\-str]{\setlength{\rightskip}{0pt plus 5cm}void print\-SCI\_\-str (char {\em sci}, const char $\ast$ {\em str})}} |
|
421 \label{canOpenDriver_8c_6e3075ae435e83aefc018e5218c197d0} |
|
422 |
|
423 |
|
424 Print the string to the serial port sci (sci takes the values SCI0 or SCI1) |
|
425 |
|
426 Definition at line 162 of file can\-Open\-Driver.c. |
|
427 |
|
428 References IO\_\-PORTS\_\-8, SCIDRL, and SCISR1.\hypertarget{canOpenDriver_8c_339b24f4eee897d3c45d88de9a4901e8}{ |
|
429 \index{canOpenDriver.c@{can\-Open\-Driver.c}!resetTimer@{resetTimer}} |
|
430 \index{resetTimer@{resetTimer}!canOpenDriver.c@{can\-Open\-Driver.c}} |
|
431 \subsubsection[resetTimer]{\setlength{\rightskip}{0pt plus 5cm}void reset\-Timer (void)}} |
|
432 \label{canOpenDriver_8c_339b24f4eee897d3c45d88de9a4901e8} |
|
433 |
|
434 |
|
435 |
|
436 |
|
437 Definition at line 73 of file can\-Open\-Driver.c. |
|