Using a Raspberry Pi with a Hope Industrial Systems Touch Screen Part II: Touch Screen Setup

Hope Industrial UM22 Touchscreen and Keyboard with Raspberry Pi internally integrated

Hope Industrial UM22 Touchscreen and Keyboard with Raspberry Pi internally integrated

In our last post we introduced our Raspberry Pi proof-of-concept project and outlined the physical components and setup required for using the Raspberry Pi as an industrial touch screen PC in a harsh environment. Please see our previous post for important information to consider before integrating a Raspberry Pi with our industrial touch screens.

In this post, we will show how easy it is to set up the Raspbian Operating System to work with a Hope Industrial touch screen without adding any third-party drivers. This how-to assumes a basic understanding of Linux command line use and text file editing. Feel free to contact us with any questions.

Installing the Raspbian OS

Linux installers are very advanced and easy to use these days, and Raspbian is no exception. The cheekily named NOOBS (New Out of Box Software) installer makes things very simple. You can find the software and a link to the quick-start guide here.

First, download the SD card image on your PC, then decompress it to a properly prepared SD card (4 GB or larger), insert it in the Raspberry Pi, and choose which distribution you want to run. When asked, choose Raspbian, which is the Raspberry Pi-optimized version of the Debian Linux distribution.

Once up and running, make sure your Raspberry Pi has an Internet connection.

Calibrating the Touch Screen – Inverting the Y-Coordinate

As mentioned in the first post, Raspbian has default drivers that recognize our industrial touch screen as an HID pointing device, which means if you press the screen after simply making the USB connection, you will get a response. However, at this point, the Y-coordinate is reversed, which means that touches to the top of the screen show up on the bottom, and vice versa. Our first step is to correct this problem.

To do this, we will need to make some changes to the evdev component, which is a part of the Linux kernal that handles input devices.

1.  Open the evdev configuration file in your favorite text editor. We use vi:

2.  Note how this file is laid out. It has sections for various types of input devices, along with “match” types that designate which devices a section applies to, and attributes and settings for those devices.

3.  Following the format in the file, create a new “InputClass” section with the following attributes:

  • Identifier “elo touchscreen catchall” – This is just the name we will give the section.
  • MatchVendor “EloTouchSystems_Inc” – Tell the section to match all devices with this vendor. All Hope Industrial Touch Screens use touch controllers made by Elo Touch Systems. Of course, if you have multiple touch screens connected and need separate calibrations for each, you will want to match on something else. The evdev documentation can help here.
  • MatchDevicePath “/dev/input/event*” – Keep this default setting.
  • Driver “evdev” – Keep this default setting.
  • Option “InvertY” “true” – Tell the driver to invert the Y axis.

The final text of this new section should look like this:

Section "InputClass"
	Identifier "elo touchscreen catchall"
	MatchVendor "EloTouchSystems_Inc"
	MatchDevicePath "/dev/input/event*"
	Driver "evdev"
	Option "InvertY" "true"

After saving this file and rebooting, the cursor should follow your finger much more closely, but will not yet be perfectly calibrated. We will address this in the next section.

Calibrating the Touch Screen – Aligning the Pointer

The touch screen alignment requires us to set some parameters that tell the driver how to “stretch” the touch screen input across the available screen area. To do this, we have to download a simple utility called evtest. You can use the Debian Advanced Package Tool (Apt) tool to download the utility. Learn more about Evtest here.

1.  Use apt installer to download and install the “evtest” package.

2.  Run evtest.

3.  Evtest will list the attached input devices. Select the number of the device for the Elo TouchSystems 2216 Accutouch Interface (this was device number two on our system).

4.  Evtest will show some configuration data then pause, waiting for input.

5.  Using your finger or a stylus, touch the very top left corner of the touch screen. You will see the evtest scrolling a series of data output with both ABS_X and ABS_Y lines, followed by numeric values:

Event: time 1374175747.420998, type 3 (EV_ABS), code 0 (ABS_X), value 484
Event: time 1374175747.421011, type 3 (EV_ABS), code 1 (ABS_Y), value 3364

6. Of these values, write down the lowest observed ABS_X value and the highest observed ABS_Y value.

7. Now repeat the process, but this time touch the lower right hand corner of the screen and write down the highest ABS_X value and the lowest ABS_Y.

8. Now open the 10-evdev.conf file we used in the last step and add the following to the previously created section: Option “Calibration” “minX maxX minY maxY”, substituting minX, etc., for the observed values from above. The resulting final text of this section should look like this (but of course with the values from your test):

