This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

AM3517 EVM touch screen app

Other Parts Discussed in Thread: AM3517

Hi all

I was writing PowerVR applications over am3517 evm, trying to get input from the on-board touch screen, and this statement was implemented in RenderScene() in my program:

 

float *pfTouch=0;

pfTouch = (float*) PVRShellGet(prefPointerLocation);

But it always returned 0, if it means that the touch screen was not functioning? Or maybe I missed some settings to active the touch screen? or lack of some software packages? need help.

thanks

 

  • Hi erwin xu,

    The touch screen support is NOT enabled (build time) by default in the PVRShell

    Simple way to enable this is to add the below define in "./GFX_Linux_SDK/OGLES/SDKPackage/Shell/OS/LinuxRaw/PVRShellOS.h" file at the top.

    #define PVRSHELL_OMAP3_TS_SUPPORT

    And, update *.mak files to add the paths to ts include and library files as shown in the sample example below.

    1.  ./GFX_Linux_SDK/OGLES/SDKPackage/Builds/OGLES/LinuxGeneric/make_demo.mak

    .......

    INCLUDES += -I$(SDKDIR)/Tools/OGLES                                             \
                            -I$(SDKDIR)/Shell                                                               \
                            -I$(SDKDIR)/Shell/API/KEGL                                              \
                            -I$(SDKDIR)/Builds/OGLES/$(PLATFORM)/Include    \
                            -I$(SDKDIR)/Builds/OGLES/Include                                \
                            -I$(SHELLOSPATH)                                                                \
                            $(addprefix -I, $(PLAT_INC))                                    \
                            -I../../.. \
                            -I/proj/AVME10/mahesh/Graphics/tscreen/targetfs/include

    .....

    LINK            += -L/proj/AVME10/mahesh/Graphics/tscreen/targetfs/lib

    ....

    2.  /GFX_Linux_SDK/OGLES/SDKPackage/Builds/OGLES/LinuxOMAP3/make_platform.mak
      PLAT_LINK =  $(LIBDIR_FLAGS) -lts -lGLES_CM $(X11_LIBS) -lm -ldl

     

    Prior to the above steps, you require to build and install the touch screen module into the target file system

    source is available at http://prdownload.berlios.de/tslib/tslib-1.0.tar.bz2

    And calibrate the touch screen on the target by running

    ts_calibrate

    Please let me know if you face any issue.

    regards,

    Mahesh.

  • Hi Mahesh

    I have solved this, I install and setup tslib, took a good look at the exsamples, and now I can handle it, thank you very much.

    erwin