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.

WEC7 A8 2.0 BSP touch calibrate

Other Parts Discussed in Thread: AM3517, OMAP3530

I do not have an EVM to try this on but I have a platform that is very close to the EVM.

I am having issues with the touch calibration under WEC7. I know the hardware is ok as I have everything working fine under CE6.

The new WEC7 2.0 BSP uses the new stream based touch driver. I am using it exactly like the 2.0 and all the hardware seems to be initializing correctly also but when it calls  TouchCalibrate(); function from the PDDCalibrationThread() in touchscreenpdd.cpp it just returns and I do not get the calibration screen.  Same when I call from the control panel stylus icon....it just returns.

I do NOT have the IMGNOCALIBRATION environment variable set and have no calibration data in the registry on start up.

The driver seems to be loading correctly as I can step through the TchPdd_Init routine, It seems to be fine ..it even stalls waiting for the GWES API  to be available then continues as expected. Its just the calibration is not working as I expected.

Any ideas? Is the calibration working on the 35XX EVM under WEC7?

 

 

 

  • Touch calibration works on OMAP3530 EVM and AM3517 board.

    Have you checked the registry settings?

    -Tao

  • Also, TouchCalibrate() has a return value. If it returns FALSE, are you able to retrieve the error by calling GetLastError()?

    -Tao
  •  

    I ported the original touch driver from CE6 to WEC7 and it works just fine. The calibration screen comes up and everything is fine. The WEC7 35xx stream based touch driver has the issue. I can see the call to TouchCalibrate returns BAD_DRIVER. I have access to the premium source and can step into the touch.cpp private source. I can see it call to TouchGetCalibrationPointCount where it fails at:

        if ( !v_fTouchInitialized ||

             !v_pfnTouchPanelGetDeviceCaps )

            {

            SetLastError(ERROR_BAD_DRIVER);

            return FALSE;

            }

     

    The v_fTouchInitialized is valid but v_pfnTouchPanelGetDeviceCaps is not. As  far as I can tell this is a pointer to the old ddsiTouchPanelGetDeviceCaps I see no equivilent IOCTL for the new stream driver method. Maybe I am missing something but don't know what it could be.

    Also on a side note you need to add:

     

    .

    .

    .

        debounce.gpioId = s_TouchDevice.nPenGPIO;

        debounce.debounceTime = 10;

     

        GPIOIoControl(s_TouchDevice.hGPIO, s_TouchDevice.nPenGPIO,

                      IOCTL_GPIO_SET_DEBOUNCE_TIME, (UCHAR*)&debounce, sizeof(debounce), NULL, 0, NULL);

     

    The GPIOIoControl for setting debounce was missing from previous versions but now is implemented.

     

  • Looks like its the Tchproxy is responsible for the translation.

    Looks like my tchproxy driver registry settings are not set and the proxy driver is not loading.

    I have the touch components from the catalog added but will have to dig a little deeper to see whats up.

  • I added manually added to the registry:

    [HKEY_LOCAL_MACHINE\HARDWARE\DEVICEMAP\TOUCH]
        "DriverName"="tchproxy.dll"
    [HKEY_LOCAL_MACHINE\SYSTEM\GWE\TouchProxy]
        "tchcaldll"="tchcaldll.dll"

    And added the the same dlls to to platform.bib file.

    Now every thing works fine with the stream based driver.

    I have all the touch components from the catalog added to my osdesign so I do not understand why these were not added automatically.

    From common.reg:

    IF IMGTPC
    ; @XIPREGION IF TOUCH_COMPONENTS

    ; GWES loads tchproxy.dll
    [HKEY_LOCAL_MACHINE\HARDWARE\DEVICEMAP\TOUCH]
        "DriverName"="tchproxy.dll"

    ; touch calibration dll used by touchproxy. Can omit only if touch driver has its own calibration routines
    [HKEY_LOCAL_MACHINE\System\GWE\TouchProxy]
        "tchcaldll"="tchcaldll.dll"

    ; @XIPREGION ENDIF TOUCH_COMPONENTS
    ELSE
    IF BSP_NOTOUCH !
    ; @XIPREGION IF TOUCH_COMPONENTS

    ; GWES loads tchproxy.dll
    [HKEY_LOCAL_MACHINE\HARDWARE\DEVICEMAP\TOUCH]
        "DriverName"="tchproxy.dll"

    ; touch calibration dll used by touchproxy. Can omit only if touch driver has its own calibration routines
    [HKEY_LOCAL_MACHINE\System\GWE\TouchProxy]
        "tchcaldll"="tchcaldll.dll"

    ; @XIPREGION ENDIF TOUCH_COMPONENTS
    ENDIF BSP_NOTOUCH !
    ENDIF IMGTPC
    ; @CESYSGEN ENDIF CE_MODULES_TOUCH

     

    I do not know where or how the TOUCH_COMPONENTS tag gets set or why this is prefixed with the @XIPREGION

     

  • I had BSP_NOTOUCH set in my BSP's .bat file ..... DUH!