Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: mbed
Asservissement/Asservissement_v1.cpp
- Committer:
- Jagang
- Date:
- 2015-05-24
- Revision:
- 0:b127c787a51b
File content as of revision 0:b127c787a51b:
#include "Asservissement_v1.h" Asservissement_v1::Asservissement_v1(Odometry &odometry, Motor &motorL, Motor &motorR) :Asservissement(odometry,motorL,motorR) { } void Asservissement_v1::update(float dt) { if(m_odometry.getY()<1000 && m_odometry.getX()<1000) { m_motorL.setSpeed(0.2); m_motorR.setSpeed(0.2); } else { m_motorL.setSpeed(0); m_motorR.setSpeed(0); } } void Asservissement_v1::setGoal(float x, float y, float theta) { } void Asservissement_v1::setGoal(float x, float y) { } void Asservissement_v1::stop() { } bool Asservissement_v1::isArrived() { return false; } char Asservissement_v1::getState() { return m_state; }