

Maybe you have a variable that gets incremented every so often and blinks an LED when it reaches a threshold.

Very often, when you are developing an Arduino sketch, what you end up coding does something differently than what you expected it to do. The other big reason to send information to a computer display using the Serial.print() function is for developing and debugging Arduino sketches.
#Arduino println wo serial#
If you open up the serial monitor window (Tools > Serial Monitor), you will see the values streaming in from the Arduino. The first reason is being able to see information that you are generating with your Arduino.įor example, if you have a temperature sensor hooked up to your Arduino and you want to see the value that the temperature sensor is recording, then you can use the Serial.print() function to send the data to a computer monitor via the USB cable. There are an endless number of reasons you may want to send information from the Arduino to a computer display, but two reasons really stand out to me: The Serial.print() function’s task is to send information from your Arduino to your computer, so you can see the value displayed on your computer’s monitor. You may know that a function is a programming tool – it performs a specific task for you. Why Would You Want to Use the Serial.print() Function? The basic use of the Serial.print() function.Why would you want to use the Serial.print() function?.Here are the specific topics we will cover in this lesson:

This is the first part, of a two part series on the Serial.print() function. In this week’s episode, we will talk about the intricacies of the Serial.print() function. One common method of doing this is using the Serial.print() function from the Serial library to display information to your computer’s monitor. In many cases while using an Arduino, you will want to see the data being generated by the Arduino.
