Netcruzer Library API  V2.03
 All Data Structures Files Functions Variables Typedefs Enumerations Macros Groups Pages
nz_pt66ei24p.h
Go to the documentation of this file.
1 
106 #ifndef PT66EI_24P_H
107 #define PT66EI_24P_H
108 
109 #if defined(XBRD_PT66EI24P)
110 
112 //Global variables
113 
114 //This is used by other application modules
115 #ifndef THIS_IS_NZ_PT66EI_24P_C
116 extern BYTE pt66ei24pLeds0to7;
117 #endif
118 
119 
123 void pt66ei24p_Init(void);
124 
125 
137 void pt66ei24p_WriteLeds(BYTE value);
138 
139 
140 
141 // *********************************************************************
142 // ------------------------- iMod Port 1 Defines -----------------------
143 // *********************************************************************
144 #define HAS_IMOD1
145 
146 #define IMOD1_PIN2
147 #define IMOD1_PIN2_IS_DIG //Digital I/O port of CPU
148 #define IMOD1_PIN2_IS_PPS
149 #ifdef PIN_08
150 #define PIN_IMOD1_P2 PIN_08
151 #define LAT_IMOD1_P2 LAT_08
152 #define DIR_IMOD1_P2 DIR_08
153 #define PULLUP_IMOD1_P2 PULLUP_08
154 #define PULLDOWN_IMOD1_P2 PULLDOWN_08
155 #define PPS_LAT_IMOD1_P2 PPS_OUT_08
156 #define PPS_IN_IMOD1_P2 PPS_IN_08
157 #define imod1_ConfDirPin2(dir) (DIR_IMOD1_P2 = dir)
158 #define imod1_WritePin2(val) (LAT_IMOD1_P2 = val)
159 #define imod1_ReadPin2() (PIN_IMOD1_P2)
160 #define imod1_ConfPullupPin2(val) (PULLUP_IMOD1_P2 = val)
161 #define imod1_ConfPulldownPin2(val) (PULLDOWN_IMOD1_P2 = val)
162 #endif
163 
164 #define IMOD1_PIN3
165 #define IMOD1_PIN3_IS_DIG
166 #define IMOD1_PIN3_IS_PPS
167 #ifdef PIN_07
168 #define PIN_IMOD1_P3 PIN_07
169 #define LAT_IMOD1_P3 LAT_07
170 #define DIR_IMOD1_P3 DIR_07
171 #define PULLUP_IMOD1_P3 PULLUP_07
172 #define PULLDOWN_IMOD1_P3 PULLDOWN_07
173 #define PPS_LAT_IMOD1_P3 PPS_OUT_07
174 #define PPS_IN_IMOD1_P3 PPS_IN_07
175 #define imod1_ConfDirPin3(dir) (DIR_IMOD1_P3 = dir)
176 #define imod1_WritePin3(val) (LAT_IMOD1_P3 = val)
177 #define imod1_ReadPin3() (PIN_IMOD1_P3)
178 #define imod1_ConfPullupPin3(val) (PULLUP_IMOD1_P3 = val)
179 #define imod1_ConfPulldownPin3(val) (PULLDOWN_IMOD1_P3 = val)
180 #endif
181 
182 #define IMOD1_PIN4
183 #define IMOD1_PIN4_IS_DIG
184 #define IMOD1_PIN4_IS_PPS
185 #ifdef PIN_06
186 #define PIN_IMOD1_P4 PIN_06
187 #define LAT_IMOD1_P4 LAT_06
188 #define DIR_IMOD1_P4 DIR_06
189 #define PULLUP_IMOD1_P4 PULLUP_06
190 #define PULLDOWN_IMOD1_P4 PULLDOWN_06
191 #define PPS_LAT_IMOD1_P4 PPS_OUT_06
192 #define PPS_IN_IMOD1_P4 PPS_IN_06
193 #define imod1_ConfDirPin4(dir) (DIR_IMOD1_P4 = dir)
194 #define imod1_WritePin4(val) (LAT_IMOD1_P4 = val)
195 #define imod1_ReadPin4() (PIN_IMOD1_P4)
196 #define imod1_ConfPullupPin4(val) (PULLUP_IMOD1_P4 = val)
197 #define imod1_ConfPulldownPin4(val) (PULLDOWN_IMOD1_P4 = val)
198 #endif
199 
200 #define IMOD1_PIN5
201 #define IMOD1_PIN5_IS_PPS
202 #define IMOD1_PIN5_IS_DIG
203 #define IMOD1_PIN5_IS_ANALOG
204 #ifdef PIN_01
205 #define PIN_IMOD1_P5 PIN_01
206 #define LAT_IMOD1_P5 LAT_01
207 #define DIR_IMOD1_P5 DIR_01
208 #define PULLUP_IMOD1_P5 PULLUP_01
209 #define PULLDOWN_IMOD1_P5 PULLDOWN_01
210 #define PPS_LAT_IMOD1_P5 PPS_OUT_01
211 #define PPS_IN_IMOD1_P5 PPS_IN_01
212 #define imod1_ConfDirPin5(dir) (DIR_IMOD1_P5 = dir)
213 #define imod1_WritePin5(val) (LAT_IMOD1_P5 = val)
214 #define imod1_ReadPin5() (PIN_IMOD1_P5)
215 #define imod1_ConfPullupPin5(val) (PULLUP_IMOD1_P5 = val)
216 #define imod1_ConfPulldownPin5(val) (PULLDOWN_IMOD1_P5 = val)
217 #endif
218 
219 #define IMOD1_PIN6
220 #define IMOD1_PIN6_IS_DIG
221 #define IMOD1_PIN6_IS_ANALOG
222 #ifdef PIN_32
223 #define PIN_IMOD1_P6 PIN_32
224 #define LAT_IMOD1_P6 LAT_32
225 #define DIR_IMOD1_P6 DIR_32
226 #define PULLUP_IMOD1_P6 PULLUP_32
227 #define PULLDOWN_IMOD1_P6 PULLDOWN_32
228 #define imod1_ConfDirPin6(dir) (DIR_IMOD1_P6 = dir)
229 #define imod1_WritePin6(val) (LAT_IMOD1_P6 = val)
230 #define imod1_ReadPin6() (PIN_IMOD1_P6)
231 #define imod1_ConfPullupPin6(val) (PULLUP_IMOD1_P6 = val)
232 #define imod1_ConfPulldownPin6(val) (PULLDOWN_IMOD1_P6 = val)
233 #endif
234 
235 #define IMOD1_PIN7
236 #define IMOD1_PIN7_IS_PPS
237 #define IMOD1_PIN7_IS_DIG
238 #define IMOD1_PIN7_IS_ANALOG
239 #ifdef PIN_31
240 #define PIN_IMOD1_P7 PIN_31
241 #define LAT_IMOD1_P7 LAT_31
242 #define DIR_IMOD1_P7 DIR_31
243 #define PULLUP_IMOD1_P7 PULLUP_31
244 #define PULLDOWN_IMOD1_P7 PULLDOWN_31
245 #define PPS_LAT_IMOD1_P7 PPS_OUT_31
246 #define PPS_IN_IMOD1_P7 PPS_IN_31
247 #define imod1_ConfDirPin7(dir) (DIR_IMOD1_P7 = dir)
248 #define imod1_WritePin7(val) (LAT_IMOD1_P7 = val)
249 #define imod1_ReadPin7() (PIN_IMOD1_P7)
250 #define imod1_ConfPullupPin7(val) (PULLUP_IMOD1_P7 = val)
251 #define imod1_ConfPulldownPin7(val) (PULLDOWN_IMOD1_P7 = val)
252 #endif
253 
254 
255 // *********************************************************************
256 // ------------------------- iMod Port 2 Defines -----------------------
257 // *********************************************************************
258 #define HAS_IMOD2
259 
260 #define IMOD2_PIN2
261 #define IMOD2_PIN2_IS_DIG
262 #define IMOD2_PIN2_IS_PPS
263 #define PIN_IMOD2_P2 PIN_39
264 #define LAT_IMOD2_P2 LAT_39
265 #define DIR_IMOD2_P2 DIR_39
266 #define PULLUP_IMOD2_P2 PULLUP_39
267 #define PULLDOWN_IMOD2_P2 PULLDOWN_39
268 #define PPS_LAT_IMOD2_P2 PPS_OUT_39
269 #define PPS_IN_IMOD2_P2 PPS_IN_39
270 #define imod2_ConfDirPin2(dir) (DIR_IMOD2_P2 = dir)
271 #define imod2_WritePin2(val) (LAT_IMOD2_P2 = val)
272 #define imod2_ReadPin2() (PIN_IMOD2_P2)
273 #define imod2_ConfPullupPin2(val) (PULLUP_IMOD2_P2 = val)
274 #define imod2_ConfPulldownPin2(val) (PULLDOWN_IMOD2_P2 = val)
275 
276 #define IMOD2_PIN3
277 #define IMOD2_PIN3_IS_DIG
278 #define IMOD2_PIN3_IS_PPS
279 #define PIN_IMOD2_P3 PIN_09
280 #define LAT_IMOD2_P3 LAT_09
281 #define DIR_IMOD2_P3 DIR_09
282 #define PULLUP_IMOD2_P3 PULLUP_09
283 #define PULLDOWN_IMOD2_P3 PULLDOWN_09
284 #define PPS_LAT_IMOD2_P3 PPS_OUT_09
285 #define PPS_IN_IMOD2_P3 PPS_IN_09
286 #define imod2_ConfDirPin3(dir) (DIR_IMOD2_P3 = dir)
287 #define imod2_WritePin3(val) (LAT_IMOD2_P3 = val)
288 #define imod2_ReadPin3() (PIN_IMOD2_P3)
289 #define imod2_ConfPullupPin3(val) (PULLUP_IMOD2_P3 = val)
290 #define imod2_ConfPulldownPin3(val) (PULLDOWN_IMOD2_P3 = val)
291 
292 #define IMOD2_PIN4
293 #define IMOD2_PIN4_IS_DIG
294 #define IMOD2_PIN4_IS_PPS
295 #define PIN_IMOD2_P4 PIN_38
296 #define LAT_IMOD2_P4 LAT_38
297 #define DIR_IMOD2_P4 DIR_38
298 #define PULLUP_IMOD2_P4 PULLUP_38
299 #define PULLDOWN_IMOD2_P4 PULLDOWN_38
300 #define PPS_LAT_IMOD2_P4 PPS_OUT_38
301 #define PPS_IN_IMOD2_P4 PPS_IN_38
302 #define imod2_ConfDirPin4(dir) (DIR_IMOD2_P4 = dir)
303 #define imod2_WritePin4(val) (LAT_IMOD2_P4 = val)
304 #define imod2_ReadPin4() (PIN_IMOD2_P4)
305 #define imod2_ConfPullupPin4(val) (PULLUP_IMOD2_P4 = val)
306 #define imod2_ConfPulldownPin4(val) (PULLDOWN_IMOD2_P4 = val)
307 
308 #define IMOD2_PIN5
309 #define IMOD2_PIN5_IS_DIG
310 #define IMOD2_PIN5_IS_ANALOG
311 #define IMOD2_PIN5_IS_PPS
312 #define PIN_IMOD2_P5 PIN_02
313 #define LAT_IMOD2_P5 LAT_02
314 #define DIR_IMOD2_P5 DIR_02
315 #define PULLUP_IMOD2_P5 PULLUP_02
316 #define PULLDOWN_IMOD2_P5 PULLDOWN_02
317 #define PPS_LAT_IMOD2_P5 PPS_OUT_02
318 #define PPS_IN_IMOD2_P5 PPS_IN_02
319 #define imod2_ConfDirPin5(dir) (DIR_IMOD2_P5 = dir)
320 #define imod2_WritePin5(val) (LAT_IMOD2_P5 = val)
321 #define imod2_ReadPin5() (PIN_IMOD2_P5)
322 #define imod2_ConfPullupPin5(val) (PULLUP_IMOD2_P5 = val)
323 #define imod2_ConfPulldownPin5(val) (PULLDOWN_IMOD2_P5 = val)
324 
325 #define IMOD2_PIN6
326 #define IMOD2_PIN6_IS_DIG
327 #define IMOD2_PIN6_IS_ANALOG
328 #define PIN_IMOD2_P6 PIN_03
329 #define LAT_IMOD2_P6 LAT_03
330 #define DIR_IMOD2_P6 DIR_03
331 #define PULLUP_IMOD2_P6 PULLUP_03
332 #define PULLDOWN_IMOD2_P6 PULLDOWN_03
333 #define imod2_ConfDirPin6(dir) (DIR_IMOD2_P6 = dir)
334 #define imod2_WritePin6(val) (LAT_IMOD2_P6 = val)
335 #define imod2_ReadPin6() (PIN_IMOD2_P6)
336 #define imod2_ConfPullupPin6(val) (PULLUP_IMOD2_P6 = val)
337 #define imod2_ConfPulldownPin6(val) (PULLDOWN_IMOD2_P6 = val)
338 
339 #define IMOD2_PIN7
340 #define IMOD2_PIN7_IS_DIG
341 #define IMOD2_PIN7_IS_ANALOG
342 #define IMOD2_PIN7_IS_PPS
343 #define PIN_IMOD2_P7 PIN_04
344 #define LAT_IMOD2_P7 LAT_04
345 #define DIR_IMOD2_P7 DIR_04
346 #define PULLUP_IMOD2_P7 PULLUP_04
347 #define PULLDOWN_IMOD2_P7 PULLDOWN_04
348 #define PPS_LAT_IMOD2_P7 PPS_OUT_04
349 #define PPS_IN_IMOD2_P7 PPS_IN_04
350 #define imod2_ConfDirPin7(dir) (DIR_IMOD2_P7 = dir)
351 #define imod2_WritePin7(val) (LAT_IMOD2_P7 = val)
352 #define imod2_ReadPin7() (PIN_IMOD2_P7)
353 #define imod2_ConfPullupPin7(val) (PULLUP_IMOD2_P7 = val)
354 #define imod2_ConfPulldownPin7(val) (PULLDOWN_IMOD2_P7 = val)
355 
356 #endif //#if defined(XBRD_PT66EI24P)
357 
358 #endif //#ifndef PT66EI_24P_H