At the end of this lesson, you will be able to:
control a 28BYJ-48 DC 5V stepper motor
review Robot:Bit extension
inside this extension is "robotbit.StepperDegree(robotbit.Steppers.M1, 0)" code
there are 2 connections for these types of "continuous" turning stepper motors
M1 & M2
robotbit.StepperTurn(robotbit.Steppers.M1, robotbit.Turns.T1B0)
robotbit.StpCarMove(10, 48)Â
plug the stepper motors on the Robot:Bit
note the colors of the wires and the terminals, make sure they match!
note the number you placed the wires on (ex: M1 or M2)
click on provided link to create a new GitHub repo
call the repo: TEJ2O.1 ⇢ Unit5-08
create a program that moves the stepper motor back and forth
if need be join another student
create a program that has 2 - 28BYJ-48 DC 5V stepper motor and a distance sensor
assume that the motors are driving 2 wheels
make the wheels move forward
if there is an object within 10 cm of the distance sensor, the motors stop, the card reverses 10 cm, it then turns 90° and then continues moving forward
do the same assignment, but in Python
not sure how to do this!
Click the "A" or "B" button
remember you need to add the "RobotBit" extension