Init

Dependents:   JetflyerMotorController

Motor.h

Committer:
skrickl
Date:
2017-07-13
Revision:
1:39b173360768
Parent:
0:5eb2bad9ea40

File content as of revision 1:39b173360768:

#include "mbed.h"


#ifndef MOTOR_H
#define MOTOR_H

#define pin_forward p29
#define pin_backward p30
#define pin_pwm_motor p23




class Motor
{
    public:
    Motor();
    ~Motor();
    
    DigitalOut forward;
    DigitalOut backward;
    AnalogOut  throttle;
     
    int drive(int speed, int direction);
    
    
    private:
    
    int direction_old;
  
    
};

#endif