Temporary fix for inappropriate atan_t().
This commit is contained in:
parent
2fdbc88d8c
commit
39cd83b171
@ -1,6 +1,17 @@
|
||||
#include "src/dependencies/timezone/Timezone.h"
|
||||
#include "wled.h"
|
||||
#include "wled_math.h"
|
||||
#ifndef WLED_USE_REAL_MATH
|
||||
#include "wled_math.h"
|
||||
#else
|
||||
#define sin_t sin
|
||||
#define cos_t cos
|
||||
#define tan_t tan
|
||||
#define asin_t asin
|
||||
#define acos_t acos
|
||||
#define atan_t atan
|
||||
#define fmod_t fmod
|
||||
#define floor_t floor
|
||||
#endif
|
||||
|
||||
/*
|
||||
* Acquires time from NTP server
|
||||
|
@ -64,6 +64,7 @@ float asin_t(float x) {
|
||||
#define C ((HALF_PI/2) - A - B)
|
||||
|
||||
float atan_t(float x) {
|
||||
if (x>1) return atan(x);
|
||||
float xx = x * x;
|
||||
return ((A*xx + B)*xx + C)*x;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user