Hardware Reference
In-Depth Information
1);
command sets the cursor to the start of the second line of the display. The
slcd.print(millis()/1000);
statement is an example of how to print a
number to the display, in this case, the number of seconds.
6. Now upload the sketch and you should see the
hello, world!
statement on the dis-
play, as shown in the following image:
Now, you can add all sorts of text by simply editing the
slcd.print("hello,
world!");
line in the
setup()
function or adding this same function to the
loop()
function. Make sure that if you place a message in the loop, use the
delay(2000)
func-
tion after it to give the user some time to read the display before you change it.