Test

Committer:
fermedicius
Date:
Mon Jan 11 10:56:36 2021 +0000
Revision:
0:5ec996c00568
Test

Who changed what in which revision?

UserRevisionLine numberNew contents of line
fermedicius 0:5ec996c00568 1 #ifndef FERMESTEPPER_H
fermedicius 0:5ec996c00568 2 #define FERMESTEPPER_H
fermedicius 0:5ec996c00568 3
fermedicius 0:5ec996c00568 4 #include "mbed.h"
fermedicius 0:5ec996c00568 5
fermedicius 0:5ec996c00568 6 class fermeMotor {
fermedicius 0:5ec996c00568 7 public:
fermedicius 0:5ec996c00568 8
fermedicius 0:5ec996c00568 9 fermeMotor(PinName A0,PinName A1, PinName A2, PinName A3, PinName B0,PinName B1, PinName B2, PinName B3); //motor constructor
fermedicius 0:5ec996c00568 10
fermedicius 0:5ec996c00568 11 void fstep(int num_stepsA, int num_stepsB, int directionA, int speed);
fermedicius 0:5ec996c00568 12 void anticlockwise(int flagA, int flagB, int motorSpeed);
fermedicius 0:5ec996c00568 13 void clockwise(int flagA, int flagB, int motorSpeed);
fermedicius 0:5ec996c00568 14
fermedicius 0:5ec996c00568 15
fermedicius 0:5ec996c00568 16 private:
fermedicius 0:5ec996c00568 17
fermedicius 0:5ec996c00568 18 DigitalOut _A0;
fermedicius 0:5ec996c00568 19 DigitalOut _A1;
fermedicius 0:5ec996c00568 20 DigitalOut _A2;
fermedicius 0:5ec996c00568 21 DigitalOut _A3;
fermedicius 0:5ec996c00568 22 DigitalOut _B0;
fermedicius 0:5ec996c00568 23 DigitalOut _B1;
fermedicius 0:5ec996c00568 24 DigitalOut _B2;
fermedicius 0:5ec996c00568 25 DigitalOut _B3;
fermedicius 0:5ec996c00568 26
fermedicius 0:5ec996c00568 27 };
fermedicius 0:5ec996c00568 28
fermedicius 0:5ec996c00568 29 #endif