Subversion Repositories svnkaklik

Rev

Rev 151 | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log

Rev 151 Rev 174
Line 1... Line 1...
1
GAS LISTING /tmp/ccAE2QZt.s 			page 1
1
GAS LISTING /tmp/ccQQINeY.s 			page 1
2
 
2
 
3
 
3
 
4
   1               		.file	"CamInterface.c"
4
   1               		.file	"CamInterface.c"
5
   2               		.arch atmega8
5
   2               		.arch atmega8
6
   3               	__SREG__ = 0x3f
6
   3               	__SREG__ = 0x3f
Line 8... Line 8...
8
   5               	__SP_L__ = 0x3d
8
   5               	__SP_L__ = 0x3d
9
   6               	__tmp_reg__ = 0
9
   6               	__tmp_reg__ = 0
10
   7               	__zero_reg__ = 1
10
   7               	__zero_reg__ = 1
11
   8               		.global __do_copy_data
11
   8               		.global __do_copy_data
12
   9               		.global __do_clear_bss
12
   9               		.global __do_clear_bss
13
  10               		.stabs	"/home/kaklik/projects/roboti/istrobot/2007/ATmega8/AVRcam/",100,0,2,.Ltext0
13
  10               		.stabs	"/home/kaklik/projects/programy/Atmel_C/AVRcam/",100,0,2,.Ltext0
14
  11               		.stabs	"CamInterface.c",100,0,2,.Ltext0
14
  11               		.stabs	"CamInterface.c",100,0,2,.Ltext0
15
  12               		.text
15
  12               		.text
16
  13               	.Ltext0:
16
  13               	.Ltext0:
17
  14               		.stabs	"gcc2_compiled.",60,0,0,0
17
  14               		.stabs	"gcc2_compiled.",60,0,0,0
18
  15               		.stabs	"int:t(0,1)=r(0,1);-32768;32767;",128,0,0,0
18
  15               		.stabs	"int:t(0,1)=r(0,1);-32768;32767;",128,0,0,0
Line 56... Line 56...
56
  53               		.stabs	"int_fast8_t:t(5,19)=(5,1)",128,0,200,0
56
  53               		.stabs	"int_fast8_t:t(5,19)=(5,1)",128,0,200,0
57
  54               		.stabs	"uint_fast8_t:t(5,20)=(5,2)",128,0,205,0
57
  54               		.stabs	"uint_fast8_t:t(5,20)=(5,2)",128,0,205,0
58
  55               		.stabs	"int_fast16_t:t(5,21)=(5,3)",128,0,210,0
58
  55               		.stabs	"int_fast16_t:t(5,21)=(5,3)",128,0,210,0
59
  56               		.stabs	"uint_fast16_t:t(5,22)=(5,4)",128,0,215,0
59
  56               		.stabs	"uint_fast16_t:t(5,22)=(5,4)",128,0,215,0
60
  57               		.stabs	"int_fast32_t:t(5,23)=(5,5)",128,0,220,0
60
  57               		.stabs	"int_fast32_t:t(5,23)=(5,5)",128,0,220,0
61
GAS LISTING /tmp/ccAE2QZt.s 			page 2
61
GAS LISTING /tmp/ccQQINeY.s 			page 2
62
 
62
 
63
 
63
 
64
  58               		.stabs	"uint_fast32_t:t(5,24)=(5,6)",128,0,225,0
64
  58               		.stabs	"uint_fast32_t:t(5,24)=(5,6)",128,0,225,0
65
  59               		.stabs	"int_fast64_t:t(5,25)=(5,7)",128,0,230,0
65
  59               		.stabs	"int_fast64_t:t(5,25)=(5,7)",128,0,230,0
66
  60               		.stabs	"uint_fast64_t:t(5,26)=(5,8)",128,0,235,0
66
  60               		.stabs	"uint_fast64_t:t(5,26)=(5,8)",128,0,235,0
Line 87... Line 87...
87
  81               		.stabs	"__compar_fn_t:t(8,5)=(8,6)=*(8,7)=f(0,1)",128,0,78,0
87
  81               		.stabs	"__compar_fn_t:t(8,5)=(8,6)=*(8,7)=f(0,1)",128,0,78,0
88
  82               		.stabn	162,0,0,0
88
  82               		.stabn	162,0,0,0
89
  83               		.stabs	"CommonDefs.h",130,0,0,0
89
  83               		.stabs	"CommonDefs.h",130,0,0,0
90
  84               		.stabs	"bool_t:t(10,1)=(0,11)",128,0,56,0
90
  84               		.stabs	"bool_t:t(10,1)=(0,11)",128,0,56,0
91
  85               		.stabn	162,0,0,0
91
  85               		.stabn	162,0,0,0
92
  86               		.stabs	"CamInt_resetCam:F(0,15)",36,0,226,CamInt_resetCam
92
  86               		.stabs	"CamInt_resetCam:F(0,15)",36,0,225,CamInt_resetCam
93
  87               	.global	CamInt_resetCam
93
  87               	.global	CamInt_resetCam
94
  88               		.type	CamInt_resetCam, @function
94
  88               		.type	CamInt_resetCam, @function
95
  89               	CamInt_resetCam:
95
  89               	CamInt_resetCam:
96
  90               		.stabd	46,0,0
96
  90               		.stabd	46,0,0
97
   1:CamInterface.c **** /*
97
   1:CamInterface.c **** /*
Line 116... Line 116...
116
  20:CamInterface.c ****    For more information on the AVRcam, please contact:
116
  20:CamInterface.c ****    For more information on the AVRcam, please contact:
117
  21:CamInterface.c **** 
117
  21:CamInterface.c **** 
118
  22:CamInterface.c ****    john@jrobot.net
118
  22:CamInterface.c ****    john@jrobot.net
119
  23:CamInterface.c **** 
119
  23:CamInterface.c **** 
120
  24:CamInterface.c ****    or go to www.jrobot.net for more details regarding the system.
120
  24:CamInterface.c ****    or go to www.jrobot.net for more details regarding the system.
121
GAS LISTING /tmp/ccAE2QZt.s 			page 3
121
GAS LISTING /tmp/ccQQINeY.s 			page 3
122
 
122
 
123
 
123
 
124
  25:CamInterface.c **** */
124
  25:CamInterface.c **** */
125
  26:CamInterface.c **** /***********************************************************
125
  26:CamInterface.c **** /***********************************************************
126
  27:CamInterface.c **** 	Module Name: CamInterface.c
126
  27:CamInterface.c **** 	Module Name: CamInterface.c
Line 146... Line 146...
146
  47:CamInterface.c ****                            nothing is clocking timer1 at startup.                             
146
  47:CamInterface.c ****                            nothing is clocking timer1 at startup.                             
147
  48:CamInterface.c **** ***********************************************************/
147
  48:CamInterface.c **** ***********************************************************/
148
  49:CamInterface.c **** 
148
  49:CamInterface.c **** 
149
  50:CamInterface.c **** /*	Includes */
149
  50:CamInterface.c **** /*	Includes */
150
  51:CamInterface.c **** #include <avr/interrupt.h>
150
  51:CamInterface.c **** #include <avr/interrupt.h>
151
  52:CamInterface.c **** #include <avr/signal.h>
151
  52:CamInterface.c **** #include <avr/sleep.h>
152
  53:CamInterface.c **** #include <avr/sleep.h>
