|
@@ -122,12 +122,12 @@ int Interaction::enter_key_listen( float* acc, float* acc_x_buff,int &station_co
|
|
|
pitch_buff[9] = pitch;
|
|
|
|
|
|
//先判断俯仰角是否正常着地,这样才能判断确认键
|
|
|
- if (pitch < 0.6f)
|
|
|
+ if (pitch < 0.4f)
|
|
|
{
|
|
|
angle_has_reset = 1;
|
|
|
}
|
|
|
|
|
|
- if (acc_is_valid(acc_x_buff, 10) && *max_element(pitch_buff, pitch_buff + 10) - *min_element(pitch_buff, pitch_buff + 10) < 0.1)
|
|
|
+ if (acc_is_valid(acc_x_buff, 10) && *max_element(pitch_buff, pitch_buff + 10) - *min_element(pitch_buff, pitch_buff + 10) < 0.1f)
|
|
|
{
|
|
|
station_count++;
|
|
|
}
|
|
@@ -137,7 +137,7 @@ int Interaction::enter_key_listen( float* acc, float* acc_x_buff,int &station_co
|
|
|
}
|
|
|
|
|
|
//x轴速度剧烈抖动,而且俯仰角大于45度,则证明是踮脚
|
|
|
- if (station_count > 10 && pitch > 0.6f && angle_has_reset == 1)
|
|
|
+ if (station_count > 10 && pitch > 0.4f && angle_has_reset == 1)
|
|
|
{
|
|
|
angle_has_reset = 0;
|
|
|
|