History

Initial values, report error.

Andrzej Kapolka committed 13 years ago

Commit 517bbe81 parent ff9e6f82 files · +10 −2Browse files

Showing the changes to interface/src/SerialInterface.cpp (1 of 2 files). Show all

Unified · Split

interface/src/SerialInterface.cpp+2−0
@@ -249,6 +249,8 @@ void SerialInterface::readData(float deltaTime) { · 248 unmodified lines
249 _angularAccelToLinearAccel * angularAcceleration;249 _angularAccelToLinearAccel * angularAcceleration;
250 glm::vec3 error = _estimatedAcceleration - predictedAcceleration;250 glm::vec3 error = _estimatedAcceleration - predictedAcceleration;
251 251
252 printLog("error %g\n", glm::length(error));
253
252 // adjust according to error in each dimension, in proportion to input magnitudes254 // adjust according to error in each dimension, in proportion to input magnitudes
253 for (int i = 0; i < 3; i++) {255 for (int i = 0; i < 3; i++) {
254 if (fabsf(error[i]) < EPSILON) {256 if (fabsf(error[i]) < EPSILON) {