mirror of
https://github.com/espressif/esp-idf.git
synced 2026-05-19 23:45:28 +02:00
refactor(adc_calib): Simplify 2nd step coefficient calculation
- remove unnecessary variables and calculations - improve readability of code
This commit is contained in:
@@ -12,13 +12,10 @@
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#define COEFF_GROUP_NUM 4
|
||||
#define TERM_MAX 5
|
||||
|
||||
typedef struct {
|
||||
uint8_t term_num; ///< Term number of the algorithm formula
|
||||
const uint64_t (*coeff)[COEFF_GROUP_NUM][TERM_MAX][2]; ///< Coeff of each term. See `adc_error_coef_atten` for details (and the magic number 2)
|
||||
const int32_t (*sign)[COEFF_GROUP_NUM][TERM_MAX]; ///< Sign of each term
|
||||
const uint64_t (*coeff)[2]; ///< Coeff of each term. See `adc_error_coef_atten` for details (and the magic number 2)
|
||||
const int32_t (*sign); ///< Sign of each term
|
||||
} cali_chars_second_step_t;
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user