Society of Robots - Robot Forum
Software => Software => Topic started by: silo_xtreme on February 12, 2008, 06:18:17 PM
-
Hi all,
In a2d.h the compiler has a problem with line 140
//! return TRUE if conversion is complete
u08 a2dIsComplete(void);
Any ideas?
-
probably
u08 = a2dIsComplete(void);
-
not the case. it works with the makefile that comes with the $50 robot. It's a return type, i just want to use a different chip....
-
u08 = a2dIsComplete(void);
u08 means int, or 8 bit int
use this to change from $50 ATmega8 code to code for your microcontroller:
http://www.societyofrobots.com/step_by_step_atmega168_swapout.shtml
-
admin,
where / what library is u08 defined?
-
Its part of the C language, as defined by gnc :P
doing this:
u08 a2dIsComplete(void);
is the same as this:
int a2dIsComplete(void);
-
admin,
thanks! I guess the silly AVR Studio 4 doesn't know u08 ?
-
Which microcontroller are you using?
Did you change all of the code to reflect that microcontroller?
What is the exact error you are getting?
-
I've changed all the ports and timing files
I'm using the Atmega 2560 ...
I have the following error:
C:\..\..\Program Files\AVRlib/a2d.h:141: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'a2dIsComplete'
It compiles with your makefile , just not with settings in the AVR Studio ....
I wanted to try to compile it in the studio, because I'm not able to get debug values back over the JTAG interface properly....
-
Admin,
After searching I found this:
http://www.avrfreaks.net/index.php?name=PNphpBB2&file=viewtopic&t=58058
Was this you? ;) If so, did you ever get that new .h file working?
-
hmm .... really no more ideas?
-
yeap, that avrfreaks post basically highlights the solution
-
excellent. Oh, after updating AVR Studio and putting the "globals.h" header before the others - it finally works no problem.
Thanks again for all your help!