This is the code we showed at Uncraftivism

Dependencies:   mbed

ServoMinder.h

Committer:
jarkman
Date:
2009-11-20
Revision:
0:57f4fdadc97f
Child:
1:70d90598d2e7

File content as of revision 0:57f4fdadc97f:

#pragma once
#include "Servo.h"

class ServoMinder
{
public:
	ServoMinder( Servo *servo );

	void moveTo( float target );

private:
	void setSpeed( float speed );

	Servo *m_servo;
	float m_target;
	float m_speed;

	float m_delta;
	float m_tickTime;
	Ticker m_ticker;

	void tick();

};