152
  53:CamInterface.c **** #include <avr/eeprom.h>
153
  54:CamInterface.c **** #include <avr/eeprom.h>
153
  54:CamInterface.c **** #include <stdlib.h>
154
  55:CamInterface.c **** #include <stdlib.h>
154
  55:CamInterface.c **** #include <string.h>
155
  56:CamInterface.c **** #include <string.h>
155
  56:CamInterface.c **** #include "CommonDefs.h"
156
  57:CamInterface.c **** #include "CommonDefs.h"
156
  57:CamInterface.c **** #include "CamInterface.h"
157
  58:CamInterface.c **** #include "CamInterface.h"
157
  58:CamInterface.c **** #include "Utility.h"
158
  59:CamInterface.c **** #include "Utility.h"
158
  59:CamInterface.c **** #include "UIMgr.h"
159
  60:CamInterface.c **** #include "UIMgr.h"
159
  60:CamInterface.c **** #include "Executive.h"
160
  61:CamInterface.c **** #include "Executive.h"
160
  61:CamInterface.c **** #include "UartInterface.h"
161
  62:CamInterface.c **** #include "UartInterface.h"
161
  62:CamInterface.c **** 
162
  63:CamInterface.c **** 
162
  63:CamInterface.c **** /*  Local Variables */
163
  64:CamInterface.c **** /*  Local Variables */
163
  64:CamInterface.c **** 
164
  65:CamInterface.c **** 
164
  65:CamInterface.c **** /* 	Local Structures and Typedefs */
165
  66:CamInterface.c **** /* 	Local Structures and Typedefs */
165
  66:CamInterface.c **** 
166
  67:CamInterface.c **** 
166
  67:CamInterface.c **** /*  Definitions */
167
  68:CamInterface.c **** /*  Definitions */
167
  68:CamInterface.c **** //#define OUTPUT_INITIAL_COLOR_MAP 1
168
  69:CamInterface.c **** //#define OUTPUT_INITIAL_COLOR_MAP 1
168
  69:CamInterface.c **** 
169
  70:CamInterface.c **** 
169
  70:CamInterface.c **** #define FAST_ACQUIRE 1
170
  71:CamInterface.c **** #define FAST_ACQUIRE 1
170
  71:CamInterface.c **** #define CAM_G_BUS          	PINB
171
  72:CamInterface.c **** #define CAM_G_BUS          	PINB
171
  72:CamInterface.c **** #define CAM_G_BUS_DIR      	DDRB
172
  73:CamInterface.c **** #define CAM_G_BUS_DIR      	DDRB
172
  73:CamInterface.c **** #define CAM_RB_BUS          PINC
173
  74:CamInterface.c **** #define CAM_RB_BUS          PINC
173
  74:CamInterface.c **** #define CAM_RB_BUS_DIR 		DDRC
174
  75:CamInterface.c **** #define CAM_RB_BUS_DIR 		DDRC
174
  75:CamInterface.c **** 
175
  76:CamInterface.c **** 
175
  76:CamInterface.c **** #define CAM_CONTROL_PORT     PORTD
176
  77:CamInterface.c **** #define CAM_CONTROL_PORT     PORTD
176
  77:CamInterface.c **** #define CAM_CONTROL_PORT_DIR DDRD
177
  78:CamInterface.c **** #define CAM_CONTROL_PORT_DIR DDRD
177
  78:CamInterface.c **** #define CAM_RESET_LINE       BIT7
178
  79:CamInterface.c **** #define CAM_RESET_LINE       BIT7
178
  79:CamInterface.c **** #define CAM_PIXEL_CLK_COUNT  BIT5
179
  80:CamInterface.c **** #define CAM_PIXEL_CLK_COUNT  BIT5
179
  80:CamInterface.c **** #define CAM_HREF             BIT4
180
  81:CamInterface.c **** #define CAM_HREF             BIT4
180
  81:CamInterface.c **** #define CAM_PIXEL_CLK_INT    BIT3
181
GAS LISTING /tmp/ccAE2QZt.s 			page 4
181
GAS LISTING /tmp/ccQQINeY.s 			page 4
182
 
182
 
183
 
183
 
184
  82:CamInterface.c **** #define CAM_PIXEL_CLK_INT    BIT3
184
  82:CamInterface.c **** #define CAM_VSYNC            BIT2
185
  83:CamInterface.c **** #define CAM_VSYNC            BIT2
185
  83:CamInterface.c **** 
186
  84:CamInterface.c **** 
186
  84:CamInterface.c **** /*  Global Variables */
187
  85:CamInterface.c **** /*  Global Variables */
187
  85:CamInterface.c **** /* NOTE: This file MUST appear first in the Makefile for these variables to
188
  86:CamInterface.c **** /* NOTE: This file MUST appear first in the Makefile for these variables to
188
  86:CamInterface.c **** be placed properly in RAM */
189
  87:CamInterface.c **** be placed properly in RAM */
189
  87:CamInterface.c **** 
190
  88:CamInterface.c **** 
190
  88:CamInterface.c **** /* The colorMap[] table provides the membership lookup table to convert 
191
  89:CamInterface.c **** /* The colorMap[] table provides the membership lookup table to convert 
191
  89:CamInterface.c **** RGB or YUV pixel values into actual colors.  The membership table contains
192
  90:CamInterface.c **** RGB or YUV pixel values into actual colors.  The membership table contains
192
  90:CamInterface.c **** 16 elements for each color channel, concatenated together.  The Red (or Y)
193
  91:CamInterface.c **** 16 elements for each color channel, concatenated together.  The Red (or Y)
193
  91:CamInterface.c **** value is located in the first 16 bytes, the G (or U) value is located in
194
  92:CamInterface.c **** value is located in the first 16 bytes, the G (or U) value is located in
194
  92:CamInterface.c **** the second 16 bytes, and the B (or V) value is located in the last 16 bytes:
195
  93:CamInterface.c **** the second 16 bytes, and the B (or V) value is located in the last 16 bytes:
195
  93:CamInterface.c **** 
196
  94:CamInterface.c **** 
196
  94:CamInterface.c ****     ----------------------------------------------------------------------------------
197
  95:CamInterface.c ****     ----------------------------------------------------------------------------------
197
  95:CamInterface.c ****     |red0|red1|red2|...|red15|green0|green1|green2|...|green15|blue0|blue1|...|blue15|
198
  96:CamInterface.c ****     |red0|red1|red2|...|red15|green0|green1|green2|...|green15|blue0|blue1|...|blue15|
198
  96:CamInterface.c **** mem:|0x00 0x01 0x02     0x15   0x16   0x17   0x18       0x31   0x32  0x33       0x47 |
199
  97:CamInterface.c **** mem:|0x00 0x01 0x02     0x15   0x16   0x17   0x18       0x31   0x32  0x33       0x47 |
199
  97:CamInterface.c ****     ---------------------------------------------------------------------------------
200
  98:CamInterface.c ****     ---------------------------------------------------------------------------------
200
  98:CamInterface.c **** Thus, the red lookup is accessed at colorMap+0, the green lookup is accessed 
201
  99:CamInterface.c **** Thus, the red lookup is accessed at colorMap+0, the green lookup is accessed 
201
  99:CamInterface.c **** at colorMap+16, and the blue lookup is accessed at colorMap+32.  */	
202
 100:CamInterface.c **** at colorMap+16, and the blue lookup is accessed at colorMap+32.  */	
