Re: [accelstepper] No matching constructor Error

41 views
Skip to first unread message

Mike McCauley

unread,
Nov 3, 2021, 4:49:58 PM11/3/21
to accels...@googlegroups.com
Do the examples compile for you?

Sent from my iPhone

On 4 Nov 2021, at 12:11 am, David Kreuzhuber <davidkr...@gmail.com> wrote:

Hello everybody,

I work on an project where I'm trying to controll the acceleration of a stepper.

I just tried to write a little test code, based on the bounce example.

My problem is that I get an error in the constructor saying "No matching constructor found".

#include <AccelStepper.h>
AccelStepper stepper (AccelStepper::DRIVER, 17, 16);

void setup() {
  stepper.setMaxSpeed(2000);
  stepper.setAcceleration(20);
  stepper.moveTo(2000);
}

Am I missing something here? 
I thought the constructor needs 3 arguments, the mode (Driver, 1) and the Step & Direction Pin. 
In every example I saw, it was done like this.

--
You received this message because you are subscribed to the Google Groups "accelstepper" group.
To unsubscribe from this group and stop receiving emails from it, send an email to accelstepper...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/accelstepper/cb264e1a-9580-4b3c-9c27-ec787f6cae6dn%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages