funktionierender Regler

Dependencies:   mbed

Fork of TestRegler by Roboshark

Fahren.h

Committer:
ahlervin
Date:
2018-04-30
Revision:
7:b2a16b1cf487
Parent:
6:a4b745625dbe
Child:
8:d7dfee648545

File content as of revision 7:b2a16b1cf487:

#ifndef FAHREN_H_
#define FAHREN_H_

#include <mbed.h>
#include "EncoderCounter.h"
#include "Controller.h"
#include "Regler.h"
#include "IRSensor.h"

class Fahren{
    
    public:    
    Fahren(Controller& controller, EncoderCounter& counterLeft, EncoderCounter& counterRight); //Konstruktor
    
    virtual ~Fahren();
    
    void geradeausU();
    void geradeausG();
    void rechts90();
    void rechts180();
    void links90();
    void ziel();
    void stopp();                        
    
    
    private:
    Controller& controller;
    EncoderCounter& counterLeft;
    EncoderCounter& counterRight;
    
    //Variablen die in der Klasse Fahren verwendet werden
    double speedRight;
    double speedLeft;
    short initialClicksLeft;
    short initialClicksRight;
    short wegLinks;
    short wegRechts;
    short stopRight;
    short stopLeft;
    float SpeedR;
    float SpeedL;
    static const float PERIOD;
    Regler& regler;
    
    void getSpeed();
    Ticker ticker;
    

};
#endif