Compare commits

..

No commits in common. "bb39c4b6e07720b5b1bcb319d33823d34a2bfeed" and "e37001e3c480a6ef51cd4a9af0bea709cd8cafd1" have entirely different histories.

2 changed files with 27 additions and 29 deletions

View File

@ -92,7 +92,7 @@ static float calculate_mean(float *values, uint32_t count)
} while (--loop_cnt > 0);
}
return sum / (float)count;
return sum/(float)count;
}
static float calculate_standard_deviation(float *values, uint32_t count, float mean)
@ -103,8 +103,7 @@ static float calculate_standard_deviation(float *values, uint32_t count, float m
float res;
switch (remainder) {
case 0: do {
sum += (*values - mean) * (*values - mean);
case 0: do { sum += (*values - mean) * (*values - mean);
values++;
/* FALLTHRU */
case 7: sum += (*values - mean) * (*values - mean);
@ -132,7 +131,7 @@ static float calculate_standard_deviation(float *values, uint32_t count, float m
}
sum /= (float)count;
/* Compute the square root using the FPU.
/* Compute the square roor using the FPU.
* The constraint 't' tells GCC to use a floating point register
*/
__asm__ __volatile__("vsqrt.f32 %0, %1" : "=t"(res) : "t"(sum));

View File

@ -151,8 +151,7 @@ int sd_card_settings_try_load_calibration(float *sens_deviation, float *offset)
} while (res != CONFIG_PARSER_END_REACHED &&
res != CONFIG_PARSER_GENERIC_ERR &&
res != CONFIG_PARSER_IOERR &&
res != CONFIG_PARSER_PARAM_ERR);
res != CONFIG_PARSER_IOERR);
config_parser_close_file(p);