202
 100:CamInterface.c **** unsigned char colorMap[NUM_ELEMENTS_IN_COLOR_MAP] __attribute__ ((section (".noinit")));
203
 101:CamInterface.c **** unsigned char colorMap[NUM_ELEMENTS_IN_COLOR_MAP] __attribute__ ((section (".noinit")));
203
 101:CamInterface.c **** 
204
 102:CamInterface.c **** 
204
 102:CamInterface.c **** /*  Extern Variables */
205
 103:CamInterface.c **** /*  Extern Variables */
205
 103:CamInterface.c **** /* These two buffers hold the current and previous lines
206
 104:CamInterface.c **** /* These two buffers hold the current and previous lines
206
 104:CamInterface.c **** of pixel data.  They are sized to the worst case scenario,
207
 105:CamInterface.c **** of pixel data.  They are sized to the worst case scenario,
207
 105:CamInterface.c **** where the color changes between every pixel (unrealistic).
208
 106:CamInterface.c **** where the color changes between every pixel (unrealistic).
208
 106:CamInterface.c **** The format of each buffer is for all the even bytes to hold
209
 107:CamInterface.c **** The format of each buffer is for all the even bytes to hold
209
 107:CamInterface.c **** the run-length, and the odd bytes to hold the color data. */
210
 108:CamInterface.c **** the run-length, and the odd bytes to hold the color data. */
210
 108:CamInterface.c **** 
211
 109:CamInterface.c **** 
211
 109:CamInterface.c **** /* In addition, if we are in frameDump mode, we use these buffers
212
 110:CamInterface.c **** /* In addition, if we are in frameDump mode, we use these buffers
212
 110:CamInterface.c **** to store the acquired line data...we are actually grabbing ALL of the
213
 111:CamInterface.c **** to store the acquired line data...we are actually grabbing ALL of the
213
 111:CamInterface.c **** pixels in a line (176) instead of the 88 we get normally during tracking.
214
 112:CamInterface.c **** pixels in a line (176) instead of the 88 we get normally during tracking.
214
 112:CamInterface.c **** But since we have enough to hold 88-RLE blocks, we already have the 176
215
 113:CamInterface.c **** But since we have enough to hold 88-RLE blocks, we already have the 176
215
 113:CamInterface.c **** allocated for this... */
216
 114:CamInterface.c **** allocated for this... */
216
 114:CamInterface.c **** unsigned char currentLineBuffer[LENGTH_OF_LINE_BUFFER];
217
 115:CamInterface.c **** unsigned char currentLineBuffer[LENGTH_OF_LINE_BUFFER];
217
 115:CamInterface.c **** unsigned char previousLineBuffer[LENGTH_OF_LINE_BUFFER];
218
 116:CamInterface.c **** unsigned char previousLineBuffer[LENGTH_OF_LINE_BUFFER];
218
 116:CamInterface.c **** 
219
 117:CamInterface.c **** 
219
 117:CamInterface.c **** /*  Extern Functions */
220
 118:CamInterface.c **** /*  Extern Functions */
220
 118:CamInterface.c **** /* These functions are located in assembly files, and thus
221
 119:CamInterface.c **** /* These functions are located in assembly files, and thus
221
 119:CamInterface.c **** must be externed here so they can be referenced in the source below. */
222
 120:CamInterface.c **** must be externed here so they can be referenced in the source below. */
222
 120:CamInterface.c **** extern void CamIntAsm_waitForNewTrackingFrame(unsigned char *pBuffer, unsigned char *pMemLookup);
223
 121:CamInterface.c **** extern void CamIntAsm_waitForNewTrackingFrame(unsigned char *pBuffer, unsigned char *pMemLookup);
223
 121:CamInterface.c **** extern void CamIntAsm_waitForNewDumpFrame(unsigned char *pCurrBuffer, unsigned char *pPrevBuffer);
224
 122:CamInterface.c **** extern void CamIntAsm_waitForNewDumpFrame(unsigned char *pCurrBuffer, unsigned char *pPrevBuffer);
224
 122:CamInterface.c **** extern void CamIntAsm_acquireTrackingLine(unsigned char *pBuffer, unsigned char *pMemLookup);
225
 123:CamInterface.c **** extern void CamIntAsm_acquireTrackingLine(unsigned char *pBuffer, unsigned char *pMemLookup);
225
 123:CamInterface.c **** extern void CamIntAsm_acquireDumpLine(unsigned char *pCurrBuffer, unsigned char *pPrevBuffer);
226
 124:CamInterface.c **** extern void CamIntAsm_acquireDumpLine(unsigned char *pCurrBuffer, unsigned char *pPrevBuffer);
226
 124:CamInterface.c **** 
227
 125:CamInterface.c **** 
227
 125:CamInterface.c **** /***********************************************************
228
 126:CamInterface.c **** /***********************************************************
228
 126:CamInterface.c **** 	Function Name: CamInt_init
229
 127:CamInterface.c **** 	Function Name: CamInt_init
229
 127:CamInterface.c **** 	Function Description: This function is responsible
230
 128:CamInterface.c **** 	Function Description: This function is responsible
230
 128:CamInterface.c **** 	for initializing the camera interface.  This includes
231
 129:CamInterface.c **** 	for initializing the camera interface.  This includes
231
 129:CamInterface.c **** 	setting up the i/o ports that are used to read the
232
 130:CamInterface.c **** 	setting up the i/o ports that are used to read the
232
 130:CamInterface.c **** 	camera busses, as well as resetting the camera.
233
 131:CamInterface.c **** 	camera busses, as well as resetting the camera.
233
 131:CamInterface.c **** 	Inputs:  none
234
 132:CamInterface.c **** 	Inputs:  none
234
 132:CamInterface.c **** 	Outputs: none
235
 133:CamInterface.c **** 	Outputs: none
235
 133:CamInterface.c **** ***********************************************************/	
236
 134:CamInterface.c **** ***********************************************************/	
236
 134:CamInterface.c **** void CamInt_init(void)
237
 135:CamInterface.c **** void CamInt_init(void)
