Fix dual gyro default logic
commit8abbb84a55c7f258b4b4d85cc090223ad6eefcd4
authorBruce Luckcuck <github@etracer.net>
Thu, 3 May 2018 00:06:08 +0000 (2 20:06 -0400)
committerBruce Luckcuck <github@etracer.net>
Thu, 3 May 2018 00:06:08 +0000 (2 20:06 -0400)
treeb56ba59de4a41edd9c00f02ebe5eed804b828a23
parent6d72a853dd788c032cede25ae41cbb5779966689
Fix dual gyro default logic
With the changes to add dual gyro support and the SPRACINGF7DUAL target, the defaulting logic of which gyro(s) to use was changed. The logic defaulted to using "BOTH" unless the target specifically selected a gyro.

I think this logic is backwards in that the first gyro should be selected by default unless the target specifies something different.  The previous logic would cause all of the previous dual-gyro targets to default to "BOTH" even though they have different gyro types.  This is probably not a good idea and definitely would cause an unexpected change for the users.

The SPRACINGF7DUAL target has two of the same gyro so defaulting to "BOTH" is appropriate.  So now the target specifies that both gyros should be used in this case as the default.
src/main/sensors/gyro.c
src/main/target/SPRACINGF7DUAL/target.h