Project note -- LCD Smartie on Arduino
1. LCD Smartie
LCD Smartie is an open-source software for Windows that you can use to show lots of different types of information on your
LCD/VFD that connects to the PC via USB/Serial/Parallel ports.
It can display: CPU frequecy, load etc; BBC World News (or any other RSS feed!); WinAmp stats; Network stats
(speed, total bytes, etc); Disk available/free, memory usage, Email details, game stats, and many more...
2. Firmware Features
The LCD Keypad Shield for Arduino is a perfect platform for implementing the LCD Smartie on Arduino. An Arduino sketch is developed to interface the LCD Smartie software running on the PC, and it has following features -
- Drives the LCD Keypad Shield using the modified LCD_4Bit library download here
- Implements a basic subset of the Matrix Orbital commands
- Baud Rate 19200, 8bits, 1 stop, no parity
- Interrupt driven 5-key Joystick keypad reading routine to send key press to the PC
You can download the sketch from here
3. Firmware Description
3.1 Main loop() routine
The main loop() routine implements a command interpreter to accept and execute the commands and data sent by
the LCD smartie software running on the PC. It implements a basic subset of the Matrix Orbital commands --
void loop()
{
byte rxbyte;
byte temp;
rxbyte = serial_getch();
if (rxbyte == 254) //Matrix Orbital uses 254 prefix for commands
{
switch (serial_getch())
{
...
case 71: //set cursor position
temp = (serial_getch() - 1); //get column byte
switch (serial_getch()) //get row byte
{
//line 1 is already set up
case 2:
temp += 0x40;
break;
...
3.2 Interrupt driven Keypad scanning routine
An interrupt driven Keypad scanning routine is used to capture key press from the Joystick keypad inputs. Timer2 is used to generate interrupt at
4ms interval. The interrupt routine records the key press by reading AD0 value and comparing with keypad value stored in an array. A debounce mechnism
is also implemented. The interrupt routine then transfer the key press to LCD Smartie software running on the PC. The key press is useful for controlling
PC applications, such as Winamp Player.
ISR(TIMER2_OVF_vect) {
TCNT2 = 6;
update_adc_key();
}
void update_adc_key(){
int adc_key_in;
char key_in;
byte i;
adc_key_in = analogRead(0);
key_in = get_key(adc_key_in);
for(i=0; i
4. Hardware and Software Setup Procedure
- Download & install the modified LCD_4bit library as shown here .
- Download the Arduino LCD Smartie sketch here .
- Compile and upload your sketch to the Arduino/Freeduino board
- Setup the LCD Smartie software as following pictures --
Fig 1. LCD Smartie 5.4 Plugin setup tab --
Display Plugin -- choose matrix.dll
Startup Paramters -- Choose COM number (for Arduino boards) & 19200 baud rate
Fig 2. LCD Smartie 5.4 Screen setup tab --
LCD Size - 2x16
5. Screenshots
The following pictures are some screenshots of LCD Smartie on Arduino... ENJOY !!!






