DCmotor rotation depends on pin switch

Dependencies:   mbed

Fork of HelloWorld by Simon Ford

Embed: (wiki syntax)

« Back to documentation index

Show/hide line numbers DCmotor.h Source File

DCmotor.h

00001 #ifndef MBED_Dcmotor_H
00002 #define MBED_Dcmotor_H
00003  
00004 #include "mbed.h"
00005  
00006 class Dcmotor {
00007 public:
00008     DigitalIn pinnm(pin);
00009     Dcmotor(PinName1 pin1,PinName2 pin2);
00010     void Dc();
00011   
00012 private:  
00013     BusOut pins(pin1,pin2);
00014 };
00015