downsampled the loop rate to 1s and added "nan" error detection
calculate brake-distance and brake rate based on current speed
instead of fixed define.
some software layout changes