Ardafruit Motor shield and Arduino Uno Compile erro - help?

Adafruit Ethernet, Motor, Proto, Wave, Datalogger, GPS Shields - etc!

Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.
Locked
User avatar
mcguyver32927
 
Posts: 6
Joined: Wed Dec 07, 2011 6:40 pm

Ardafruit Motor shield and Arduino Uno Compile erro - help?

Post by mcguyver32927 »

I get this note in red below my programming screen when trying to compile the motor program

core.a(main.cpp.o): In function `main':
C:\arduino-1.0-windows\arduino-1.0\hardware\arduino\cores\arduino/main.cpp:11: undefined reference to `setup'
C:\arduino-1.0-windows\arduino-1.0\hardware\arduino\cores\arduino/main.cpp:14: undefined reference to `loop'

Ideas, or have I not given enoght info..?

Mitch

User avatar
adafruit_support_bill
 
Posts: 88088
Joined: Sat Feb 07, 2009 10:11 am

Re: Ardafruit Motor shield and Arduino Uno Compile erro - help?

Post by adafruit_support_bill »

when trying to compile the motor program
Which example are you trying to compile?

User avatar
mcguyver32927
 
Posts: 6
Joined: Wed Dec 07, 2011 6:40 pm

Re: Ardafruit Motor shield and Arduino Uno Compile erro - help?

Post by mcguyver32927 »

Here they are. it relies upon the AFMotor.h which I believe is in the right library

https://github.com/adafruit/Adafruit-Mo ... ld-library

MItchell

User avatar
adafruit_support_bill
 
Posts: 88088
Joined: Sat Feb 07, 2009 10:11 am

Re: Ardafruit Motor shield and Arduino Uno Compile erro - help?

Post by adafruit_support_bill »

There are 5 examples in the AF_Motor library.
Which one are you trying to compile?

User avatar
mcguyver32927
 
Posts: 6
Joined: Wed Dec 07, 2011 6:40 pm

Re: Ardafruit Motor shield and Arduino Uno Compile erro - help?

Post by mcguyver32927 »

I just want to run 2 PM gearmotors with an analog joystick.

User avatar
adafruit_support_bill
 
Posts: 88088
Joined: Sat Feb 07, 2009 10:11 am

Re: Ardafruit Motor shield and Arduino Uno Compile erro - help?

Post by adafruit_support_bill »

Well, I can't answer the question about your compiler error if you don't show me the code that caused it.

User avatar
mcguyver32927
 
Posts: 6
Joined: Wed Dec 07, 2011 6:40 pm

Re: Ardafruit Motor shield and Arduino Uno Compile erro - help?

Post by mcguyver32927 »

I recently pgraded to the new version of thr Arduino environment, have you had any related problems? I was trying all the programs. I will try again with 023 ide

User avatar
adafruit_support_bill
 
Posts: 88088
Joined: Sat Feb 07, 2009 10:11 am

Re: Ardafruit Motor shield and Arduino Uno Compile erro - help?

Post by adafruit_support_bill »

The recently released Arduino 1.0 IDE has some incompatibilities with previous versions. We are currently working at updating all of our libraries to support both versions.

User avatar
pburgess
 
Posts: 4161
Joined: Sun Oct 26, 2008 2:29 am

Re: Ardafruit Motor shield and Arduino Uno Compile erro - help?

Post by pburgess »

The Adafruit-Motor-Shield-library and AccelStepper libraries presently on Github should both compile under Arduino 1.0 or 0022/0023.

If you've downloaded a more recent version of mikem's AccelStepper directly from his site, that could be an issue...it's not yet 1.0-compliant.

User avatar
mcguyver32927
 
Posts: 6
Joined: Wed Dec 07, 2011 6:40 pm

Re: Ardafruit Motor shield and Arduino Uno Compile erro - help?

Post by mcguyver32927 »

Which sketch should I be using with the IDE 023 to run 2 servos? Ultimately I need to make a gyro stabilized platform for a laser. Im starting with servos now , then going to stepper or encoded motors for more control.

User avatar
adafruit_support_bill
 
Posts: 88088
Joined: Sat Feb 07, 2009 10:11 am

Re: Ardafruit Motor shield and Arduino Uno Compile erro - help?

Post by adafruit_support_bill »

If you need to have both steppers moving at the same time, the AFMotor_MultiStepper example is the one to use. That example uses both the AF_Motor and AccelStepper libraries.

User avatar
mcguyver32927
 
Posts: 6
Joined: Wed Dec 07, 2011 6:40 pm

Re: Ardafruit Motor shield and Arduino Uno Compile erro - help?

Post by mcguyver32927 »

thanks very much. You are helping my learning curve with is not linear yet.

Locked
Please be positive and constructive with your questions and comments.

Return to “Arduino Shields from Adafruit”