2009-11-16 17:06:04     ads7846 driver issue

Document created by Aaronwu Employee on Aug 19, 2013
Version 1Show Document
  • View in full screen mode

2009-11-16 17:06:04     ads7846 driver issue

Bryan DE FARIA (UNITED STATES)

Message: 82419   

 

Hi,

 

I am using a tsc2046 chip with the ads7846 driver. This my bf537 stamp configuration :

 

#if defined(CONFIG_TOUCHSCREEN_ADS7846) || defined(CONFIG_TOUCHSCREEN_ADS7846_MODULE)

static struct bfin5xx_spi_chip spi_ads7846_chip_info = {

    .cs_change_per_word = 0,

    .enable_dma = 0,

    .bits_per_word = 8,

    .cs_gpio= GPIO_PF6,

};

 

 

static int ads7846_pendown_state(void)

{

    int value;

    value = gpio_get_value(GPIO_PF7);

    return value;

}

 

 

static struct ads7846_platform_data bfin_ads7846_ts_info = {

    .model        = 7846,

    .vref_delay_usecs = 100,

    .x_min        = 150,

    .x_max        = 0x0fff,

    .y_min        = 190,

    .y_max        = 0x0fff,

    .x_plate_ohms    = 310,

    .y_plate_ohms    = 230,

    .pressure_max    = 1500,

    .pressure_min    = 0,

    .debounce_max    = 10,

    .debounce_tol    = 3,

    .debounce_rep    = 1,

    .get_pendown_state    =ads7846_pendown_state,

};

#endif

 

#if defined(CONFIG_TOUCHSCREEN_ADS7846) || defined(CONFIG_TOUCHSCREEN_ADS7846_MODULE)

{

        .modalias        = "ads7846",

          .platform_data        = &bfin_ads7846_ts_info,

        .irq            = IRQ_PF7,

        .max_speed_hz    = 2000000,     /* max spi clock (SCK) speed in HZ */

        .bus_num    = 0,

        .chip_select  = 0,

        .controller_data = &spi_ads7846_chip_info,

        .mode = SPI_MODE_0,

},

#endif

 

 

 

 

 

My issue is when the touchscreen is used with fingers with fast movements during about 20 seconds, the sytem freezes without an error message and restart a few seconds later.

 

It doesn't happen with a pen, in observing the interruption pin with an oscilloscope I noticed that with fingers a lot interruptions are generated whereas with a pen it does not.

 

Is it possible to fix it, like in using a timer instead of interruption?

QuoteReplyEditDelete

 

 

2009-11-16 17:21:20     Re: ads7846 driver issue

Mike Frysinger (UNITED STATES)

Message: 82420   

 

the ads7846 driver is not for Analog Devices (as you might think the "ad" prefix indicates).  it's a TI part.  the tsc2046 part is also from TI.  so please seek assistance from TI and/or the driver author (look at the history of the driver to find out who wrote it).

Attachments

    Outcomes