dc motor rotations are depending upon the pins given to mbed board

Dependencies:   mbed

Fork of HelloWorld by Simon Ford

Committer:
KIRAN_PALTANKAR
Date:
Tue Nov 29 12:58:13 2016 +0000
Revision:
2:d2ddd762da24
dc motor rotations are depending upon the pins given to mbed board

Who changed what in which revision?

UserRevisionLine numberNew contents of line
KIRAN_PALTANKAR 2:d2ddd762da24 1 #ifndef MBED_Dcmotor_H
KIRAN_PALTANKAR 2:d2ddd762da24 2 #define MBED_Dcmotor_H
KIRAN_PALTANKAR 2:d2ddd762da24 3
KIRAN_PALTANKAR 2:d2ddd762da24 4 #include "mbed.h"
KIRAN_PALTANKAR 2:d2ddd762da24 5
KIRAN_PALTANKAR 2:d2ddd762da24 6 class Dcmotor {
KIRAN_PALTANKAR 2:d2ddd762da24 7 public:
KIRAN_PALTANKAR 2:d2ddd762da24 8 DigitalIn pinnm(pin);
KIRAN_PALTANKAR 2:d2ddd762da24 9 Dcmotor(PinName1 pin1,PinName2 pin2);
KIRAN_PALTANKAR 2:d2ddd762da24 10 void Dc();
KIRAN_PALTANKAR 2:d2ddd762da24 11
KIRAN_PALTANKAR 2:d2ddd762da24 12 private:
KIRAN_PALTANKAR 2:d2ddd762da24 13 BusOut pins(pin1,pin2);
KIRAN_PALTANKAR 2:d2ddd762da24 14 };