Note: This page refers to a product that is retired.
Device Control

Arduino_EMBRYO_2

Control stepper motor

Allows you to control a stepper motor in a linear axis, EArduino Embryo 2

Go to repository

This library allows Arduino boards to control stepper motors to be used in the EMBRYO 2 educational modular machine. The linear axis of this machine are controlled with the stepper motor, buttons and switches. This library has two classes:

  • StepMotor class: allows us to control an individual linear axis.
  • Embryo class: allows us to control two coupled linear axis.

Attention: For the library to work the endstops must be configure as pull-down, and the forward direction must rotate the step motor clockwise and backward direction must rotate the step motor anticlockwise.

To use this library:

1#include <Arduino_Embryo_2.h>

Circuit

  • X-axis motor connections Step motor connections

  • Y-axis motor connections Step motor connections

  • Linear axis endstops Linear axis



StepMotor()
begin()
start()
startWithoutHoming()
end()
play()
pause()
homing()
ready()
prepareInterrupt()
terminateInterrupt()
moveForward()
moveBackward()
moveSteps()
moveDistance()
toStep()
toPosition()
setSpeed()
getStep()
getPosition()
readBtnForward()
readBtnBackward()
readBtnStart()
readBtnEmergencyStop()
readEndstopHome()
readEndstopFar()
setTotalSteps()
getTotalSteps()
setLength()
getLength()
checkInputs()