Society of Robots - Robot Forum
Software => Software => Topic started by: junkman on April 06, 2011, 01:10:21 AM
-
i was writing a program for 50$ bot and for first time tried project builder and webbotlib 2
i got an error
../lib/opt_pcint.c:4: error: '_NUM_PCINT_PINS' undeclared here (not in a function)
i dident make this file or write any thing in it so why error?
After thinking i thought lets delete the line at which the error is and try again
(i have no idea how to do programing )
so i delete the line ' PIN_CHANGE pcCallbacks[_NUM_PCINT_PINS]; ' and build
get message
Build succeeded with 0 Warnings...
Does the project builder create some other c files (c files other than the file with main() ) which require modifying ?
i was reading some other post where the guy deleted a part of the file and then program worked
-
You may be using the ATMega8 - which doesn't have any PCINT pins at all. That could explain the issue.
Yes Project Designer ( not 'builder' ;) ) does generate other C files in the 'lib' sub folder of your project so you need to use the generated makefile or AVRStudio to build the project. I assume you are doing this anyway otherwise you would have got other errors. And your error is in 'lib/opt_pcint.h' anyway.
What devices are you using? Or better still send me your project file '*.prj'. I am assumng you've tried to use something that requires PCINT pins.
Commenting out code that causes an error may allow the program to compile - but doesn't necessarily mean that the code will work !!
-
ya i using a atmega 8
sorry i meant designer
my design was simple(2 analog in , l293d , led (default),clock(default)