nanogui: Thread: My touchscreen driver gives strange results!


[<<] [<] Page 1 of 1 [>] [>>]
Subject: My touchscreen driver gives strange results!
From: ####@####.####
Date: 23 Jul 2007 11:59:50 +0100
Message-Id: <1185188296.10824.22.camel@localhost>

Hi people!

I've added my own touchscreen driver to the mou_touchscreen driver, and
even written my own kernel driver (since all touch data comes from a
slave processor via I2C).

It does work, but a single touch is not triggering the touch event in
Nano-X! I have to move around on the screen to make it trigger.

My driver does not "spit" data all the time or anything. Only when the
touchscreen is touched, it delivers X and Y and a touch event.
When moving your finger, it delivers the new X and Y data and a move
event.
And finally it delivers a untouch even when the finger has left.

All this comes from my /dev/touchscreen with a read of 3*32bits (x+y
+event).

When using a debug application which just read /dev/touchscreen and
print out all events + coords, it works perfectly and is fast.
But when using Nano-X it does not react on a touch until i move my
finger around.

It seems like it's dropping the first events!
Even when adding debug prints within the PD_Read, it all works great,
but it still doesn't make an GR_EVENT_TYPE_BUTTON_DOWN event!

I'm really lost here, so please help me get in the right direction to
fix this.

Best regards
Daniel


Subject: Re: [nanogui] My touchscreen driver gives strange results!
From: ####@####.####
Date: 23 Jul 2007 13:59:15 +0100
Message-Id: <1185195432.27621.5.camel@localhost>

Release is not a problem when the "press" finally has gone through.

It's just that I want to make a BUTTON_DOWN event when I get a touch
event from my touchscreen driver.
Other drivers seems to spit out alot of data when holding the finger
down, so if first event is dropped it won't be noticed since next one is
comming so fast.
My driver doesn't work that way. Might this be the problem?

On Mon, 2007-07-23 at 12:49 +0100, Robin Clark wrote:
> are you sending release events (i.e. pressure <= 49 )
> to indicate the press has finished ?
> 
> hay door
> 
> Robin
> 
> 
> --- Daniel Nyström ####@####.####
> wrote:
> 
> > Hi people!
> > 
> > I've added my own touchscreen driver to the
> > mou_touchscreen driver, and
> > even written my own kernel driver (since all touch
> > data comes from a
> > slave processor via I2C).
> > 
> > It does work, but a single touch is not triggering
> > the touch event in
> > Nano-X! I have to move around on the screen to make
> > it trigger.
> > 
> > My driver does not "spit" data all the time or
> > anything. Only when the
> > touchscreen is touched, it delivers X and Y and a
> > touch event.
> > When moving your finger, it delivers the new X and Y
> > data and a move
> > event.
> > And finally it delivers a untouch even when the
> > finger has left.
> > 
> > All this comes from my /dev/touchscreen with a read
> > of 3*32bits (x+y
> > +event).
> > 
> > When using a debug application which just read
> > /dev/touchscreen and
> > print out all events + coords, it works perfectly
> > and is fast.
> > But when using Nano-X it does not react on a touch
> > until i move my
> > finger around.
> > 
> > It seems like it's dropping the first events!
> > Even when adding debug prints within the PD_Read, it
> > all works great,
> > but it still doesn't make an
> > GR_EVENT_TYPE_BUTTON_DOWN event!
> > 
> > I'm really lost here, so please help me get in the
> > right direction to
> > fix this.
> > 
> > Best regards
> > Daniel
> > 
> > 
> > 
> >
> ---------------------------------------------------------------------
> > To unsubscribe, e-mail:
> > ####@####.####
> > For additional commands, e-mail:
> > ####@####.####
> > 
> > 
> 
> 
> 
>       ___________________________________________________________
> Yahoo! Answers - Got a question? Someone out there knows the answer. Try it
> now.
> http://uk.answers.yahoo.com/ 


Subject: Re: [nanogui] My touchscreen driver gives strange results!
From: ####@####.####
Date: 24 Jul 2007 08:01:49 +0100
Message-Id: <1185260414.6578.2.camel@localhost>

Shouldn't that be in the specific driver?
I do all avaraging in the coprocessor, all results are "final" when they
reach Nano-X.
Anyone know how to fix this? Or should I "fake" alot of touch info to
make Nano-X work? Seems like a veeery ugly fix to me.

Any suggestions, please?

On Mon, 2007-07-23 at 16:10 +0100, Robin Clark wrote:
> very probably. I do aot of filtering and averaging ut
> I 
> saw that nano X does this as well.


Subject: AW: [nanogui] My touchscreen driver gives strange results!
From: "Wein, Peter (ext)" ####@####.####
Date: 27 Jul 2007 10:48:37 +0100
Message-Id: <0C9BD57BDE7F5947B6E8AF9C655EBD99D3A93D@khes0e1a.ww001.siemens.net>

My touch driver works over spi connection. After the press down irq is sent to my driver, it will start a workqueue tasklet which won't finish measuring data until the job is done (for ads7846, if the measured pressure value went above 200000 for example (cause it is inversely proportional in my case). Only then it will stop sending data.  I use a ring structure to send the data. Wokrqueue tasklet is sending  a wake up signal to my wait event queue. With poll method my read function awakes and starts sending data oz of the ring structure. 

