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.

WinCE TWLOpen()

Other Parts Discussed in Thread: OMAP3530

Customer has the following question using WinCE6.13/6.14 on OMAP3530

 

Have an issue with TWLOpen().

 

Want to use TWL to manage our proprietary CPLD interrupt. I need to call TWLOpen() to get the HANDLE, however it failed with error 55 - ERRO_DEV_NOT_EXIST. It is an exclusive bus driver or can be shared?  Noticed there are lot of places that uses TWLOpen() such as in GPIO, KEYPAD, BCI, PWRKEY etc, etc. Don't understand how to use it.

Lawrence

  • It is the driver for TPS659xx chip - all the peripherals you mentioned are controlled by this chip and therefore you see it in many places. All register read/writes from this chip occur on I2C bus. Unless your CPLD is somehow controlled by this chip, you cannot use this driver

     

    Atul

  • Atul,

    Let me ask the quetion differently, the desire is to have the TPS659xx GPIO to accept an interrupt from the CPLD, which will then interrupt the OMAP35x. How can this be setup?

    Lawrence

  • This should be fairly easy. Assuming HW is hooked up, you will have to configure appropriate settings in TPS chip (for GPIO interrupt etc) using the TWL driver. Then you will have to create an Event, hook it up to TWL interrupt and wait for the event to occur. TWL driver upon getting an interrupt will signal the appropriate event, which in turn will come to your thread if it is the one that you created.  You can look at DRIVERS\HEADSET\headset.cpp to see some sample code sequence (you can look at keypad or other drivers as well which use TWL driver)

    Atul