no matching function for call to 'Stepper ::Stepper(const int&, int, i…
페이지 정보
작성자 master 작성일18-08-14 11:26 조회7,874회 댓글0건본문
#include<Stepper.h>
const int STEPS = 200; //0.9 deg/step, 360/0.9=400//
Stepper mystepper (STEPS, 8, 9, 10);
int DirPIN=8;
int ClkPIN=9;
int EnvPIN=10;
void setup(){
mystepper.setSpeed(30); // How fast
Serial.begin(9600);
pinMode(DirPIN, OUTPUT);
pinMode(ClkPIN, OUTPUT);
pinMode(EnvPIN, OUTPUT);
digitalWrite(DirPIN,HIGH);
digitalWrite(ClkPIN,HIGH);
digitalWrite(EnvPIN,HIGH);
}
void loop(){
Serial.println("+direction");
mystepper.step(200); // 100 step = 0.5 revolution
delay(500);
Serial.println("-dirction");
mystepper.step(-200);
delay(500);
}
했는데 왜 no matching function for call to 'Stepper ::Stepper(const int&, int, int, int)' 가 뜨죠?
잘못 썼나요...
//
해당 모터는 스텝모터 라이브러리를 사용할 필요 없습니다.
댓글 : 0
조회수 : 7,874
등록된 댓글이 없습니다.