AmboVent-1690-108 / AmboVent

AmboVent 1690.108
The Unlicense
206 stars 69 forks source link

Possible calibration user error #55

Open salam17 opened 4 years ago

salam17 commented 4 years ago

It appears to me that there is a plausible scenario in which there will be a divide by zero in calc_failure(), leading to unexpected results or a crash. During calibrate_arm_range(), if a user is is distracted and pushes the test button twice without moving the arm, max_arm_pos can be set to the same value as min_arm_pos. I suggest more checks before the calibrated variable is set to true.