diff options
author | jdavidberger <j.david.berger@gmail.com> | 2018-04-11 10:51:45 -0600 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-04-11 10:51:45 -0600 |
commit | 0cd7e8d9783e8cdff7be99a330b2096a0648b192 (patch) | |
tree | 09fa3f286dc20d87448220a4f7800fd0e3f04087 /src/survive_vive.c | |
parent | 7af7eec04bc03719aa6b2879fe599ff0cf43e032 (diff) | |
parent | 8469de349450efb8e71fd0735bfe2dd6d3c62063 (diff) | |
download | libsurvive-0cd7e8d9783e8cdff7be99a330b2096a0648b192.tar.gz libsurvive-0cd7e8d9783e8cdff7be99a330b2096a0648b192.tar.bz2 |
Merge pull request #123 from cnlohr/simple_api
Simple async api
Diffstat (limited to 'src/survive_vive.c')
-rwxr-xr-x | src/survive_vive.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/survive_vive.c b/src/survive_vive.c index 83bc977..0fae736 100755 --- a/src/survive_vive.c +++ b/src/survive_vive.c @@ -1233,10 +1233,10 @@ static void handle_watchman( SurviveObject * w, uint8_t * readdata ) if( ( ( type & 0xe8 ) == 0xe8 ) || doimu ) //Hmm, this looks kind of yucky... we can get e8's that are accelgyro's but, cleared by first propset. { propset |= 2; - FLT agm[9] = { 0, 0, 0, 0, 0, 0, 0, 0, 0 }; + FLT agm[9] = {0, 0, 0, 0, 0, 0, 0, 0, 0}; int j; - for( j = 0; j < 6; j++ ) - agm[j] = (int16_t)(readdata[j*2+1] | (readdata[j*2+2]<<8)); + for (j = 0; j < 6; j++) + agm[j] = (int16_t)(readdata[j * 2 + 1] | (readdata[j * 2 + 2] << 8)); calibrate_acc(w, agm); calibrate_gyro(w, agm+3); w->ctx->imuproc( w, 3, agm, (time1<<24)|(time2<<16)|readdata[0], 0 ); |