Updated interfaces and sensors

Signed-off-by: Serban Waltter <serban.waltter@rinftech.com>
Signed-off-by: Mihai Tudor Panu <mihai.tudor.panu@intel.com>
This commit is contained in:
Serban Waltter
2018-07-26 18:04:31 +03:00
committed by Mihai Tudor Panu
parent bfdd2c37c0
commit 90524273ec
18 changed files with 44 additions and 63 deletions

View File

@ -77,7 +77,7 @@ float Rotary::rel_rad()
return Rotary::rel_deg() * M_PI / 180.0;
}
float Rotary::getValue()
float Rotary::getAngle()
{
return Rotary::abs_value();
return Rotary::abs_deg();
}

View File

@ -30,7 +30,7 @@
#include <mraa/aio.hpp>
#include "rotary.hpp"
#include <interfaces/iRotaryAngle.hpp>
#include <interfaces/iAngle.hpp>
namespace upm {
@ -60,7 +60,7 @@ namespace upm {
* @image html rotary.jpg
* @snippet rotary.cxx Interesting
*/
class Rotary : virtual public iRotaryAngle {
class Rotary : virtual public iAngle {
public:
/**
* Rotary angle sensor constructor
@ -115,7 +115,7 @@ class Rotary : virtual public iRotaryAngle {
*
* @return rotation value.
*/
virtual float getValue();
virtual float getAngle();
std::string name(){ return "Rotary Angle Sensor";}
private: