Merge branch 'dev' into ui

This commit is contained in:
2020-05-11 21:59:25 +02:00
5 changed files with 212 additions and 104 deletions

View File

@@ -29,8 +29,8 @@
void calibration_calculate(float low_measured, float low_setpoint, float high_measured, float high_setpoint,
float *sens_deviation, float *sens_corrected_offset);
int calibration_acquire_data(float *mu, float *max_dev, uint32_t count);
float *calibration_acquire_data_start(uint32_t count, volatile int *flag);
int calibration_sequence_shell_cmd(shellmatta_handle_t shell);
shellmatta_retCode_t calibration_sequence_shell_cmd(shellmatta_handle_t shell, const char *arg, uint32_t len);
#endif /* __CALIBRATION_H__ */

View File

@@ -25,6 +25,7 @@
#define PUPDR_DELETE(pin) ~(0x3U << ((pin) * 2))
#define OUTPUT(pin) (0x01U << ((pin) * 2))
#define PULLUP(pin) (0x1U << ((pin)* 2))
#define PULLDOWN(pin) (0x2U << ((pin)* 2))
#define ALTFUNC(pin) ((0x2) << ((pin) * 2))
#define PINMASK(pin) ((0x3) << ((pin) * 2))
#define SETAF(PORT,PIN,AF) PORT->AFR[((PIN) < 8 ? 0 : 1)] |= (AF) << (((PIN) < 8 ? (PIN) : ((PIN) - 8)) * 4)