LCD Circuit (Homework due Nov. 20th, 2017)


For this assignment, we had to connect a LCD to the Arduino and Processing and use the Dimmer example to change the numbers printed on the LCD as the mouse moved across the Processing window.

Because we had never connected an LCD before, after wiring it up (the first time), I decided to check if it was working using the “Hello World” built-in example. However, when I uploaded the code, nothing but some white rectangles was displayed. I looked at my circuit again and instead of using the wire schematic, I looked at the breadboard schematic. I immediately realized that I had reversed the order of the LCD pins. After switching all my wires, the “Hello Word” example ran perfectly.

I went on to tackle the actual exercise: displaying information from Processing on the LCD. Initially, I tried to combine the Processing Dimmer code and the Arduino Serial Display code. With these two codes combined, all the LCD displayed was rapidly changing characters and symbols from various languages as I moved the mouse across the Processing window. I tried moving around some variables to no avail until I noticed that that the LCD library had both a print and a write method. I read the documentation for both and then realized that the lcd.write() that was in the example only printed characters, so I changed it to a lcd.print(). There was one more adjustment to be made, though. Since the integer was printing multiple times on the screen, I removed the delay() that was in the example and everything began to work as I expected.

Arduino Code:

Processing Code:


Leave a Reply

Your email address will not be published. Required fields are marked *