Section "InputClass"
		Identifier "elo touchscreen catchall"
		MatchVendor "EloTouchSystems_Inc"
		MatchDevicePath "/dev/input/event*"
		Driver "evdev"
		Option "InvertY" "true"
		Option "Calibration" "449 3562 575 3412"

9. Save the file, reboot, and now your cursor should follow your finger very closely.

All that is left to do is add the ability to right-click-to-hold, which is necessary for a fully functioning touch screen.

Enabling Hold-For Right Click

This is the easiest part of our process. In order to add right clicking, open the 10-evdev.conf file one more time and add the following lines to the same section we previously created:

  • Option “EmulateThirdButton” “1” – This enables the feature.
  • Option “EmulateThirdButtonTimeout” “750” – This sets the time in milliseconds you must hold your finger down to create a right-click event.
  • Option “EmulateThirdButtonMoveThreshold” “30” – This sets the threshold at which you are allowed to slightly move your finger during the timeout without restarting the timeout count.

Your final section should look like this:

Section "InputClass"
		Identifier "elo touchscreen catchall"
		MatchVendor "EloTouchSystems_Inc"
		MatchDevicePath "/dev/input/event*"
		Driver "evdev"
		Option "InvertY" "true"
		Option "Calibration" "449 3562 575 3412"
		Option "EmulateThirdButton" "1"
		Option "EmulateThirdButtonTimeout" "750"
		Option "EmulateThirdButtonMoveThreshold" "30"

Reboot, and now you should have a fully functioning industrial touch screen PC with Raspberry Pi!


We hope you have enjoyed this proof-of-concept project installing the Raspberry Pi into a Hope Industrial touch screen.

Keep checking our blog for more step-by-step guides to creative uses of existing technology paired with Hope Industrial touch screen monitors. We will be writing more posts like these based on customer interest in the future. Feel free to contact us with any questions or suggestions.