237
 135:CamInterface.c **** {
238
 136:CamInterface.c **** {
238
 136:CamInterface.c **** #if OUTPUT_INITIAL_COLOR_MAP
239
 137:CamInterface.c **** #if OUTPUT_INITIAL_COLOR_MAP
239
 137:CamInterface.c **** 	unsigned char asciiBuffer[5];
240
 138:CamInterface.c **** 	unsigned char asciiBuffer[5];
240
 138:CamInterface.c ****     unsigned char i;
241
GAS LISTING /tmp/ccAE2QZt.s 			page 5
241
GAS LISTING /tmp/ccQQINeY.s 			page 5
242
 
242
 
243
 
243
 
244
 139:CamInterface.c ****     unsigned char i;
244
 139:CamInterface.c **** #endif    
245
 140:CamInterface.c **** #endif    
245
 140:CamInterface.c ****     
246
 141:CamInterface.c ****     
246
 141:CamInterface.c **** 	/* set up the mega8 ports that will be interfacing
247
 142:CamInterface.c **** 	/* set up the mega8 ports that will be interfacing
247
 142:CamInterface.c **** 	with the camera */	
248
 143:CamInterface.c **** 	with the camera */	
248
 143:CamInterface.c **** 	CAM_CONTROL_PORT_DIR |= (1<<CAM_RESET_LINE); /* cam reset is output */
249
 144:CamInterface.c **** 	CAM_CONTROL_PORT_DIR |= (1<<CAM_RESET_LINE); /* cam reset is output */
249
 144:CamInterface.c **** 	CAM_CONTROL_PORT_DIR |= 0x80;   /* set just the MSB as an output */
250
 145:CamInterface.c **** 	CAM_CONTROL_PORT_DIR |= 0x80;   /* set just the MSB as an output */
250
 145:CamInterface.c **** 	CAM_CONTROL_PORT_DIR &= 0xFB;   /* make sure bit2 is clear (input) */
251
 146:CamInterface.c **** 	CAM_CONTROL_PORT_DIR &= 0xFB;   /* make sure bit2 is clear (input) */
251
 146:CamInterface.c **** 	CAM_CONTROL_PORT &= 0x7F;   /* set reset line low */
252
 147:CamInterface.c **** 	CAM_CONTROL_PORT &= 0x7F;   /* set reset line low */
252
 147:CamInterface.c **** 	CAM_G_BUS_DIR &= 0xF0;  /* 4-bit G bus all inputs */
253
 148:CamInterface.c **** 	CAM_G_BUS_DIR &= 0xF0;  /* 4-bit G bus all inputs */
253
 148:CamInterface.c ****     CAM_G_BUS_DIR |= 0xF0;  /* disable the pull-up on PB4 and PB5 */
254
 149:CamInterface.c ****     CAM_G_BUS_DIR |= 0xF0;  /* disable the pull-up on PB4 and PB5 */
254
 149:CamInterface.c **** 	CAM_RB_BUS_DIR &= 0xF0;  /* 4-bit RB bus all inputs */
255
 150:CamInterface.c **** 	CAM_RB_BUS_DIR &= 0xF0;  /* 4-bit RB bus all inputs */
255
 150:CamInterface.c **** 	
256
 151:CamInterface.c **** 	
256
 151:CamInterface.c ****     /* ensure that timer1 is disabled to start...eventually, when PCLK needs
257
 152:CamInterface.c ****     /* ensure that timer1 is disabled to start...eventually, when PCLK needs
257
 152:CamInterface.c ****     to feed timer1 through the external counter, it will be enabled on an
258
 153:CamInterface.c ****     to feed timer1 through the external counter, it will be enabled on an
258
 153:CamInterface.c ****     "as needed" basis...*/
259
 154:CamInterface.c ****     "as needed" basis...*/
259
 154:CamInterface.c **** 	TCCR1B &= ~( (1<<CS12)|(1<<CS11)|(1<<CS10) );
260
 155:CamInterface.c **** 	TCCR1B &= ~( (1<<CS12)|(1<<CS11)|(1<<CS10) );
260
 155:CamInterface.c **** 	
261
 156:CamInterface.c **** 	
261
 156:CamInterface.c **** 	/* we'll turn on the interrupt after we assign the initial TCNT value */
262
 157:CamInterface.c **** 	/* we'll turn on the interrupt after we assign the initial TCNT value */
262
 157:CamInterface.c **** 	
263
 158:CamInterface.c **** 	
263
 158:CamInterface.c **** 	/* set up External Interrupt1 to interrupt us on rising edges (HREF)...
264
 159:CamInterface.c **** 	/* set up External Interrupt1 to interrupt us on rising edges (HREF)...
264
 159:CamInterface.c **** 	this is needed to indicate when the first pixel of each line is about to start, so
265
 160:CamInterface.c **** 	this is needed to indicate when the first pixel of each line is about to start, so
265
 160:CamInterface.c **** 	we can synch up with it...this interrupt will be disabled once HREF goes high */
266
 161:CamInterface.c **** 	we can synch up with it...this interrupt will be disabled once HREF goes high */
266
 161:CamInterface.c **** 	
267
 162:CamInterface.c **** 	
267
 162:CamInterface.c **** 	MCUCR |= (1<<ISC11) | (1<<ISC10);  /* rising edge interrupt */
268
 163:CamInterface.c **** 	MCUCR |= (1<<ISC11) | (1<<ISC10);  /* rising edge interrupt */
268
 163:CamInterface.c **** 	/* the interrupt will be enabled when we are ready to detect the rising edge of
269
 164:CamInterface.c **** 	/* the interrupt will be enabled when we are ready to detect the rising edge of
269
 164:CamInterface.c **** 	HREF...its now primed and ready to go */
270
 165:CamInterface.c **** 	HREF...its now primed and ready to go */
270
 165:CamInterface.c **** 	
271
 166:CamInterface.c **** 	
271
 166:CamInterface.c **** 	/* set up External Interrupt0 to interrupt us on rising edges (VSYNC) */
272
 167:CamInterface.c **** 	/* set up External Interrupt0 to interrupt us on rising edges (VSYNC) */
272
 167:CamInterface.c **** 	MCUCR |= (1<<ISC01) | (1<<ISC00);	/* rising edge interrupt */ 
273
 168:CamInterface.c **** 	MCUCR |= (1<<ISC01) | (1<<ISC00);	/* rising edge interrupt */ 
273
 168:CamInterface.c **** 	GICR  |= (1<<INT0);    /* interrupt request enabled */
274
 169:CamInterface.c **** 	GICR  |= (1<<INT0);    /* interrupt request enabled */
274
 169:CamInterface.c **** 	
275
 170:CamInterface.c **** 	
275
 170:CamInterface.c **** 	/* set up TimerO to count and be clocked from an external pulse source
276
 171:CamInterface.c **** 	/* set up TimerO to count and be clocked from an external pulse source
276
 171:CamInterface.c **** 	(HREF) on falling edges...eventually, we need to enable the interrupt
277
 172:CamInterface.c **** 	(HREF) on falling edges...eventually, we need to enable the interrupt
277
 172:CamInterface.c **** 	for this!  FIX THIS */
278
 173:CamInterface.c **** 	for this!  FIX THIS */
278
 173:CamInterface.c **** 	TCCR0 = (1<<CS02)|(1<<CS01)|(0<<CS00);
279
 174:CamInterface.c **** 	TCCR0 = (1<<CS02)|(1<<CS01)|(0<<CS00);
279
 174:CamInterface.c **** 	
280
 175:CamInterface.c **** 	
280
 175:CamInterface.c **** 	/* setting up the PCLK counter with Timer1 will be done right after
281
 176:CamInterface.c **** 	/* setting up the PCLK counter with Timer1 will be done right after
281
 176:CamInterface.c **** 	we start receiving pixels in each line...we sacrifice the first pixel
282
 177:CamInterface.c **** 	we start receiving pixels in each line...we sacrifice the first pixel
282
 177:CamInterface.c **** 	in each line, but we'll account for it...*/
283
 178:CamInterface.c **** 	in each line, but we'll account for it...*/
283
 178:CamInterface.c **** 	
284
 179:CamInterface.c **** 	
284
 179:CamInterface.c **** 	/* set up the mega8 so that its sleep mode puts it in an IDLE sleep
285
 180:CamInterface.c **** 	/* set up the mega8 so that its sleep mode puts it in an IDLE sleep
285
 180:CamInterface.c **** 	mode, where it can wake up as fast as possible */
286
 181:CamInterface.c **** 	mode, where it can wake up as fast as possible */
286
 181:CamInterface.c **** 	set_sleep_mode(SLEEP_MODE_IDLE);
287
 182:CamInterface.c **** 	set_sleep_mode(SLEEP_MODE_IDLE);
287
 182:CamInterface.c **** 	/* umm....we need to actually enable the sleep mode...*/
288
 183:CamInterface.c **** 	/* umm....we need to actually enable the sleep mode...*/
288
 183:CamInterface.c **** 	MCUCR |= 0x80;
289
 184:CamInterface.c **** 	MCUCR |= 0x80;
289
 184:CamInterface.c **** 	
290
 185:CamInterface.c **** 	
290
 185:CamInterface.c **** 	/* initialize the memLookup table */
291
 186:CamInterface.c **** 	/* initialize the memLookup table */
291
 186:CamInterface.c **** 	memset(colorMap,0x00,NUM_ELEMENTS_IN_COLOR_MAP);   
292
 187:CamInterface.c **** 	memset(colorMap,0x00,NUM_ELEMENTS_IN_COLOR_MAP);   
292
 187:CamInterface.c **** 	
293
 188:CamInterface.c **** 	
293
 188:CamInterface.c **** 	/* read the color map out of EEPROM */
294
 189:CamInterface.c **** 	/* read the color map out of EEPROM */
294
 189:CamInterface.c **** 	eeprom_read_block(colorMap, (unsigned char*)0x01,NUM_ELEMENTS_IN_COLOR_MAP);
295
 190:CamInterface.c **** 	eeprom_read_block(colorMap, (unsigned char*)0x01,NUM_ELEMENTS_IN_COLOR_MAP);
295
 190:CamInterface.c **** 
296
 191:CamInterface.c **** 
296
 191:CamInterface.c **** #if OUTPUT_INITIAL_COLOR_MAP    
297
 192:CamInterface.c **** #if OUTPUT_INITIAL_COLOR_MAP    
297
 192:CamInterface.c ****     UIMgr_txBuffer("\r\n",2);
298
 193:CamInterface.c ****     UIMgr_txBuffer("\r\n",2);
298
 193:CamInterface.c ****     for (i=0; i<NUM_ELEMENTS_IN_COLOR_MAP; i++)
299
 194:CamInterface.c ****     for (i=0; i<NUM_ELEMENTS_IN_COLOR_MAP; i++)
299
 194:CamInterface.c **** 	{
300
 195:CamInterface.c **** 	{
300
 195:CamInterface.c **** 		memset(asciiBuffer,0x00,5);
301
GAS LISTING /tmp/ccAE2QZt.s 			page 6
301
GAS LISTING /tmp/ccQQINeY.s 			page 6
302
 
302
 
303
 
303
 
304
 196:CamInterface.c **** 		memset(asciiBuffer,0x00,5);
304
 196:CamInterface.c **** 		itoa(colorMap[i],asciiBuffer,10);
305
 197:CamInterface.c **** 		itoa(colorMap[i],asciiBuffer,10);
305
 197:CamInterface.c **** 		UIMgr_txBuffer(asciiBuffer,3);
306
 198:CamInterface.c **** 		UIMgr_txBuffer(asciiBuffer,3);
306
 198:CamInterface.c **** 		UIMgr_txBuffer(" ",1);
307
 199:CamInterface.c **** 		UIMgr_txBuffer(" ",1);
307
 199:CamInterface.c **** 		if (i==15 || i == 31)
308
 200:CamInterface.c **** 		if (i==15 || i == 31)
308
 200:CamInterface.c **** 		{
309
 201:CamInterface.c **** 		{
309
 201:CamInterface.c **** 			/* break up the output */
310
 202:CamInterface.c **** 			/* break up the output */
310
 202:CamInterface.c **** 			UIMgr_txBuffer("\r\n",2);
311
 203:CamInterface.c **** 			UIMgr_txBuffer("\r\n",2);
311
 203:CamInterface.c **** 		}
312
 204:CamInterface.c **** 		}
312
 204:CamInterface.c **** 	}
313
 205:CamInterface.c **** 	}
313
 205:CamInterface.c **** #endif    
314
 206:CamInterface.c **** #endif    
314
 206:CamInterface.c **** 
315
 207:CamInterface.c **** 
315
 207:CamInterface.c **** #ifndef NO_CRYSTAL
316
 208:CamInterface.c **** #ifndef NO_CRYSTAL
316
 208:CamInterface.c **** 	CamInt_resetCam();	
317
 209:CamInterface.c **** 	CamInt_resetCam();	
317
 209:CamInterface.c **** #endif    
318
 210:CamInterface.c **** #endif    
318
 210:CamInterface.c **** }
319
 211:CamInterface.c **** }
