Moved interface version to new string format with trailing textual 0.0.0 version...
[freeems-vanilla.git] / src / xgateVectors.c
blobb5d36428a415a8c7f9f3eebd700f431722fcf732
1 /* FreeEMS - the open source engine management system
3 * Copyright 2010 Sean Keys, Fred Cooke
5 * This file is part of the FreeEMS project.
7 * FreeEMS software is free software: you can redistribute it and/or modify
8 * it under the terms of the GNU General Public License as published by
9 * the Free Software Foundation, either version 3 of the License, or
10 * (at your option) any later version.
12 * FreeEMS software is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 * GNU General Public License for more details.
17 * You should have received a copy of the GNU General Public License
18 * along with any FreeEMS software. If not, see http://www.gnu.org/licenses/
20 * We ask that if you make any changes to this file you email them upstream to
21 * us at admin(at)diyefi(dot)org or, even better, fork the code on github.com!
23 * Thank you for choosing FreeEMS to run your engine!
27 /** @file xgateVectors.c
28 * @ingroup interruptHandlers
30 * @brief XGATE Interrupt Vector Table
32 * This file contains the definition of the XGATE interrupt vector table.
33 * This table consists only of pointers to xgate code blocks which are by
34 * definition void. These will be called by the hardware when an interrupt
35 * of a certain type occurs.
37 * @author Sean Keys
41 #define XGATEVECTORS_C
42 #include "inc/freeEMS.h"
43 #include "inc/xgateVectors.h"
46 /* Currently this gets copied from wherever it ends up into the XGATE flash pages */
47 const xgateIntVector xgateIntVectorTable[] PPAGE_E0X = {
48 /* Channel ID = vector address offset / 4 */
49 /* channel 0x00-0x08 are not used, 0x09-0x1D are reserved first used must match macro XGATE_VECTOR_OFFSET in xgate.h */
50 {XGATE_ERROR_HANDLER, 0x00}, /* NOT USED */
51 {XGATE_ERROR_HANDLER, 0x01}, /* NOT USED */
52 {XGATE_ERROR_HANDLER, 0x02}, /* NOT USED */
53 {XGATE_ERROR_HANDLER, 0x03}, /* NOT USED */
54 {XGATE_ERROR_HANDLER, 0x04}, /* NOT USED */
55 {XGATE_ERROR_HANDLER, 0x05}, /* NOT USED */
56 {XGATE_ERROR_HANDLER, 0x06}, /* NOT USED */
57 {XGATE_ERROR_HANDLER, 0x07}, /* NOT USED */
58 {XGATE_ERROR_HANDLER, 0x08}, /* NOT USED */
59 {XGATE_ERROR_HANDLER, 0x09}, // RESERVED
60 {XGATE_ERROR_HANDLER, 0x0A}, // RESERVED
61 {XGATE_ERROR_HANDLER, 0x0B}, // RESERVED
62 {XGATE_ERROR_HANDLER, 0x0C}, // RESERVED
63 {XGATE_ERROR_HANDLER, 0x0D}, // RESERVED
64 {XGATE_ERROR_HANDLER, 0x0E}, // RESERVED
65 {XGATE_ERROR_HANDLER, 0x0F}, // RESERVED
66 {XGATE_ERROR_HANDLER, 0x10}, // RESERVED
67 {XGATE_ERROR_HANDLER, 0x11}, // RESERVED
68 {XGATE_ERROR_HANDLER, 0x12}, // RESERVED
69 {XGATE_ERROR_HANDLER, 0x13}, // RESERVED
70 {XGATE_ERROR_HANDLER, 0x14}, // RESERVED
71 {XGATE_ERROR_HANDLER, 0x15}, // RESERVED
72 {XGATE_ERROR_HANDLER, 0x16}, // RESERVED
73 {XGATE_ERROR_HANDLER, 0x17}, // RESERVED
74 {XGATE_ERROR_HANDLER, 0x18}, // RESERVED
75 {XGATE_ERROR_HANDLER, 0x19}, // RESERVED
76 {XGATE_ERROR_HANDLER, 0x1A}, // RESERVED
77 {XGATE_ERROR_HANDLER, 0x1B}, // RESERVED
78 {XGATE_ERROR_HANDLER, 0x1C}, // RESERVED
79 {XGATE_ERROR_HANDLER, 0x1D}, // RESERVED
80 {XGATE_ERROR_HANDLER, 0x1E}, // RESERVED
81 {XGATE_ERROR_HANDLER, 0x1F}, // RESERVED
82 {XGATE_ERROR_HANDLER, 0x20}, // RESERVED
83 {XGATE_ERROR_HANDLER, 0x21}, // RESERVED
84 {XGATE_ERROR_HANDLER, 0x22}, // RESERVED
85 {XGATE_ERROR_HANDLER, 0x23}, // RESERVED
86 {XGATE_ERROR_HANDLER, 0x24}, // RESERVED
87 {XGATE_ERROR_HANDLER, 0x25}, // RESERVED
88 {XGATE_ERROR_HANDLER, 0x26}, // RESERVED
89 {XGATE_ERROR_HANDLER, 0x27}, // RESERVED
90 {XGATE_ERROR_HANDLER, 0x28}, // RESERVED
91 {XGATE_ERROR_HANDLER, 0x29}, // RESERVED
92 {XGATE_ERROR_HANDLER, 0x2A}, // RESERVED
93 {XGATE_ERROR_HANDLER, 0x2B}, // RESERVED
94 {XGATE_ERROR_HANDLER, 0x2C}, // RESERVED
95 {XGATE_ERROR_HANDLER, 0x2D}, // RESERVED
96 {XGATE_ERROR_HANDLER, 0x2E}, // RESERVED
97 {XGATE_ERROR_HANDLER, 0x2F}, // RESERVED
98 {XGATE_ERROR_HANDLER, 0x30}, // special - Reserved S12XCPU RAM access violation
99 {XGATE_ERROR_HANDLER, 0x31}, // special - Reserved XGATE software error interrupt
100 {XGATE_ERROR_HANDLER, 0x32}, // Channel 32 - XGATE Software Trigger 7
101 {XGATE_ERROR_HANDLER, 0x33}, // Channel 33 - XGATE Software Trigger 6
102 {XGATE_ERROR_HANDLER, 0x34}, // Channel 34 - XGATE Software Trigger 5
103 {XGATE_ERROR_HANDLER, 0x35}, // Channel 35 - XGATE Software Trigger 4
104 {XGATE_ERROR_HANDLER, 0x36}, // Channel 36 - XGATE Software Trigger 3
105 {XGATE_ERROR_HANDLER, 0x37}, // Channel 37 - XGATE Software Trigger 2
106 {XGATE_ERROR_HANDLER, 0x38}, // Channel 38 - XGATE Software Trigger 1
107 {(unsigned short)xgateSchedule, (unsigned short)&PORTP}, // Channel 39 - XGATE Software Trigger 0 address in first field is from xgate linear 64k point of view. The VMA MUST BE CHANGED IN THE COPYOPTS PORTION OF THE MAKEFILE to reflect how xgate see's this section
108 {XGATE_ERROR_HANDLER, 0x3A}, // Channel 3A - Periodic Interrupt Timer 3
109 {(unsigned short)xgateDelayCounter, 0x3B}, // Channel 3B - Periodic Interrupt Timer 2
110 {(unsigned short)xgatePITTurnOff, 0x3C}, // Channel 3C - Periodic Interrupt Timer 1
111 {(unsigned short)xgatePITTurnOn, 0x3D}, // Channel 3D - Periodic Interrupt Timer 0
112 {XGATE_ERROR_HANDLER, 0x3E}, // Reserved
113 {XGATE_ERROR_HANDLER, 0x3F}, // Channel 3F - Autonomous Periodical interrupt API
114 {XGATE_ERROR_HANDLER, 0x40}, // Channel 40 - Low Voltage interrupt LVI
115 {XGATE_ERROR_HANDLER, 0x41}, // Channel 41 - IIC1 Bus
116 {XGATE_ERROR_HANDLER, 0x42}, // Channel 42 - SCI5
117 {XGATE_ERROR_HANDLER, 0x43}, // Channel 43 - SCI4
118 {XGATE_ERROR_HANDLER, 0x44}, // Channel 44 - SCI3
119 {XGATE_ERROR_HANDLER, 0x45}, // Channel 45 - SCI2
120 {XGATE_ERROR_HANDLER, 0x46}, // Channel 46 - PWM Emergency Shutdown
121 {XGATE_ERROR_HANDLER, 0x47}, // Channel 47 - Port P Interrupt
122 {XGATE_ERROR_HANDLER, 0x48}, // Channel 48 - CAN4 transmit
123 {XGATE_ERROR_HANDLER, 0x49}, // Channel 49 - CAN4 receive
124 {XGATE_ERROR_HANDLER, 0x4A}, // Channel 4A - CAN4 errors
125 {XGATE_ERROR_HANDLER, 0x4B}, // Channel 4B - CAN4 wake-up
126 {XGATE_ERROR_HANDLER, 0x4C}, // Channel 4C - CAN3 transmit
127 {XGATE_ERROR_HANDLER, 0x4D}, // Channel 4D - CAN3 receive
128 {XGATE_ERROR_HANDLER, 0x4E}, // Channel 4E - CAN3 errors
129 {XGATE_ERROR_HANDLER, 0x4F}, // Channel 4F - CAN3 wake-up
130 {XGATE_ERROR_HANDLER, 0x50}, // Channel 50 - CAN2 transmit
131 {XGATE_ERROR_HANDLER, 0x51}, // Channel 51 - CAN2 receive
132 {XGATE_ERROR_HANDLER, 0x52}, // Channel 52 - CAN2 errors
133 {XGATE_ERROR_HANDLER, 0x53}, // Channel 53 - CAN2 wake-up
134 {XGATE_ERROR_HANDLER, 0x54}, // Channel 54 - CAN1 transmit
135 {XGATE_ERROR_HANDLER, 0x55}, // Channel 55 - CAN1 receive
136 {XGATE_ERROR_HANDLER, 0x56}, // Channel 56 - CAN1 errors
137 {XGATE_ERROR_HANDLER, 0x57}, // Channel 57 - CAN1 wake-up
138 {XGATE_ERROR_HANDLER, 0x58}, // Channel 58 - CAN0 transmit
139 {XGATE_ERROR_HANDLER, 0x59}, // Channel 59 - CAN0 receive
140 {XGATE_ERROR_HANDLER, 0x5A}, // Channel 5A - CAN0 errors
141 {XGATE_ERROR_HANDLER, 0x5B}, // Channel 5B - CAN0 wake-up
142 {XGATE_ERROR_HANDLER, 0x5C}, // Channel 5C - FLASH
143 {XGATE_ERROR_HANDLER, 0x5D}, // Channel 5D - EEPROM
144 {XGATE_ERROR_HANDLER, 0x5E}, // Channel 5E - SPI2
145 {XGATE_ERROR_HANDLER, 0x5F}, // Channel 5F - SPI1
146 {XGATE_ERROR_HANDLER, 0x60}, // Channel 60 - IIC0 Bus
147 {XGATE_ERROR_HANDLER, 0x61}, // RESERVED
148 {XGATE_ERROR_HANDLER, 0x62}, // Channel 62 - CRG Self Clock Mode
149 {XGATE_ERROR_HANDLER, 0x63}, // Channel 63 - CRG PLL lock
150 {XGATE_ERROR_HANDLER, 0x64}, // Channel 64 - Pulse Accumulator B Overflow
151 {XGATE_ERROR_HANDLER, 0x65}, // Channel 65 - Modulus Down Counter underflow
152 {XGATE_ERROR_HANDLER, 0x66}, // Channel 66 - Port H
153 {XGATE_ERROR_HANDLER, 0x67}, // Channel 67 - Port J
154 {XGATE_ERROR_HANDLER, 0x68}, // Channel 68 - ATD1
155 {XGATE_ERROR_HANDLER, 0x69}, // Channel 69 - ATD0
156 {XGATE_ERROR_HANDLER, 0x6A}, // Channel 6A - SCI1
157 {XGATE_ERROR_HANDLER, 0x6B}, // Channel 6B - SCI0
158 {XGATE_ERROR_HANDLER, 0x6C}, // Channel 6C - SPI0
159 {XGATE_ERROR_HANDLER, 0x6D}, // Channel 6D - ECT Pulse accumulator input edge
160 {XGATE_ERROR_HANDLER, 0x6E}, // Channel 6E - ECT Pulse accumulator A overflow
161 {XGATE_ERROR_HANDLER, 0x6F}, // Channel 6F - Enhanced Capture Timer overflow
162 {XGATE_ERROR_HANDLER, 0x70}, // Channel 70 - Enhanced Capture Timer channel 7
163 {XGATE_ERROR_HANDLER, 0x71}, // Channel 71 - Enhanced Capture Timer channel 6
164 {XGATE_ERROR_HANDLER, 0x72}, // Channel 72 - Enhanced Capture Timer channel 5
165 {XGATE_ERROR_HANDLER, 0x73}, // Channel 73 - Enhanced Capture Timer channel 4
166 {XGATE_ERROR_HANDLER, 0x74}, // Channel 74 - Enhanced Capture Timer channel 3
167 {XGATE_ERROR_HANDLER, 0x75}, // Channel 75 - Enhanced Capture Timer channel 2
168 {XGATE_ERROR_HANDLER, 0x76}, // Channel 76 - Enhanced Capture Timer channel 1
169 {XGATE_ERROR_HANDLER, 0x77}, // Channel 77 - Enhanced Capture Timer channel 0
170 {XGATE_ERROR_HANDLER, 0x78} // Channel 78 - Real Time Interrupt