AMS2 Motors Don’t Initialize or move

Home Forum Makelangelo Polargraph Art Robot AMS2 Motors Don’t Initialize or move

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #13443
    AvatarAnonymous
    Inactive

    Ok So I’ve downloaded the firmware and the software.
    Since I am running the Adafruit Motor Shield V2 I’ve adjust the firmware as:

    //#define MOTHERBOARD 1 // Adafruit Motor Shield 1
    #define MOTHERBOARD 2 // Adafruit Motor Shield 2

    When I verify the code after this change I get an error:

    Arduino: 1.8.3 (Windows 10), Board: “Arduino/Genuino Uno”

    Archiving built core (caching) in: C:\Users\******\AppData\Local\Temp\arduino_cache_267541\core\core_arduino_avr_uno_0c812875ac70eb4a9b385d8fb077f54c.a
    C:\Users\******\AppData\Local\Temp\ccitlfGN.ltrans1.ltrans.o: In function `setup’:

    C:\Users\******\Documents\Arduino\makelangeloFirmwareAMS/makelangeloFirmwareAMS.ino:1241: undefined reference to `Adafruit_MotorShield::begin(unsigned int)’

    C:\Users\******\Documents\Arduino\makelangeloFirmwareAMS/makelangeloFirmwareAMS.ino:1242: undefined reference to `Adafruit_MotorShield::getStepper(unsigned int, unsigned char)’

    C:\Users\******\Documents\Arduino\makelangeloFirmwareAMS/makelangeloFirmwareAMS.ino:1243: undefined reference to `Adafruit_MotorShield::getStepper(unsigned int, unsigned char)’

    C:\Users\******\AppData\Local\Temp\ccitlfGN.ltrans1.ltrans.o: In function `motor_engage’:

    C:\Users\******\Documents\Arduino\makelangeloFirmwareAMS/makelangeloFirmwareAMS.ino:918: undefined reference to `Adafruit_StepperMotor::onestep(unsigned char, unsigned char)’

    C:\Users\******\Documents\Arduino\makelangeloFirmwareAMS/makelangeloFirmwareAMS.ino:918: undefined reference to `Adafruit_StepperMotor::onestep(unsigned char, unsigned char)’

    C:\Users\******\Documents\Arduino\makelangeloFirmwareAMS/makelangeloFirmwareAMS.ino:919: undefined reference to `Adafruit_StepperMotor::onestep(unsigned char, unsigned char)’

    C:\Users\******\Documents\Arduino\makelangeloFirmwareAMS/makelangeloFirmwareAMS.ino:919: undefined reference to `Adafruit_StepperMotor::onestep(unsigned char, unsigned char)’

    C:\Users\******\AppData\Local\Temp\ccitlfGN.ltrans1.ltrans.o: In function `processCommand’:

    C:\Users\******\Documents\Arduino\makelangeloFirmwareAMS/makelangeloFirmwareAMS.ino:1145: undefined reference to `Adafruit_StepperMotor::onestep(unsigned char, unsigned char)’

    C:\Users\******\AppData\Local\Temp\ccitlfGN.ltrans1.ltrans.o:C:\Users\blackdavda\Documents\Arduino\makelangeloFirmwareAMS/makelangeloFirmwareAMS.ino:1155: more undefined references to `Adafruit_StepperMotor::onestep(unsigned char, unsigned char)’ follow

    C:\Users\******\AppData\Local\Temp\ccitlfGN.ltrans2.ltrans.o: In function `__static_initialization_and_destruction_0′:

    C:\Users\******\Documents\Arduino\makelangeloFirmwareAMS/makelangeloFirmwareAMS.ino:176: undefined reference to `Adafruit_MotorShield::Adafruit_MotorShield(unsigned char)’

    C:\Users\******\AppData\Local\Temp\ccitlfGN.ltrans0.ltrans.o: In function `motor_disengage()’:

    C:\Users\******\Documents\Arduino\makelangeloFirmwareAMS/makelangeloFirmwareAMS.ino:902: undefined reference to `Adafruit_StepperMotor::release()’

    C:\Users\******\Documents\Arduino\makelangeloFirmwareAMS/makelangeloFirmwareAMS.ino:903: undefined reference to `Adafruit_StepperMotor::release()’

    C:\Users\******\AppData\Local\Temp\ccitlfGN.ltrans0.ltrans.o: In function `line(float, float, float)’:

    C:\Users\******\Documents\Arduino\makelangeloFirmwareAMS/makelangeloFirmwareAMS.ino:440: undefined reference to `Adafruit_StepperMotor::onestep(unsigned char, unsigned char)’

    C:\Users\******\Documents\Arduino\makelangeloFirmwareAMS/makelangeloFirmwareAMS.ino:444: undefined reference to `Adafruit_StepperMotor::onestep(unsigned char, unsigned char)’

    C:\Users\******\Documents\Arduino\makelangeloFirmwareAMS/makelangeloFirmwareAMS.ino:457: undefined reference to `Adafruit_StepperMotor::onestep(unsigned char, unsigned char)’

    C:\Users\******\Documents\Arduino\makelangeloFirmwareAMS/makelangeloFirmwareAMS.ino:461: undefined reference to `Adafruit_StepperMotor::onestep(unsigned char, unsigned char)’

    C:\Users\******\AppData\Local\Temp\ccitlfGN.ltrans0.ltrans.o: In function `setFeedRate(float)’:

    C:\Users\******\Documents\Arduino\makelangeloFirmwareAMS/makelangeloFirmwareAMS.ino:298: undefined reference to `Adafruit_StepperMotor::setSpeed(unsigned int)’

    C:\Users\******\Documents\Arduino\makelangeloFirmwareAMS/makelangeloFirmwareAMS.ino:299: undefined reference to `Adafruit_StepperMotor::setSpeed(unsigned int)’

    collect2.exe: error: ld returned 1 exit status

    exit status 1
    Error compiling for board Arduino/Genuino Uno.

    This report would have more information with
    “Show verbose output during compilation”
    option enabled in File -> Preferences.

    If I don’t change the firmware and leave it as:

    #define MOTHERBOARD 1 // Adafruit Motor Shield 1
    //#define MOTHERBOARD 2 // Adafruit Motor Shield 2

    It verifies and uploads just fine. I can make a serial connection. I can launch the software file and connect as well but I cannot get the motors to initialize and thus not move… I would assume this is because its not set to MOTHERBOARD 2.

    Please Help

    #13447
    DanDan
    Keymaster

    We don’t officially support the AMS2 board. I no longer recall when or why some code was added.
    In any case, I’ll try to help.

    It looks like you’re missing the AMS2 library which the code needs to talk to the AMS2 shield. You should be able to install it with the arduino libraries manager.

    #13464
    AvatarAnonymous
    Inactive

    So simple…
    Of course that did the trick.
    Thank you.

Viewing 3 posts - 1 through 3 (of 3 total)
  • You must be logged in to reply to this topic.