319
 211:CamInterface.c **** 
320
 212:CamInterface.c **** 
320
 212:CamInterface.c **** /***********************************************************
321
 213:CamInterface.c **** /***********************************************************
321
 213:CamInterface.c **** 	Function Name: CamInt_resetCam
322
 214:CamInterface.c **** 	Function Name: CamInt_resetCam
322
 214:CamInterface.c **** 	Function Description: This function is responsible
323
 215:CamInterface.c **** 	Function Description: This function is responsible
323
 215:CamInterface.c **** 	for resetting the camera.  This is accomplished by
324
 216:CamInterface.c **** 	for resetting the camera.  This is accomplished by
324
 216:CamInterface.c **** 	toggling the reset line on the OV6620 for ~100 mS.
325
 217:CamInterface.c **** 	toggling the reset line on the OV6620 for ~100 mS.
325
 217:CamInterface.c **** 	Inputs:  none
326
 218:CamInterface.c **** 	Inputs:  none
326
 218:CamInterface.c **** 	Outputs: none
327
 219:CamInterface.c **** 	Outputs: none
327
 219:CamInterface.c ****     IMPORTANT NOTE: This function has effectively been removed
328
 220:CamInterface.c ****     IMPORTANT NOTE: This function has effectively been removed
328
 220:CamInterface.c ****     since resetting the camera now causes the camera to not
329
 221:CamInterface.c ****     since resetting the camera now causes the camera to not
329
 221:CamInterface.c ****     output the clock signal.  Thus, if we reset the cam, the
330
 222:CamInterface.c ****     output the clock signal.  Thus, if we reset the cam, the
330
 222:CamInterface.c ****     AVR has no clock, and thus doesn't run...
331
 223:CamInterface.c ****     AVR has no clock, and thus doesn't run...
331
 223:CamInterface.c **** ***********************************************************/	
332
 224:CamInterface.c **** ***********************************************************/	
332
 224:CamInterface.c **** void CamInt_resetCam(void)
333
 225:CamInterface.c **** void CamInt_resetCam(void)
