Table of Contents

Advertisement

Quick Links

User Manual
ezLCD-3xx Product Family
Version 1.4 June 20, 2012
Requires Firmware Version 1.40 or Later
1

Advertisement

Table of Contents
loading

Summary of Contents for EarthLCD ezLED-3 Series

  • Page 1 User Manual ezLCD-3xx Product Family Version 1.4 June 20, 2012 Requires Firmware Version 1.40 or Later...
  • Page 2: Table Of Contents

    Table of Contents 1.0 Introduction............................4 2.0 About This Manual..........................5 2.1 One Hundred Dollars - The e.z. way!....................5 3.0 How the ezLCD-30x Works.........................6 4.0 Installation and Getting Started......................7 4.1 Connect the ezLCD USB to Your PC....................7 4.2 Verify the ezLCD USB Flash Drive Operation................8 4.3a Installing the USB Driver on a Windows 7 Operating System.............8 4.3b Installing the USB Driver on a Windows XP Operating System..........8 4.4 Run the “Termie”...
  • Page 3 12.5 Choice Widget – CHOICE......................40 12.6 Dial Widget – DIAL........................41 12.7 Digital Meter Widget – DMETER....................43 12.8 Groupbox Widget - GBOX ......................45 12.9 Progress Widget – PROGRESS....................46 12.10 Radio Button Widget – RADIO....................48 12.11 Slider Widget - SLIDER......................50 12.12 Static Text Widget – STATIC....................52 13.0 Snapshot Command.........................54 14.0 Widget State Command........................55 14.0 Flash Drive File Structure........................56...
  • Page 4: Introduction

    CNC mill he was always tinkering with in his garage. We hope that you enjoy using your ezLCD-3xx as much as we’ve enjoyed creating it! -Randy Schafer EarthLCD.com CEO & Fire Starter...
  • Page 5: About This Manual

    2.1 One Hundred Dollars - The e.z. way! Technical documentation here at EarthLCD is a continuous process. Our goal is to provide easy to use and well documented products. Over our nearly 20 year history our best ideas have come from our customers.
  • Page 6: How The Ezlcd-30X Works

    MSD driver. The serial interface uses a built-in CDC driver when connected through the USB. The CDC driver is already installed in most computers. Under Windows the driver only requires the EarthLCD.inf file (which is included on the ezLCD-3xx flash drive) for configuration.
  • Page 7: Installation And Getting Started

    4.0 Installation and Getting Started You will need the following before proceeding: • ezLCD-3xx Smart LCD • ezLCD-3xx USB Cable or an ezLCD-30x EDK board with USB cable • A computer with a USB connection (Host) The 7 steps to install your ezLCD-30x are: 4.1 Connect the ezLCD-3xx USB to Your PC 4.2 Verify the ezLCD-3xx USB Flash Drive Operation 4.3 Install the USB CDC Driver...
  • Page 8: Verify The Ezlcd Usb Flash Drive Operation

    Once the ezLCD-30x fails to install automatically, open up the Device Manager. The device should be listed under Other Devices with an exclamation mark next to EarthLCD ezLCD-30x. Right click this item and select Update Driver Software. On the next screen, select Browse my computer for driver software.
  • Page 9: Run The "Termie" Terminal Program

    On the following screen, select No, not this time and click the Next button. Select Install from a list or specific location and click the Next button. Click the Browse button and select the flash drive labeled ezLCD-30x that was automatically installed earlier.
  • Page 10: Verify Connection

    the Parity to None, the Stop bits to One, and make sure to uncheck Monospaced font and Local echo. Select OK. For purposes of this manual it is assumed that you are using ‘Termie’, but most other ASCII terminal programs will work as long as you use the same comparable settings . If you do not remember the COM port, look in Control Panel/Device Manager/Port (Figure 3).
  • Page 11: Command Your Ezlcd With Earthsempl

    5.0 Command your ezLCD with EarthSEMPL Your ezLCD-30x is really a computer and like all computers it has a language in which you can talk to it in. The ezLCD-30x uses the simplest of languages, which we call Earth Simple Embedded Macro Programming Language, or EarthSEMPL for short.
  • Page 12: Creating And Saving Macros

    editor must insert a carriage return after each line of text (Notepad, Wordpad and almost all editors do). In the included Termie program, it’s important that you select the Append CR option in SETTINGS. For Firmware 1.1 and after, you should select the Append CR-LF option. 5.2 Creating and Saving Macros EarthSEMPL is an interpreter.
  • Page 13: Earthsempl Macros

    The latest can be downloaded as part of the file system for your ezLCD-3xx model on it’s product page at the EarthLCD website. The ezLCD-30x latest file system is located http://www.earthlcd.com/ezLCD-30x . Note: Substitute your model number for ezLCD-3xx.
  • Page 14: Startup.ezm - Your Most Important Macro

    It may also be used to set default fonts, themes, colors and other ezLCD parameters. Application notes by EarthLCD will assume you are using the factory default macro. Never change the default startup macro . Instead copy the original \EZSYS\MACROS\STARTUP.EZM into the \EZUSER\MACROS directory and then customize it for your application.
  • Page 15: Images

    7.0 Images The ezLCD-3xx can display .jpg, .gif and .bmp image files. Example image files are located in your \EZSYS\IMAGES directory. Image files must be kept in your \EZUSER\IMAGES directory. To display an image file, type the command PICTURE or IMAGE into your terminal window followed by the image name, including the file suffix.
  • Page 16: Resizing An Image In Windows Paint

    7.2 Resizing an Image in Windows Paint Open the image in Windows Paint. Make sure that under the Paint dropdown menu, Image Properties the Units option is set to pixels. Use the Rectangular Selection tool to select the area of the image that you want to crop. Paint does not allow for fixed cropping ratios.
  • Page 17: Colors

    8.0 Colors The ezLCD-30x has the ability to display up to 65,535 colors simultaneously. This is referred to as 16- bit color. You may input 24-bit colors which the ezLCD-30x converts internally to 16-bit. To ease color selection, an index of 200 customizable colors are provided internally (see COLORID). The first 168 colors have been preset in your ezLCD-30x, with the remaining colors available for your own custom colors.
  • Page 18: Drawing

    9.0 Drawing The ezLCD-3xx has the ability to draw individual pixels, lines, boxes, circles, circle sections and arcs. Successive shapes will appear to be layered on top one another if drawn in the same location. All shapes are drawn with the current color. To see a demo of some shape examples, type PLAY SHAPES into your terminal program.
  • Page 19: Drawing A Circle Section

    9.5 Drawing a circle section Typing the command PIE [r][s][e] draws a section of a circle (pie slice) at current xy position. Replace [R] with the desired radius of the section, in pixels. Replace [S] with the start angle at which you want the section to start.
  • Page 20: Fonts And The Print Command

    The ezLCD-30X font converter for windows will allow you to create and customize new ezLCD fonts from TrueType and OpenType fonts. It is available for free download at http://www.earthlcd.com/ezLCD-301. To set the current font, type the command FONT [font] into your terminal program, where [font] is the name of the font.
  • Page 21 will print the text at the horizontal and vertical center of the screen. This command will justify the text referencing the center of the text because of the CC option. You can also justify text placement with the other 8 options. It is an easy way of placing text without computing font heights and widths. To see a macro that demonstrates this, type PLAY ALIGN in your terminal program.
  • Page 22: Widget Themes

    11.0 Widget Themes The THEME command is a way of describing color and font characteristics of widgets. Themes are introduced here but you may want to proceed to the 12.0 Widgets and play with widgets and refer back to here when you want to customize the themes for the examples. Different widget types can use the same color theme to make your GUI look consistent.
  • Page 23 THEME 5 126 118 3 3 3 35 35 35 35 2 Don’t worry about damaging the default settings - these are the default values for theme 5. You can change the settings and see the results by using the BUTTON command as outlined in Section 12.0. The command THEME 5 references theme 5.
  • Page 24: Diagrams Of Widget Themes

    11.1 Diagrams of Widget Themes Theme [ID] [EmbossDkColor] [EmbossLtColor] [TextColor0] [TextColor1] [TextColorDisabled] [Color0] [Color1] [ColorDisabled] [CommonBkColor] [Fontw] Analog Meter Pressed Button Button Disabled Button Disabled Checkbox "Filled/Checked" Checkbox...
  • Page 25 Choice Dial Digital Meter...
  • Page 26 Progress Bar Radio Button Slider Slider (scroll bar option)
  • Page 27 Static Box Framed Static Box...
  • Page 28: Some Non-Widget Commands

    11.1 Some Non-Widget Commands CLIPENAREA[left][top][right][bottom] allows you to designate a rectangular/box area that you can draw in. Any surrounding area will be protected and no changes can be made to it. (ex. CLIPAREA 50 30 200 150 ) CLIPENABLE[enable] is a command to turn on or off clipenable. 0/off = disable, 1/on = enable RECORD[name] allows you to record your commands to a macro, [name].
  • Page 29 new files or changes to them, because you need to be or located at that directory the files are in. [name] needs to be in double quotes. If you want to move to a directory that is within another directory, you will need to show each directory paths with a \ in front.
  • Page 30 Will generate a simple tone of the frequency and duration provided. If frequency and duration are not provided it will default to 4000, 1000. Before using the beeper it must be configured to match the hardware you are using. For the expander board IO7 is used. CFGIO 7,BEEPER BEEP 4000,2000 BRIDGE [port]...
  • Page 31 This would allow the UART2 as the console port and USB and UART1 are bridged together (not console). This configuration can be used to program an Arduino or Basic Stamp in circuit. You must also enable DTR and RTS to reset those products during programming. Appnote to follow.
  • Page 32: Widgets

    12.0 Widgets A widget is a reusable screen object of a graphical user interface that displays an information arrangement and provides standardized data manipulation. Widgets allow you to create an interactive user interface that is small, fast and easy! There are user input widgets and output widgets. Input widgets takes the user input and outputs a result to the command port.
  • Page 33: Analog Meter Widget - Ameter

    12.1 Analog Meter Widget – AMETER The AMETER widget allows you to display an analog meter which looks like a car speedometer. It’s companion command, AMETER_VALUE, allows you to set the needle value without redrawing the whole meter. Also, the AMETER_COLOR command allows you to change the colors of the number and line indicators that form an arc around the meter.
  • Page 34 Option 3 = Ring Option 1= Draw Option 4 = Accuracy Option 2 = Disabled Option 1= Draw Option 3 = Ring Option 4 = Accuracy Option 2 = Disabled The AMETER command contains ten different values. The [ID] value 1-99, is the id number of this particular widget. You can create many different widgets as long as each ID is unique regardless of widget type.
  • Page 35 The [min] designates the minimum value on the meter scale. The [max] designates the maximum value on the meter scale. The [theme] sets the widget to theme 5. The [stringID] designates the id number of the text string that you’d like displayed below the meter. [color 1-6] changes the colors of the 6 “zones”...
  • Page 36: Button Widget

    12.2 Button Widget A button widget (sometimes known as a push button or command button) is a user interface element that provides the user a simple way to trigger an event. You can draw/make a variety of buttons making them round or square by adjusting the [radius] parameter. This is the ideal replacement for a switch in an embedded application.
  • Page 37 Align 3 = Bottom Align 2 = Left Align 1 = Right Align 0 = Center Align 4 = Top Pressing the button will send BP1 to the Command Port and releasing it will send BR1 to the Command Port. The button command contains ten different values.
  • Page 38 can save as many different text strings as you’d like. To write a text string, type the following: STRING 0 "HELLO" and the word HELLO will appear on any button that designates text string 0. Note: To create multi-line text on buttons, use \n in the string contents. Example: string 5 “Wrap\nText” will appear on 2 lines.
  • Page 39: Touchzone Widget

    12.3 Touchzone Widget A touchzone widget is a user interface element that provides the user a simple way to trigger an event just by press an area of the screen defined by a box. You can also draw graphics of any kind onto the screen and place a hot spot around it with touchzone.
  • Page 40: Check Box Widget - Checkbox

    12.4 Check Box Widget – CHECKBOX The CHECKBOX widget allows you to display a check box with a string next to it. This permits the user to make a choice. When a CHECKBOX state changes (it is checked or unchecked) a status change is sent to the host via the current Command Port.
  • Page 41 The [width] and [height] values designate the width and height of the widget in pixels. The [options], designates the initial state of the checkboxes. Option choices: 1=draw unchecked, 2=draw disabled, 3=draw checked, 4=redraw The [theme] changes the colors on the widget. The [stringID] designates the id number of the text string that you’d like displayed next to the text string.
  • Page 42: Choice Widget - Choice

    12.5 Choice Widget – CHOICE The CHOICE widget allows you to print a string and display buttons for the user to choose a response. CHOICE reply buttons are “yes”, “no”, or “cancel”. This widget is useful for asking simple “yes or no” questions without having to tediously figure out coordinates, sizes, and et al.
  • Page 43: Dial Widget - Dial

    12.6 Dial Widget – DIAL The DIAL widget allows you to display a dial that looks like an analog volume control found in modern cars. The DIAL.EZM file in the \EZSYS\MACROS directory contains an example of this widget. It can be invoked by typing PLAY DIAL in TERMIE. dial [ID][x][y][radius][option][resolution][value][max][theme] Example: cls white...
  • Page 44 The [value] designates the initial dial value. The [max] value designates the largest value of the dial’s input. The [theme] value sets widget theme. Note: Themes 0-7 are predefined in the STARTUP.EZM macro.
  • Page 45: Digital Meter Widget - Dmeter

    12.7 Digital Meter Widget – DMETER The DMETER widget allows you to display a digital meter as in a panel meter. It’s companion command the DMETER_VALUE command allows you to set the read out value without redrawing the meter. The DMETER.EZM file in the \EZSYS\MACROS directory contains an example of this widget. It can be invoked by typing PLAY DMETER in your terminal program.
  • Page 46 as long as each ID is unique regardless of widget type. For dmeter_value the ID must be the same ID as the dmeter you want to change. The [x] and [y] values designate the location of the widget on the screen as the XY coordinate of the upper left corner.
  • Page 47: Groupbox Widget - Gbox

    12.8 Groupbox Widget - GBOX The GBOX widget generates a border/box and by changing the options positions the header text at different alignments. Group boxes help visually distinguish related items by framing them. The Groupbox consists only of the frame, title, and a title background. The GBOX.EZM file in the \EZSYS\MACROS directory contains an example of this widget.
  • Page 48: Progress Widget - Progress

    12.9 Progress Widget – PROGRESS The PROGRESS widget allows you to display a progression bar at an initial state. To change the values to show progression or regression, use the PROGRESS_VALUE command. PROGRESS_VALUE command does not re-draw the entire percentage bar, but changes the value. The PROGRESS.EZM file in the \EZSYS\MACROS directory contains an example of this widget.
  • Page 49 The PROGRESS command contains nine different values and PROGRESS_VALUE contains two values. The [ID] value 1-99, is the id number of this particular widget. You can create many different widgets as long as each ID is unique regardless of widget type. In order to change the value of a specific progress bar, you must use its id number.
  • Page 50: Radio Button Widget - Radio

    12.10 Radio Button Widget – RADIO The RADIO widget allows you to display buttons for making a selection. Radio buttons differ from checkboxes in that only one button can be filled in at a time, while checkboxes can have many filled in. Therefore, radio buttons are interconnected.
  • Page 51 The [width] and [height] values designate the width and height of the widget in pixels. The [width] and [height] are not the dimensions for the radio button, but it is the area which the button and string will be in. The size of the radio button itself is defined by the height of the button. The [options] available allow you to draw radio buttons checked, unchecked, or disabled.
  • Page 52: Slider Widget - Slider

    12.11 Slider Widget - SLIDER The SLIDER widget allows you to display a vertical or horizontal slider bar that looks like a light dimmer. The SLIDER widget components are the slider and a handle, also known as the thumb or indicator.
  • Page 53 The [x] and [y] values designate the location of the widget on the screen as the XY coordinate of the upper left corner. The [width] and [height] values designate the width and height of the widget in pixels. The [option], 1, designates the options of the slider. Option choices: 1=draw horizontal, 2=horizontal disabled, 3=vertical, 4=vertical disabled, 5=horizontal slider, 6=horizontal slider disabled, 7=vertical slider, 8=vertical slider disabled The [range] value designates that the minimum and maximum value is 0-75.
  • Page 54: Static Text Widget - Static

    12.12 Static Text Widget – STATIC The STATIC widget generates a framed text box with a header string at different alignments. This command changes text within a box without having to overwrite its background The STATIC.EZM file in the \EZSYS\MACROS directory contains an example of this widget. It can be invoked by typing PLAY STATIC in your terminal program.
  • Page 55 The [ID] value 1-99, is the ID number of this particular widget. You can create many different widgets as long as each ID is unique regardless of widget type. For static_value the ID needs to be the same ID as the static box you want to change. The [x] and [y] values designate the location of the widget on the screen as the XY coordinate of the upper left corner.
  • Page 56: Snapshot Command

    13.0 Snapshot Command The Snapshot command is a lot like taking a screen shot. First, you need to display onto the screen what you would like to take a snapshot of. Then you use the command SNAPSHOT to capture and save it to a file.
  • Page 57: Widget State Command

    14.0 Widget State Command The widget state command is used to adjust the state of a widget. WSTATE [ID] [options] [ID] must be the same as the ID of the widget you want to change. [Options] are: 0 = delete, 1 = enable, 2 = disable, 3 = redraw 0 = Delete the widget.
  • Page 58: Flash Drive File Structure

    Note: It is recommended to make a copy of the EZSYS directory on your PC hard drive in case of accidental alteration of that directory on your flash drive. The EZSYS default directory is also available for download on the EarthLCD website. EZSYS\FONTS - default font files (.ezf) EZSYS\IMAGES - default image files (.gif, .jpg, .bmp)
  • Page 59: Ports & Embedding The Ezlcd-3Xx

    PC as it is in the examples we’ve shown up to now. More specific examples of embedding and connecting the ezLCD-3xx to other micro-controllers can be found on the ezLCD-3xx product page at www.EarthLCD.com/ezLCD-30x. We suggest that beginners take a look at the Arduino application notes.
  • Page 60: Command Port Management

    Warning : Do not change the CMD port in the startup.ezm file located in the \EZSYS\MACROS folder. Instead, make a copy of it in \EZUSER\MACROS and modify it there. 15.2 Command Port Management Setting the command port to another port besides USB can cause problems if you cannot set it back. That is the reason we recommend to never change the startup.ezm file in the \EZSYS\MACROS directory or any files in the \EZSYS directory.
  • Page 61: Start Something With Your Ezlcd-3Xx

    However, in the coming months the staff, consultants, customers and maybe even you will develop application notes that will be available on the product web page at www.earthlcd.com/ezLCD-30x. File updates, firmware and examples will also be provided there, so bookmark it and check back often.
  • Page 62: Warnings, Errata And Gotchas

    • As with any new technology product there will be bugs or opportunities for improvement ;-) : If you find something that you think should be changed, fixed or enhanced, send it to support301@earthlcd.com and it will be addressed ASAP. • Do not play a macro of the same name within itself.
  • Page 63: Gratis (A Note From Randy Schafer)

    18.0 Gratis (a note from Randy Schafer) There are more than a few people who put up with my continuous banter about making this product right: Mark Eck, our VP of Sales and Marketing who’s never short of new ideas. Our graphics artist and Maker enthusiast James Harrell.
  • Page 64: Appendix A: Ezlcd-30X Connector Pinout

    Appendix A: ezLCD-30x Connector Pinout Note: Connector is DF11-16DP-2V. Mating Connector DF11-16DS-2C or DF11-16DS-2DSA The I/O pins are programmable for different I/O functions in the future but the current firmware supports the following command to set the command port to serial port 2 on IO3 & IO4 : CMD SERIAL2 115200 1 N81 For firmware 1.4 on use cfgio 4 serial2_tx 115200 N81...
  • Page 65: Appendix B: Ezlcd-30X Model Descriptions And Drawings

    Appendix B: ezLCD-30x Model Descriptions and Drawings ezLCD-301: 400 x 240 Wide (10:6) 65.536 Transmissive Color TFT with Resistive TouchScreen Connector Drawing (See 16 Pin): http://www.hirose.co.jp/cataloge_hp/e54305002.pdf Connector Placement: Mechanical Drawing:...
  • Page 66 ezLCD-302: 240 x 160 (4:3) 4096 Reflective Color TFT (Sunlight Readable - NO Touchscreen)
  • Page 67: Appendix C: Earthsempl Colors

    Appendix C: EarthSEMPL Colors...
  • Page 72 color_ID [x] Color khaki black dark khaki grey lavendar silver thistle white plum violet maroon orchid yellow fuchsia olive medium orchid lime medium purple green blue violet aqua dark violet teal dark orchid blue dark magenta navy purple fuchsia indigo purple dark slate blue indian red...
  • Page 73 aquamarine gainsboro turquoise light gray medium turquoise silver dark turquoise dark gray cadet blue gray steel blue dim gray light steel blue light slate gray powder blue slate gray light blue medium turquoise sky blue dark slate gray light sky blue black deep sky blue gray7...
  • Page 74: Appendix D: Earthsempl Command Reference Guide

    Input values can be an integer between -32768 and 32767. Strings can be up to 64 characters. Examples and descriptions are provided for each command in the table. Note that this command list is updated from time to time and you should check the ezLCD-30x product page at EarthLCD.com for the latest documentation.
  • Page 75 TABLE 1 SHORT COMMAND SYNTAX EXAMPLE DESCRIPTION & OPTIONS FORM Draw ARC w ith Radius, Start ARC [radius][start][end][fill] ARC 50 100 120 1 angle and End angle. Fill=1 or F to fill arc.   Angle of 0 is on the right. Place a box from current XY w ith specif ied w idth and height.
  • Page 76 DEL [name] DEL "Droid.ezm" Delete file name DIR [mask] DIR *.ezm" Returns directory using mask ECHO ECHO [mode] ECHO off Sets mode 0 = OFF or 1 = ON Delete file name. Must be in the ERASE ERASE [name] ERASE "Droid.ezm" directory the file is located in.
  • Page 77 Draw PIE w ith Radius, Start PIE [radius][start][end] PIE 55 120 140 Angle, and End angle  Angle of 0 is on the right. Asks LCD to send acknow ledge PING PING PING w ith PONG Play macro "name",  Looks in directory \EZUSER\MACROS first PLAY PLAY [name]...
  • Page 79 Wait for events. Options: “T” = Touch, “!T” =No Touch, “TR” = Touch and release, “IO[1-9]” = WAIT WAIT [Option] WAIT T Wait for 1 (choose a pin number [1-9]), “!IO[1-9]” = Wait for 0. No option = Touch and Release Set draw ing cursor to location x,y on screen.
  • Page 80 Options: 1=draw , 2=disabled, RADIO [ID][x][y][w idth][height ] RADIO BUTTON RADIO 4 50 50 100 50 4 2 1 3=checked, 4=first, 5=first and [option][theme][stringID] checked. Options: 1=draw hori, 2=hori SLIDER [ID][x][y][w idth][height] disabled, 3=vert, 4=vert disabled, SLIDER 1 20 30 100 50 1 75 5 SLIDER 5=hori scrollbar, 6=hori scrollbar [options][range][resolution][value]...
  • Page 81: Appendix E: Upgrading The Ezlcd-30X Firmware

    Before starting an upgrade be sure you have downloaded the ezLCD30x Firmware Loader and installed it. The latest firmware can be found at www.EarthLCD.com/ezLCD-30x. IMPORTANT: Never use any upgrade firmware that is not designed for the display you have. Only ezLCD-30x firmware should be installed.
  • Page 82 Format the ezLCD, using quick format by right clicking the drive in file manager and selecting the button "Restore Device Defaults". Step 10. Load the new file system if you re-formatted or downloaded a new file system from the EarthLCD website. Step 11. Reconnect your terminal program and enjoy your firmware upgrade.
  • Page 83: Appendix F: Installing & Using The Ezlcd-30X On A Mac (Os X Lion (10.7)

    Appendix F: Installing & Using the ezLCD-30x on a MAC (OS X Lion (10.7) The ezLCD-30x requires OS X version 10.7 or later to run on a MAC. The good news there are no drivers or utilities to install. Step 1. Run the Mac Terminal program Use spotlight or navigate in Finder to the Applications/Utilities folder and run the Terminal application.

This manual is also suitable for:

Ezled-30 series

Table of Contents