Eurobot: Sensor Filtering Algorithm

This week we wrote an algorithm for our ultrasonic sensors to remove some noise from the sensor. This is important because the sensors aren’t always quite accurate, so we must filter the values. In the algorithm, we have a variable “a” to adjust the graph. If we make “a” smaller the curve gets smoother, but we lose some responsiveness, and the opposite will happen if we make “a” bigger. We tested out the algorithm and found out that “a” should be around 0.3 to get the best balance between a smoother graph and the ability to quickly detect obstacles, which is very important for us. In the video, the blue graph represents the raw sensor input and the orange one represents the smoothened value.

(author: Jannis)

Schreibe einen Kommentar

Cookie Consent mit Real Cookie Banner