diff options
author | Justin Berger <j.david.berger@gmail.com> | 2018-03-25 21:29:32 -0600 |
---|---|---|
committer | Justin Berger <j.david.berger@gmail.com> | 2018-03-25 21:29:41 -0600 |
commit | d9ecb4d321bfa04b5d67fb501be0cd9c46140775 (patch) | |
tree | 0017676a859d0da5aaa3898ebc7bac2b3c5a3615 /src/survive_sensor_activations.c | |
parent | 93ce31bf11cb22c5a09b5af04a76c7b7a6b912fd (diff) | |
download | libsurvive-d9ecb4d321bfa04b5d67fb501be0cd9c46140775.tar.gz libsurvive-d9ecb4d321bfa04b5d67fb501be0cd9c46140775.tar.bz2 |
Added tool to calculate various things about length of received pulses
Diffstat (limited to 'src/survive_sensor_activations.c')
-rw-r--r-- | src/survive_sensor_activations.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/survive_sensor_activations.c b/src/survive_sensor_activations.c index 4d1801c..e42b50e 100644 --- a/src/survive_sensor_activations.c +++ b/src/survive_sensor_activations.c @@ -21,9 +21,11 @@ void SurviveSensorActivations_add(SurviveSensorActivations *self, struct PoserDa int axis = (lightData->acode & 1); uint32_t *data_timecode = &self->timecode[lightData->sensor_id][lightData->lh][axis]; FLT *angle = &self->angles[lightData->sensor_id][lightData->lh][axis]; + uint32_t *length = &self->lengths[lightData->sensor_id][lightData->lh][axis]; *angle = lightData->angle; *data_timecode = lightData->timecode; + *length = lightData->length * 48000000; } -uint32_t SurviveSensorActivations_default_tolerance = (uint32_t)(48000000 /*mhz*/ * (16.7 * 2 /*ms*/) / 1000);
\ No newline at end of file +uint32_t SurviveSensorActivations_default_tolerance = (uint32_t)(48000000 /*mhz*/ * (16.7 * 2 /*ms*/) / 1000); |