As the distance between the obstacle & the robot decreases, the Blue waveform decreases. In this example the Blue waveform represents the Ultrasonic sensor and the Yellow and Red waveforms represent the left and right motors.
#ARDUINO 1.8.5 SERIAL MONITOR OUTPUTS GIBBERISH SERIAL#
The Serial Plotter will also help debugging code by displaying the values various conditional statements and variables or even the states of the pins of the Arduino.Ī good example of would be troubleshooting a Obstacle Avoidance Robot. With the help of the Serial Plotter you can check if a sensors reading is incorrect or even if the sensor is not connected properly to the Arduino. In such cases where there too many lines of code or too many wires to debug the Serial Plotter can show the exact point of error. Faulty connections or incorrect coding logic can sometimes return an undesired output. One of the best uses of the Serial Plotter is to troubleshoot the code & circuit. In this case the values of the variables 'temperature & humidity will have separate waveforms plotted on the same graph simultaneously. Inorder to plot multiple variables or waveforms simultaneously a 'space' is printed between the two print statements.
![arduino 1.8.5 serial monitor outputs gibberish arduino 1.8.5 serial monitor outputs gibberish](https://i2.wp.com/randomnerdtutorials.com/wp-content/uploads/2021/05/Arduino-2-0-Serial-Monitor-ESP32.png)
When displaying multiple waveforms, every separate variable/value/parameter is displayed using a different colour like shown below. Remember to set the Baud Rate of the Serial Plotter so that it matches that of the code. In other words the plot is updated along the X-axis every time the Serial.println() is updated with a new value. The vertical Y-axis auto adjusts itself as the value of the output increases or decreases, and the X-axis is a fixed 500 point axis with each tick of the axis equal to an executed Serial.println() command. The Arduino Serial Plotter takes incoming serial data values over the USB connection and is able to graph the data along the X/Y axis, beyond just seeing numbers being spit out on to the Serial Monitor.
![arduino 1.8.5 serial monitor outputs gibberish arduino 1.8.5 serial monitor outputs gibberish](https://user-images.githubusercontent.com/48331/41821188-b737fe2c-77d4-11e8-8f14-60224bfcce0c.png)
Now that you have installed the latest version of the Arduino IDE(1.6.7 or above) its time to understand how the Serial Plotter actually works.