333
 225:CamInterface.c **** {
334
 226:CamInterface.c **** {
334
  91               		.stabn	68,0,225,.LM0-CamInt_resetCam
335
  91               		.stabn	68,0,226,.LM0-CamInt_resetCam
-
 
336
  92               	.LM0:
335
  92               	.LM0:
337
  93               	/* prologue: frame size=0 */
336
  93               	/* prologue: frame size=0 */
338
  94               	/* prologue end (size=0) */
337
  94               	/* prologue end (size=0) */
339
  95               	/* epilogue: frame size=0 */
338
  95               	/* epilogue: frame size=0 */
340
  96 0000 0895      		ret
339
  96 0000 0895      		ret
Line 342... Line 341...
342
  98               	/* function CamInt_resetCam size 1 (0) */
341
  98               	/* function CamInt_resetCam size 1 (0) */
343
  99               		.size	CamInt_resetCam, .-CamInt_resetCam
342
  99               		.size	CamInt_resetCam, .-CamInt_resetCam
344
 100               	.Lscope0:
343
 100               	.Lscope0:
345
 101               		.stabs	"",36,0,0,.Lscope0-CamInt_resetCam
344
 101               		.stabs	"",36,0,0,.Lscope0-CamInt_resetCam
346
 102               		.stabd	78,0,0
345
 102               		.stabd	78,0,0
347
 103               		.stabs	"CamInt_init:F(0,15)",36,0,136,CamInt_init
346
 103               		.stabs	"CamInt_init:F(0,15)",36,0,135,CamInt_init
348
 104               	.global	CamInt_init
347
 104               	.global	CamInt_init
349
 105               		.type	CamInt_init, @function
348
 105               		.type	CamInt_init, @function
350
 106               	CamInt_init:
349
 106               	CamInt_init:
351
 107               		.stabd	46,0,0
350
 107               		.stabd	46,0,0
352
 108               		.stabn	68,0,136,.LM1-CamInt_init
351
 108               		.stabn	68,0,135,.LM1-CamInt_init
353
 109               	.LM1:
352
 109               	.LM1:
354
 110               	/* prologue: frame size=0 */
353
 110               	/* prologue: frame size=0 */
355
 111               	/* prologue end (size=0) */
354
 111               	/* prologue end (size=0) */
356
 112               		.stabn	68,0,144,.LM2-CamInt_init
355
 112               		.stabn	68,0,143,.LM2-CamInt_init
357
 113               	.LM2:
356
 113               	.LM2:
358
 114 0002 8F9A      		sbi 49-0x20,7
357
 114 0002 8F9A      		sbi 49-0x20,7
359
 115               		.stabn	68,0,145,.LM3-CamInt_init
358
 115               		.stabn	68,0,144,.LM3-CamInt_init
360
 116               	.LM3:
359
 116               	.LM3:
-
 
360
 117 0004 8F9A      		sbi 49-0x20,7
361
GAS LISTING /tmp/ccAE2QZt.s 			page 7
361
GAS LISTING /tmp/ccQQINeY.s 			page 7
362
 
362
 
363
 
363
 
364
 117 0004 8F9A      		sbi 49-0x20,7
-
 
365
 118               		.stabn	68,0,146,.LM4-CamInt_init
364
 118               		.stabn	68,0,145,.LM4-CamInt_init
366
 119               	.LM4:
365
 119               	.LM4:
367
 120 0006 8A98      		cbi 49-0x20,2
366
 120 0006 8A98      		cbi 49-0x20,2
368
 121               		.stabn	68,0,147,.LM5-CamInt_init
367
 121               		.stabn	68,0,146,.LM5-CamInt_init
369
 122               	.LM5:
368
 122               	.LM5:
370
 123 0008 9798      		cbi 50-0x20,7
369
 123 0008 9798      		cbi 50-0x20,7
371
 124               		.stabn	68,0,148,.LM6-CamInt_init
370
 124               		.stabn	68,0,147,.LM6-CamInt_init
372
 125               	.LM6:
371
 125               	.LM6:
373
 126 000a 87B3      		in r24,55-0x20
372
 126 000a 87B3      		in r24,55-0x20
374
 127 000c 807F      		andi r24,lo8(-16)
373
 127 000c 807F      		andi r24,lo8(-16)
375
 128 000e 87BB      		out 55-0x20,r24
374
 128 000e 87BB      		out 55-0x20,r24
376
 129               		.stabn	68,0,149,.LM7-CamInt_init
375
 129               		.stabn	68,0,148,.LM7-CamInt_init
377
 130               	.LM7:
376
 130               	.LM7:
378
 131 0010 87B3      		in r24,55-0x20
377
 131 0010 87B3      		in r24,55-0x20
379
 132 0012 806F      		ori r24,lo8(-16)
378
 132 0012 806F      		ori r24,lo8(-16)
380
 133 0014 87BB      		out 55-0x20,r24
379
 133 0014 87BB      		out 55-0x20,r24
381
 134               		.stabn	68,0,150,.LM8-CamInt_init
380
 134               		.stabn	68,0,149,.LM8-CamInt_init
382
 135               	.LM8:
381
 135               	.LM8:
383
 136 0016 84B3      		in r24,52-0x20
382
 136 0016 84B3      		in r24,52-0x20
384
 137 0018 807F      		andi r24,lo8(-16)
383
 137 0018 807F      		andi r24,lo8(-16)
385
 138 001a 84BB      		out 52-0x20,r24
384
 138 001a 84BB      		out 52-0x20,r24
386
 139               		.stabn	68,0,155,.LM9-CamInt_init
385
 139               		.stabn	68,0,154,.LM9-CamInt_init
387
 140               	.LM9:
386
 140               	.LM9:
388
 141 001c 8EB5      		in r24,78-0x20
387
 141 001c 8EB5      		in r24,78-0x20
389
 142 001e 887F      		andi r24,lo8(-8)
388
 142 001e 887F      		andi r24,lo8(-8)
390
 143 0020 8EBD      		out 78-0x20,r24
389
 143 0020 8EBD      		out 78-0x20,r24
391
 144               		.stabn	68,0,163,.LM10-CamInt_init
390
 144               		.stabn	68,0,162,.LM10-CamInt_init
392
 145               	.LM10:
391
 145               	.LM10:
393
 146 0022 85B7      		in r24,85-0x20
392
 146 0022 85B7      		in r24,85-0x20
394
 147 0024 8C60      		ori r24,lo8(12)
393
 147 0024 8C60      		ori r24,lo8(12)
395
 148 0026 85BF      		out 85-0x20,r24
394
 148 0026 85BF      		out 85-0x20,r24
396
 149               		.stabn	68,0,168,.LM11-CamInt_init
395
 149               		.stabn	68,0,167,.LM11-CamInt_init
397
 150               	.LM11:
396
 150               	.LM11:
398
 151 0028 85B7      		in r24,85-0x20
397
 151 0028 85B7      		in r24,85-0x20
399
 152 002a 8360      		ori r24,lo8(3)
398
 152 002a 8360      		ori r24,lo8(3)
400
 153 002c 85BF      		out 85-0x20,r24
399
 153 002c 85BF      		out 85-0x20,r24
401
 154               		.stabn	68,0,169,.LM12-CamInt_init
400
 154               		.stabn	68,0,168,.LM12-CamInt_init
402
 155               	.LM12:
401
 155               	.LM12:
403
 156 002e 8BB7      		in r24,91-0x20
402
 156 002e 8BB7      		in r24,91-0x20
404
 157 0030 8064      		ori r24,lo8(64)
403
 157 0030 8064      		ori r24,lo8(64)
405
 158 0032 8BBF      		out 91-0x20,r24
404
 158 0032 8BBF      		out 91-0x20,r24
406
 159               		.stabn	68,0,174,.LM13-CamInt_init
405
 159               		.stabn	68,0,173,.LM13-CamInt_init
407
 160               	.LM13:
406
 160               	.LM13:
408
 161 0034 86E0      		ldi r24,lo8(6)
407
 161 0034 86E0      		ldi r24,lo8(6)
409
 162 0036 83BF      		out 83-0x20,r24
408
 162 0036 83BF      		out 83-0x20,r24
410
 163               		.stabn	68,0,182,.LM14-CamInt_init
409
 163               		.stabn	68,0,181,.LM14-CamInt_init
411
 164               	.LM14:
410
 164               	.LM14:
412
 165 0038 85B7      		in r24,85-0x20
411
 165 0038 85B7      		in r24,85-0x20
413
 166 003a 8F78      		andi r24,lo8(-113)
412
 166 003a 8F78      		andi r24,lo8(-113)
414
 167 003c 85BF      		out 85-0x20,r24
413
 167 003c 85BF      		out 85-0x20,r24
415
 168               		.stabn	68,0,184,.LM15-CamInt_init
414
 168               		.stabn	68,0,183,.LM15-CamInt_init
416
 169               	.LM15:
415
 169               	.LM15:
417
 170 003e 85B7      		in r24,85-0x20
416
 170 003e 85B7      		in r24,85-0x20
418
 171 0040 8068      		ori r24,lo8(-128)
417
 171 0040 8068      		ori r24,lo8(-128)
419
 172 0042 85BF      		out 85-0x20,r24
418
 172 0042 85BF      		out 85-0x20,r24
420
 173               		.stabn	68,0,187,.LM16-CamInt_init
419
 173               		.stabn	68,0,186,.LM16-CamInt_init
-
 
420
 174               	.LM16:
421
GAS LISTING /tmp/ccAE2QZt.s 			page 8
421
GAS LISTING /tmp/ccQQINeY.s 			page 8
422
 
422
 
423
 
423
 
424
 174               	.LM16:
-
 
425
 175 0044 E0E0      		ldi r30,lo8(colorMap)
424
 175 0044 E0E0      		ldi r30,lo8(colorMap)
426
 176 0046 F0E0      		ldi r31,hi8(colorMap)
425
 176 0046 F0E0      		ldi r31,hi8(colorMap)
427
 177 0048 80E3      		ldi r24,lo8(48)
426
 177 0048 80E3      		ldi r24,lo8(48)
428
 178 004a DF01      		movw r26,r30
427
 178 004a DF01      		movw r26,r30
429
 179 004c 982F      		mov r25,r24
428
 179 004c 982F      		mov r25,r24
Line 476... Line 475...
476
  39:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****      eeprom_write_word and eeprom_write_block added by Artur Lipowski 
475
  39:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****      eeprom_write_word and eeprom_write_block added by Artur Lipowski 
477
  40:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****      <LAL@pro.onet.pl>
476
  40:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****      <LAL@pro.onet.pl>
478
  41:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****      Complete rewrite using the original interface by Bjoern Haase 
477
  41:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****      Complete rewrite using the original interface by Bjoern Haase 
479
  42:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****      <bjoern.haase@de.bosch.com>. 
478
  42:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****      <bjoern.haase@de.bosch.com>. 
480
  43:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****  */
479
  43:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****  */
-
 
480
  44:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h **** 
481
GAS LISTING /tmp/ccAE2QZt.s 			page 9
481
GAS LISTING /tmp/ccQQINeY.s 			page 9
482
 
482
 
483
 
483
 
484
  44:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h **** 
-
 
485
  45:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h **** #ifndef _EEPROM_H_
484
  45:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h **** #ifndef _EEPROM_H_
486
  46:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h **** #define _EEPROM_H_ 1
485
  46:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h **** #define _EEPROM_H_ 1
487
  47:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h **** 
486
  47:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h **** 
488
  48:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h **** #define __need_size_t
487
  48:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h **** #define __need_size_t
489
  49:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h **** #include <stddef.h>
488
  49:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h **** #include <stddef.h>
Line 536... Line 535...
536
  96:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h **** 
535
  96:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h **** 
537
  97:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****     \note All of the read/write functions first make sure the EEPROM
536
  97:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****     \note All of the read/write functions first make sure the EEPROM
538
  98:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****      is ready to be accessed.  Since this may cause long delays if a
537
  98:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****      is ready to be accessed.  Since this may cause long delays if a
539
  99:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****      write operation is still pending, time-critical applications
538
  99:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****      write operation is still pending, time-critical applications
540
 100:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****      should first poll the EEPROM e. g. using eeprom_is_ready() before
539
 100:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****      should first poll the EEPROM e. g. using eeprom_is_ready() before
-
 
540
 101:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****      attempting any actual I/O.
541
GAS LISTING /tmp/ccAE2QZt.s 			page 10
541
GAS LISTING /tmp/ccQQINeY.s 			page 10
542
 
542
 
543
 
543
 
544
 101:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****      attempting any actual I/O.
-
 
545
 102:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h **** 
544
 102:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h **** 
546
 103:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****     \note This header file declares inline functions that call the
545
 103:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****     \note This header file declares inline functions that call the
547
 104:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****      assembler subroutines directly. This prevents that the compiler
546
 104:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****      assembler subroutines directly. This prevents that the compiler
548
 105:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****      generates push/pops for the call-clobbered registers. This way
547
 105:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****      generates push/pops for the call-clobbered registers. This way
549
 106:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****      also a specific calling convention could be used for the eeprom
548
 106:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****      also a specific calling convention could be used for the eeprom
Line 596... Line 595...
596
 153:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h **** /** \def EEMEM
595
 153:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h **** /** \def EEMEM
597
 154:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****     \ingroup avr_eeprom
596
 154:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****     \ingroup avr_eeprom
598
 155:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****     Attribute expression causing a variable to be allocated within the .eeprom
597
 155:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****     Attribute expression causing a variable to be allocated within the .eeprom
599
 156:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****      section.  */
598
 156:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****      section.  */
600
 157:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h **** #define EEMEM __attribute__((section(".eeprom")))
599
 157:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h **** #define EEMEM __attribute__((section(".eeprom")))
-
 
600
 158:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h **** 
601
GAS LISTING /tmp/ccAE2QZt.s 			page 11
601
GAS LISTING /tmp/ccQQINeY.s 			page 11
602
 
602
 
603
 
603
 
604
 158:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h **** 
-
 
605
 159:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h **** /** \def eeprom_is_ready
604
 159:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h **** /** \def eeprom_is_ready
606
 160:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****     \ingroup avr_eeprom
605
 160:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****     \ingroup avr_eeprom
607
 161:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****     \returns 1 if EEPROM is ready for a new read/write operation, 0 if not. */
606
 161:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****     \returns 1 if EEPROM is ready for a new read/write operation, 0 if not. */
608
 162:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h **** 
607
 162:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h **** 
609
 163:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h **** #if defined(__DOXYGEN__)
608
 163:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h **** #if defined(__DOXYGEN__)
Line 656... Line 655...
656
 210:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****        : "+x" (addr),
655
 210:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****        : "+x" (addr),
657
 211:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****          "=z" (result)
656
 211:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****          "=z" (result)
658
 212:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****        : );
657
 212:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****        : );
