aboutsummaryrefslogtreecommitdiff
path: root/src/survive_default_devices.c
diff options
context:
space:
mode:
authorJustin Berger <j.david.berger@gmail.com>2018-03-22 12:06:41 -0600
committerJustin Berger <j.david.berger@gmail.com>2018-03-22 12:26:55 -0600
commitdcf5d7a482e022e762a656253017ebbc721d8a83 (patch)
treebeb85d67dc1a6d383186f94b674834f2f0667ba9 /src/survive_default_devices.c
parentf60bed509a7e416c155bcd35d5151bca65eaa190 (diff)
downloadlibsurvive-dcf5d7a482e022e762a656253017ebbc721d8a83.tar.gz
libsurvive-dcf5d7a482e022e762a656253017ebbc721d8a83.tar.bz2
Progress on IMU tracking
Diffstat (limited to 'src/survive_default_devices.c')
-rw-r--r--src/survive_default_devices.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/src/survive_default_devices.c b/src/survive_default_devices.c
index 6b65752..2e47b9e 100644
--- a/src/survive_default_devices.c
+++ b/src/survive_default_devices.c
@@ -144,11 +144,10 @@ int survive_load_htc_config_format(SurviveObject *so, char *ct0conf, int len) {
FLT *values = NULL;
if (parse_float_array(ct0conf, tk + 2, &values, count) > 0) {
so->acc_bias = values;
- so->acc_bias[0] *= .125; // XXX Wat? Observed by CNL. Biasing
- // by more than this seems to hose
- // things.
- so->acc_bias[1] *= .125;
- so->acc_bias[2] *= .125;
+ const FLT bias_units = 1. / 1000.; // I deeply suspect bias is in milligravities -JB
+ so->acc_bias[0] *= bias_units;
+ so->acc_bias[1] *= bias_units;
+ so->acc_bias[2] *= bias_units;
}
}
if (jsoneq(ct0conf, tk, "acc_scale") == 0) {