Arduino automation

My setup will be including 2timing 10mins and 50mins to execute action

The first cycle will be holding the object for 50mins
Next need the arduino to control the stepper motor to turn to lift up the object and hold for 10mins then next cycle the motor lower down and hold for 50mins
This will be the whole process

Can this be code in arduino?

From the minimal description, yes the Arduino, with supporting hardware, could accomplish this.

if possible can tell me where can I get the code from or reference from?

You will find a lot of code examples in the IDE.

do you know how to change the rotation speed of the stepper?

You will find a lot of tutorials in the WWW.

what is WWW?

World Wide Web

#include <Stepper.h>

const int stepsPerRevolution = 200; // change this to fit the number of steps per revolution
// for your motor

// initialize the stepper library on pins 8 through 11:
Stepper myStepper(stepsPerRevolution, 8, 9, 10, 11);

void setup() {
// set the speed at 60 rpm:
myStepper.setSpeed(60);
// initialize the serial port:
Serial.begin(9600);
}

void loop() {
// step one revolution in one direction:
Serial.println("clockwise");
myStepper.step(stepsPerRevolution);
delay(60000);

// step one revolution in the other direction:
Serial.println("counterclockwise");
myStepper.step(-stepsPerRevolution);
delay(3000000);
}
can this applicable for my experiment above?
if I want to change the number of rotations of the motor to a specific value what should I include or just change the const int stepsPerRevolution?
as for the 2timing can I just use the delay function to perform the task?

Hi,
World Wide Web
also known as WEB,
Internet.

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.