659
 213:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****   return result;
658
 213:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****   return result;
660
 214:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h **** }
659
 214:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h **** }
-
 
660
 215:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h **** 
661
GAS LISTING /tmp/ccAE2QZt.s 			page 12
661
GAS LISTING /tmp/ccQQINeY.s 			page 12
662
 
662
 
663
 
663
 
664
 215:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h **** 
-
 
665
 216:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h **** /** \ingroup avr_eeprom
664
 216:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h **** /** \ingroup avr_eeprom
666
 217:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****     Read a block of \c n bytes from EEPROM address \c pointer_eeprom to
665
 217:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****     Read a block of \c n bytes from EEPROM address \c pointer_eeprom to
667
 218:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****     \c pointer_ram.  For constant n <= 256 bytes a library function is used.
666
 218:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****     \c pointer_ram.  For constant n <= 256 bytes a library function is used.
668
 219:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****     For block sizes unknown at compile time or block sizes > 256 an inline
667
 219:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****     For block sizes unknown at compile time or block sizes > 256 an inline
669
 220:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****     loop is expanded. */
668
 220:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****     loop is expanded. */
Line 716... Line 715...
716
 267:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****               asm volatile (
715
 267:/usr/lib/gcc/avr/4.1.0/../../../../avr/include/avr/eeprom.h ****               asm volatile (
717
 188               		.stabn	68,0,267,.LM17-CamInt_init
716
 188               		.stabn	68,0,267,.LM17-CamInt_init
718
 189               	.LM17:
717
 189               	.LM17:
719
 190 0054 A1E0      		ldi r26,lo8(1)
718
 190 0054 A1E0      		ldi r26,lo8(1)
720
 191 0056 B0E0      		ldi r27,hi8(1)
719
 191 0056 B0E0      		ldi r27,hi8(1)
-
 
720
 192               	/* #APP */
721
GAS LISTING /tmp/ccAE2QZt.s 			page 13
721
GAS LISTING /tmp/ccQQINeY.s 			page 13
722
 
722
 
723
 
723
 
724
 192               	/* #APP */
-
 
725
 193 0058 182E      		mov __zero_reg__,r24
724
 193 0058 182E      		mov __zero_reg__,r24
726
 194 005a 00D0      		rcall __eeprom_read_block_1C1D1E
725
 194 005a 00D0      		rcall __eeprom_read_block_1C1D1E
727
 195               	/* #NOAPP */
726
 195               	/* #NOAPP */
728
 196               	.LBE8:
727
 196               	.LBE8:
729
 197               	.LBE7:
728
 197               	.LBE7:
Line 731... Line 730...
731
 199               	/* epilogue: frame size=0 */
730
 199               	/* epilogue: frame size=0 */
732
 200 005c 0895      		ret
731
 200 005c 0895      		ret
733
 201               	/* epilogue end (size=1) */
732
 201               	/* epilogue end (size=1) */
734
 202               	/* function CamInt_init size 48 (47) */
733
 202               	/* function CamInt_init size 48 (47) */
735
 203               		.size	CamInt_init, .-CamInt_init
734
 203               		.size	CamInt_init, .-CamInt_init
736
 204               		.stabs	"pointer_eeprom:r(0,16)=*(0,17)=k(0,15)",64,0,190,26
735
 204               		.stabs	"pointer_eeprom:r(0,16)=*(0,17)=k(0,15)",64,0,189,26
737
 205               		.stabs	"pointer_ram:r(0,18)=*(0,15)",64,0,190,30
736
 205               		.stabs	"pointer_ram:r(0,18)=*(0,15)",64,0,189,30
738
 206               		.stabn	192,0,0,.LBB6-CamInt_init
737
 206               		.stabn	192,0,0,.LBB6-CamInt_init
739
 207               		.stabn	224,0,0,.LBE6-CamInt_init
738
 207               		.stabn	224,0,0,.LBE6-CamInt_init
740
 208               	.Lscope1:
739
 208               	.Lscope1:
741
 209               		.stabs	"",36,0,0,.Lscope1-CamInt_init
740
 209               		.stabs	"",36,0,0,.Lscope1-CamInt_init
742
 210               		.stabd	78,0,0
741
 210               		.stabd	78,0,0
Line 750... Line 749...
750
 218 0000 0000 0000 		.skip 48,0
749
 218 0000 0000 0000 		.skip 48,0
751
 218      0000 0000 
750
 218      0000 0000 
752
 218      0000 0000 
751
 218      0000 0000 
753
 218      0000 0000 
752
 218      0000 0000 
754
 218      0000 0000 
753
 218      0000 0000 
755
 219               		.stabs	"currentLineBuffer:G(0,19)=ar(0,20)=r(0,20);0;0177777;;0;175;(0,11)",32,0,115,0
754
 219               		.stabs	"currentLineBuffer:G(0,19)=ar(0,20)=r(0,20);0;0177777;;0;175;(0,11)",32,0,114,0
756
 220               		.stabs	"previousLineBuffer:G(0,19)",32,0,116,0
755
 220               		.stabs	"previousLineBuffer:G(0,19)",32,0,115,0
757
 221               		.stabs	"colorMap:G(0,21)=ar(0,20);0;47;(0,11)",32,0,101,0
756
 221               		.stabs	"colorMap:G(0,21)=ar(0,20);0;47;(0,11)",32,0,100,0
758
 222               		.text
757
 222               		.text
759
 223               		.stabs	"",100,0,0,.Letext0
758
 223               		.stabs	"",100,0,0,.Letext0
760
 224               	.Letext0:
759
 224               	.Letext0:
761
 225               	/* File "CamInterface.c": code   49 = 0x0031 (  47), prologues   0, epilogues   2 */
760
 225               	/* File "CamInterface.c": code   49 = 0x0031 (  47), prologues   0, epilogues   2 */
762
GAS LISTING /tmp/ccAE2QZt.s 			page 14
761
GAS LISTING /tmp/ccQQINeY.s 			page 14
763
 
762
 
764
 
763
 
765
DEFINED SYMBOLS
764
DEFINED SYMBOLS
766
                            *ABS*:00000000 CamInterface.c
765
                            *ABS*:00000000 CamInterface.c
767
     /tmp/ccAE2QZt.s:3      *ABS*:0000003f __SREG__
766
     /tmp/ccQQINeY.s:3      *ABS*:0000003f __SREG__
768
     /tmp/ccAE2QZt.s:4      *ABS*:0000003e __SP_H__
767
     /tmp/ccQQINeY.s:4      *ABS*:0000003e __SP_H__
769
     /tmp/ccAE2QZt.s:5      *ABS*:0000003d __SP_L__
768
     /tmp/ccQQINeY.s:5      *ABS*:0000003d __SP_L__
770
     /tmp/ccAE2QZt.s:6      *ABS*:00000000 __tmp_reg__
769
     /tmp/ccQQINeY.s:6      *ABS*:00000000 __tmp_reg__
771
     /tmp/ccAE2QZt.s:7      *ABS*:00000001 __zero_reg__
770
     /tmp/ccQQINeY.s:7      *ABS*:00000001 __zero_reg__
772
     /tmp/ccAE2QZt.s:89     .text:00000000 CamInt_resetCam
771
     /tmp/ccQQINeY.s:89     .text:00000000 CamInt_resetCam
773
     /tmp/ccAE2QZt.s:106    .text:00000002 CamInt_init
772
     /tmp/ccQQINeY.s:106    .text:00000002 CamInt_init
774
     /tmp/ccAE2QZt.s:217    .noinit:00000000 colorMap
773
     /tmp/ccQQINeY.s:217    .noinit:00000000 colorMap
775
                            *COM*:000000b0 currentLineBuffer
774
                            *COM*:000000b0 currentLineBuffer
776
                            *COM*:000000b0 previousLineBuffer
775
                            *COM*:000000b0 previousLineBuffer
777
 
776
 
778
UNDEFINED SYMBOLS
777
UNDEFINED SYMBOLS
779
__do_copy_data
778
__do_copy_data