The structure only contains x and y (32-bit as well for the matrix transformation algorithm) and pressure 1 or 0. This will well work for mou_touchscreen.c and devmouse.c.

Hope this will help you.

Cheers Peter  

P.S.: By the way, maybe you also have to be aware of distortions during the analogous measurement of the controller. Every measurement also includes dummy measuremnts, before measuring each x, y, z1 and z2 value. Afterwards I also have to sort out and average the sent data (awful story)).

-----Ursprüngliche Nachricht-----
Von: Daniel Nyström ####@####.#### 
Gesendet: Montag, 23. Juli 2007 14:57
An: Robin Clark
Cc: ####@####.####
Betreff: Re: [nanogui] My touchscreen driver gives strange results!

Release is not a problem when the "press" finally has gone through.

It's just that I want to make a BUTTON_DOWN event when I get a touch
event from my touchscreen driver.
Other drivers seems to spit out alot of data when holding the finger
down, so if first event is dropped it won't be noticed since next one is
comming so fast.
My driver doesn't work that way. Might this be the problem?

On Mon, 2007-07-23 at 12:49 +0100, Robin Clark wrote:
> are you sending release events (i.e. pressure <= 49 )
> to indicate the press has finished ?
> 
> hay door
> 
> Robin
> 
> 
> --- Daniel Nyström ####@####.####
> wrote:
> 
> > Hi people!
> > 
> > I've added my own touchscreen driver to the
> > mou_touchscreen driver, and
> > even written my own kernel driver (since all touch
> > data comes from a
> > slave processor via I2C).
> > 
> > It does work, but a single touch is not triggering
> > the touch event in
> > Nano-X! I have to move around on the screen to make
> > it trigger.
> > 
> > My driver does not "spit" data all the time or
> > anything. Only when the
> > touchscreen is touched, it delivers X and Y and a
> > touch event.
> > When moving your finger, it delivers the new X and Y
> > data and a move
> > event.
> > And finally it delivers a untouch even when the
> > finger has left.
> > 
> > All this comes from my /dev/touchscreen with a read
> > of 3*32bits (x+y
> > +event).
> > 
> > When using a debug application which just read
> > /dev/touchscreen and
> > print out all events + coords, it works perfectly
> > and is fast.
> > But when using Nano-X it does not react on a touch
> > until i move my
> > finger around.
> > 
> > It seems like it's dropping the first events!
> > Even when adding debug prints within the PD_Read, it
> > all works great,
> > but it still doesn't make an
> > GR_EVENT_TYPE_BUTTON_DOWN event!
> > 
> > I'm really lost here, so please help me get in the
> > right direction to
> > fix this.
> > 
> > Best regards
> > Daniel
> > 
> > 
> > 
> >
> ---------------------------------------------------------------------
> > To unsubscribe, e-mail:
> > ####@####.####
> > For additional commands, e-mail:
> > ####@####.####
> > 
> > 
> 
> 
> 
>       ___________________________________________________________
> Yahoo! Answers - Got a question? Someone out there knows the answer. Try it
> now.
> http://uk.answers.yahoo.com/ 



---------------------------------------------------------------------
To unsubscribe, e-mail: ####@####.####
For additional commands, e-mail: ####@####.####

Subject: Re: AW: [nanogui] My touchscreen driver gives strange results!
From: ####@####.####
Date: 6 Aug 2007 08:48:00 +0100
Message-Id: <1186386393.6621.8.camel@localhost>

Thanks for your helpful description!
But does your workqueue tasklet send a wakeup signal to the wait queue
once for each measurement?
Let's say you write a loop which uses a blocking read on your driver,
and then print out coordinates as it comes from the device.
Does it print out many lines for each press, or does it average one
coord for each touch?
My driver does the later.

I've also changed my driver to work like (what I think) other
touchscreen drivers. As long as you hold your finger down, it keep
delivering XY data, and when you release your finger, it'll stop (with a
finishing data with pressure set to 0).

It still won't work with mou_touchscreen.c !

I've added a printf to the "Read" which tells me all data goes into
nano-X. But nano-X doesn't trigger a "mouser down" event.

I'm doing all AD handling within an coexisting Atmel AVR which as well
does the averaging in prior to sending it to the main CPU.

On Fri, 2007-07-27 at 11:47 +0200, Wein, Peter (ext) wrote:
> My touch driver works over spi connection. After the press down irq is sent to my driver, it will start a workqueue tasklet which won't finish measuring data until the job is done (for ads7846, if the measured pressure value went above 200000 for example (cause it is inversely proportional in my case). Only then it will stop sending data.  I use a ring structure to send the data. Wokrqueue tasklet is sending  a wake up signal to my wait event queue. With poll method my read function awakes and starts sending data oz of the ring structure. 
> 
> The structure only contains x and y (32-bit as well for the matrix transformation algorithm) and pressure 1 or 0. This will well work for mou_touchscreen.c and devmouse.c.
> 
> Hope this will help you.
> 
> Cheers Peter  
> 
> P.S.: By the way, maybe you also have to be aware of distortions during the analogous measurement of the controller. Every measurement also includes dummy measuremnts, before measuring each x, y, z1 and z2 value. Afterwards I also have to sort out and average the sent data (awful story)).
> 

[<<] [<] Page 1 of 1 [>] [>>]


Powered by ezmlm-browse 0.20.