New Project, MarkoeZ is going to Fly!
More on that in a future post though, and corresponding Project Page.
First, since the next project will be based on Arduino/ATMega, and i have no experience with that, i decided to get an Arduino Uno.
The guys at Farnell (supplier of electronic components, dev kits, etc) noticed my blog, so they sponsored the Arduino Uno! (Thanks Farnell!)
They probably found it through the Hackaday Feature: Thanks Hackaday!
So i have no experience, and an Arduino Uno. Building time! :). First downloaded the software from www.arduino.cc. Then i went through my parts, and found a 5 volt, HD44780 compatible LCD display i ordered off ebay, and had not tested yet.
The Arduino site has a very useful tutorial on connecting the module (need to register first), and LCD Library is provided with the IDE.
The standard example code only displayed a static text though, and thats just boring. So i added some movement to the initial text, a tactile switch and a resistor to the circuit for state selection, and the appropriate code.
Click on "Full Post" for more details, parts list and very rough code (simple schematic will be added)
First, the Video Overview. Nothing ground shaking yet, only the camera :P Just a quick first look at the Uno, and the LCD module tests:
So what i first did is add movement to the text in the tutorial. Very simple, just added a software counter to the main loop, that moves everything one character to the left when XX is reached.
In a final poject, with more stuff going on, you may want to move that to a timer and interrupt configuration to free up cpu cycles for more important stuff.
So, Scrolling text, nice, but not interactive. For a fun demo you want to actually control the build, if only as simple as pushing a button. So i added a tactile switch to pin 8, a 10k resistor and some wires.
The button example code was not really useful for switching program states, since it just detected a button press, and not if it was held. So i added some button press/held detection code, rough, but functional.
Again, in a final project you will want to do it different. At least you should add a capacitor, or extra code for either hardware or software debouncing of the button. In the current setup you might get weird results sometimes, you are warned
Last to be added was the code to make the button presses actually do something, in this case, drawing different texts to the display.
* 5v HD44780 Compatible LCD Module, E-Bay
* Tactile Switch
* 1x 2.2K Resistor (For screen contrast, does not have to be exact, just try)
* 1x 10k Resistor (Pull Down Resistor for button, not exact, but make sure its high enough)
* Breadboard and Connecting Cables
Warning!!! Crude, and not to be used in anything outside a breadbord test setup.
But download here if you want to take a look: ArduinoLCDandBUTTON.txt