10 Responses to “Using a Raspberry Pi with a Hope Industrial Systems Touch Screen Part II: Touch Screen Setup”

  1. David December 16, 2013 at 6:35 pm #

    Thank you very much, this guide made it a breeze to calibrate my ELO touchscreen!
    I noticed that instead of inversing the Y-axis you can also swap the minY and maxY values.

  2. Ivan January 9, 2014 at 12:09 pm #

    In Section about Calibrating the Touch Screen – Inverting the Y-Coordinate, your text for new InputSection doesn’t correspond to what needs to be done but if I follow the actual instructions, I get a blank back screen with blinking cursor and have to re-install Raspbian. Can you update this section with what the new section actually looks like? Also does MatchVendor value have to match what I see in boot log when it detects that device?

    • Daniel J. McGraw February 26, 2014 at 11:43 am #

      Hi Ivan sorry for the delayed reply – our WordPress alerts were on the fritz.

      Regarding the instructions not perfectly matching your setup – I’m sure you are running a newer version than we were in Oct., so perhaps something has changed (I will edit the post to include the version we used to generate the instructions).

      In the mean-time, see David’s comment above – if you are calibrating fine but stumbling at the Y-Coordinate inversion, you could simply swap the minY and maxY vales as he points out.

      On the vendor match, you should be able to match exactly “EloTouchSystems_Inc” as noted, as this is how our touch screens report themselves.

  3. Jpeyro March 6, 2014 at 6:26 am #

    Hi , I have a raspberry pi model b , with this version of raspbian :
    2014-01 -07- wheezy –
    already installed ,
    I have a monitor Elo TouchSystems ET2239L ,
    USB and RS- 232, I can connect the touch by either of these methods .
    I have this VGA monitor connected to the Raspberry , right through an RCA to VGA converter.
    In Raspberry , I connect the Touch Monitor , via USB port , for obvious reasons

    Now, my problem is that without installing any driver , and recently started Raspbian for the first time , once on the Desktop , touching the monitor, and it works, but completely inverted, I touch with my finger on the right side and curzor mouse , it moves on the left side of the screen , and when touched up , the curzor moves at the bottom of the screen.

    I have followed your tutorial , changing the above file :
    / usr/share/X11/xorg.conf.d/10-evdev.conf
    several times, but nothing changes.
    Option ” InvertY ” “true”
    Option ” InvertX ” “true”
    Option ” SwapAxes ” “true”
    it is as if this does not take effect.

    Install evtest , and when I run it , this is what shows on the screen :
    / dev/input/event0 : Elo TouchSystems , Inc. Elo TouchSystems 2700 IntelliTouch (r ) USB Interface Touchmonitor
    / dev/input/event1 : USB To keyboard Mouse Converter
    / dev/input/event2 : USB To keyboard Mouse Converter

    So apparently Raspbian recognizes the Touch device.

    Have you any idea for this?

    Thank you.

    • Daniel J. McGraw March 6, 2014 at 8:18 am #

      Hi Jpeyro, it looks like the Elo controller is a bit different than the ones we integrate in our industrial touch screens, but I suspect the problem has to do with where you are putting your Option Invert_ values. I’m mobile right now and cannot research, but let me see if I can point you in the right direction.

      Option Invert_ need to be placed inside a Section “InputClass” that is set up to match something about your controller – in our example above we matched on:

      MatchVendor “EloTouchSystems_Inc”
      MatchDevicePath “/dev/input/event*”

      Your vendor string may be different than what we used – you need to check this using I think lusb or xinput list-props, or xinput list – I’m not sure and I cannot confirm right now.

      I suggest you put a new InputClass statement in your 10-evdev.conf that is just like the one above (just before the conclusion), use one of those methods to verify your vendor string, then edit the invert and calibration values to suit.

      Sorry I cannot be exact – let me know if that does not get you anywhere.


      • Martin Edlman March 12, 2014 at 3:56 pm #

        Hello, great manual, it really helped me. But I had the same problem as Jpeyro – when I calibrated the X/Y-axis using evtest nothing changed. I have ELO 0700L (7″ touch monitor). evtest showed

        # evtest
        No device specified, trying to scan all of /dev/input/event*
        Available devices:
        /dev/input/event0: Microsoft Basic Optical Mouse
        /dev/input/event1: EloTouchSystems,Inc Elo TouchSystems 2216 AccuTouch® USB Touchmonitor Interface

        So I tried to replace
        MatchVendor “EloTouchSystems_Inc”
        MatchVendor “EloTouchSystems”
        in /usr/share/X11/xorg.conf.d/10-evdev.conf

        and huray, it works! I hope this will help Jpeyro too.


    • Rthreis June 25, 2014 at 5:38 am #

      Hello Jpeyro,
      I’m trying to use the same monitor, and got the X and Y axis inverted, both.
      I’ve tried several configs, but nothing seem to work.
      Have you found a solution on your issue ? Can you tell me more about ?

  4. Plasma April 4, 2016 at 6:35 pm #

    I realise this is an old posting but I am hoping someone might be able to point me in the right direction. My monitor information is ..

    I: Bus=0003 Vendor=04e7 Product=0020 Version=0100
    N: Name=”Elo TouchSystems, Inc. Elo TouchSystems 2700 IntelliTouch(r) USB Touchmonitor Interface”
    P: Phys=usb-3f980000.usb-1.3/input0
    S: Sysfs=/devices/platform/soc/3f980000.usb/usb1/1-1/1-1.3/1-1.3:1.0/0003:04E7:0020.0001/input/input0
    U: Uniq=20000000
    H: Handlers=mouse0 js0 event0
    B: PROP=0
    B: EV=1b
    B: KEY=10000 0 0 0 0 0 0 0 0
    B: ABS=100 3
    B: MSC=10

    The touchscreen works just fine without inverting anything, but whenever I add any of the “EmulateThirdButton” parameters or the calibration ones X refuses to start.

    Can someone maybe give me a hand getting the right click working? I also tried installing the “xserver-xorg-input-elographics” package but that hasn’t made any difference at all. I have no idea if its even using this driver or how to tell it to.

    Thanks in advance.


  5. Plasma April 5, 2016 at 6:54 am #

    Solved this, I changed the MatchVendor to Match Product with a keyword:

    Section “InputClass”
    Identifier “elo touchscreen catchall”
    MatchProduct “2700 IntelliTouch”
    MatchDevicePath “/dev/input/event*”
    Driver “evdev”
    Option “InvertY” “true”
    Option “Calibration” “50 4067 4040 27”
    Option “EmulateThirdButton” “1”
    Option “EmulateThirdButtonTimeout” “750”
    Option “EmulateThirdButtonMoveThreshold” “30”

  6. 3dangel November 11, 2016 at 11:12 pm #

    Thanks a lot for sharing this out!!!
    It worked for me and really made my day!

Leave a Reply:

Gravatar Image

WordPress Appliance - Powered by TurnKey Linux