comparison Discovery/Src/motion.c @ 618:96af74455420

Development bugfix: focus state not remembered: Somehow the static in front of the focus state has disappeared. After returning it again the focus detection is available again.
author Ideenmodellierer
date Wed, 27 Jan 2021 22:04:45 +0100
parents 916998f90e39
children 6826731ff2be
comparison
equal deleted inserted replaced
617:4eba86129d35 618:96af74455420
728 } 728 }
729 729
730 void HandleMotionDetection(void) 730 void HandleMotionDetection(void)
731 { 731 {
732 detectionState_t pitchstate = DETECT_NOTHING; 732 detectionState_t pitchstate = DETECT_NOTHING;
733 uint8_t wasInFocus = 0; 733 static uint8_t wasInFocus = 0;
734 734
735 evaluateMotionDelta(stateUsed->lifeData.compass_roll, stateUsed->lifeData.compass_pitch, stateUsed->lifeData.compass_heading); 735 evaluateMotionDelta(stateUsed->lifeData.compass_roll, stateUsed->lifeData.compass_pitch, stateUsed->lifeData.compass_heading);
736 checkViewport(stateUsed->lifeData.compass_roll, stateUsed->lifeData.compass_pitch, stateUsed->lifeData.compass_heading); 736 checkViewport(stateUsed->lifeData.compass_roll, stateUsed->lifeData.compass_pitch, stateUsed->lifeData.compass_heading);
737 737
738 if(viewInFocus()) 738 if(viewInFocus())