This repository has been archived on 2020-04-08. You can view files and clone it, but cannot push or open issues or pull requests.
Files
Indoor/sensors/imu/AccelerometerData.h
FrankE a2c9e575a2 huge commit
- worked on about everything
- grid walker using plugable modules
- wifi models
- new distributions
- worked on geometric data-structures
- added typesafe timestamps
- worked on grid-building
- added sensor-classes
- added sensor analysis (step-detection, turn-detection)
- offline data reader
- many test-cases
2016-08-29 08:18:44 +02:00

24 lines
421 B
C++

#ifndef ACCELEROMETERDATA_H
#define ACCELEROMETERDATA_H
#include <cmath>
/** data received from an accelerometer sensor */
struct AccelerometerData {
float x;
float y;
float z;
AccelerometerData() : x(0), y(0), z(0) {;}
AccelerometerData(const float x, const float y, const float z) : x(x), y(y), z(z) {;}
float magnitude() const {
return std::sqrt( x*x + y*y + z*z );
}
};
#endif // ACCELEROMETERDATA_H