wiki:picoLCD

This driver supports the USB displays manufactured by iTuner picoLCD Website

Mini-Box USB LCD is an intelligent 2x20 character USB LCD display module with InfraRed receiver and keypad interface. This USB LCD display device it's a true USB HID device (not serial or parallel port to USB emulated) supporting high speed data transfers and easy application developmen without any special drivers needed. picoLCD is not limited to a USB only connection it can be connected thru I2C or USART.

Mini-Box has designed picoLCD with the ease of use in mind reducing the time and money needed for integrators to launch a new product with picoLCD. Our sample applications provides windows and linux platform support with open source code and SDK available.

Mini-Box USB LCD has built in 8x5 dots ASCII character font with 8 used definable characters and provides 8 GPO (General Purpose Output) pins. Internal EEPROM allows firmware upgrading and splash screen definition. On power on Mini-Box USB LCD is able to show up to 10 user defined splash screens with custom timing, order and led/gpo status.


Display Section

Display <name> {
    Driver   'picoLCD'
    Size     'string'
    Contrast  <number>
    Backlight <0|1>
    Icons     <number>
}

Parameters

Driver'picoLCD'
Size<rows>x<colums> for now only 20x2 is available
Contrastinitial contrast (0..40) 0 meaning stronger contrast 40 meaning lowest contrast
Backlightinitial backlight state (0=off, 1=on)
IconsNumber of user-defined chars reserved for Icons (default: 0) (maximum 8)

Plugins

The driver provides the following functions :

LCD::contrast(n)set the contrast to <n> (0..40)
LCD::backlight(v)switch the backlight on (v=1) or off (v=0)
LCD::gpo(n,v)set the GPO <n> to level <v> (0..255)
LCD::gpi(n)get the value of GPI <n>, n=1 is for button events. Option is available since rev.898

GPO widget lights mapping:

GPO1keypad(left,up,right,down,ok)
GPO2F1 key
GPO3F2 key
GPO4F3 key
GPO5F4 key
GPO6F5 key

GPI(1) button mapping:

ValueButton
1+
2-
3F1
4F2
5F3
6F4
7F5
8LEFT
9RIGHT
10UP
11DOWN
12OK

Example

Variables {
   n 0
   nkey 0
   button_text ''
}

Widget TimerW {
   class 'Timer'
   expression n=LCD::GPI(1);nkey=n!=0?n:nkey  
   active 1
   update 100
}

Widget BUTTON_ACTION {
   class 'Text'
   expression button_text
   width 20
   align 'L'
   update 500
}

Widget GPO_kf1 {
   class 'GPO'
   expression button_text=nkey==3?uptime('%d days %H:%M:%S'):button_text;nkey==3?1:0
   update 300
}

Widget GPO_kf2 {
   class 'GPO'
   expression button_text=nkey==4?strftime('%a,%d/%m %H:%M:%S',time()):button_text;nkey==4?1:0
   update 300
}

Display picoLCD20x2 {
   Driver   'picoLCD'
   Size     '20x2'
   Contrast  0
   Backlight 1
   Icons     6
}

Layout L20x2 {
   Row1 {
        Col1 'BUTTON_ACTION'
   }
   Timer1 'TimerW'
   GPO2       'GPO_kf1'
   GPO3       'GPO_kf2'
}

Display 'picoLCD20x2'
Layout 'L20x2'

Last modified 9 years ago Last modified on 10/07/08 19:02:03