Touch Screen (FT6X06) how to use Touch Index Range

For general Flowcode discussion that does not belong in the other sections.
Post Reply
stefan.erni
Valued Contributor
Posts: 758
http://meble-kuchenne.info.pl
Joined: Wed Dec 02, 2020 10:53 am
Has thanked: 149 times
Been thanked: 171 times

Touch Screen (FT6X06) how to use Touch Index Range

Post by stefan.erni »

Hi Ben

I use a touchscreen with a FT6336U controller and it's working if I use Touch Index Range 0.
The touchscreen give the coordinate back, but for x max 24 and for y max 22 if i set to 360 pixel touchscreen.

If I set the touch index range to 1 it' give back always 0

I can very easy use the touchscreen with index range 0 but is this the way?

I did not found a information about Touch Index Range in the help.

regards

Stefan

BenR
Matrix Staff
Posts: 1739
Joined: Mon Dec 07, 2020 10:06 am
Has thanked: 440 times
Been thanked: 603 times

Re: Touch Screen (FT6X06) how to use Touch Index Range

Post by BenR »

Hi Stefan,

The touchscreen should be able to detect up to two simultaneous touches to allow for things like pinch gestures, the first touch being in index 0 and the second being at index 1. So index 1 should have data but only when you have two fingers on the display.

stefan.erni
Valued Contributor
Posts: 758
Joined: Wed Dec 02, 2020 10:53 am
Has thanked: 149 times
Been thanked: 171 times

Re: Touch Screen (FT6X06) how to use Touch Index Range

Post by stefan.erni »

Hi Ben

Ah it's like this.
One more little question. I have a 320*240 display and the touchscreen set to the same values. The touchscreen gives me 24 for x and 15 for y as the maximum touch coordinates.
This is very useful for evaluating a key, but is that ok?


regards

Stefan

BenR
Matrix Staff
Posts: 1739
Joined: Mon Dec 07, 2020 10:06 am
Has thanked: 440 times
Been thanked: 603 times

Re: Touch Screen (FT6X06) how to use Touch Index Range

Post by BenR »

Hi Stefan,

That seems a bit low, what if you change the single ended/double ended property to see if this improves things at all.

stefan.erni
Valued Contributor
Posts: 758
Joined: Wed Dec 02, 2020 10:53 am
Has thanked: 149 times
Been thanked: 171 times

Re: Touch Screen (FT6X06) how to use Touch Index Range

Post by stefan.erni »

Hi Ben
Single/double made no change
I2C hardware/software and speed made no change (always working)
But if I double the number of x,y pixels, the result also doubles.
If I use 30000x,y pixel the maximal result is about 2336,2048

just like the display: Is it possible to expose the "send/get reg and send/get data macros"?
I like to try if gesture is working in a way
regards

Stefan

gesture
gest_2022-07-20_18-55-46.jpg
gest_2022-07-20_18-55-46.jpg (37.26 KiB) Viewed 1305 times

BenR
Matrix Staff
Posts: 1739
Joined: Mon Dec 07, 2020 10:06 am
Has thanked: 440 times
Been thanked: 603 times

Re: Touch Screen (FT6X06) how to use Touch Index Range

Post by BenR »

Hi Stefan,

I've now exposed the Read and Write bytes macros for you that allows you to read and write the register values.

stefan.erni
Valued Contributor
Posts: 758
Joined: Wed Dec 02, 2020 10:53 am
Has thanked: 149 times
Been thanked: 171 times

Re: Touch Screen (FT6X06) how to use Touch Index Range

Post by stefan.erni »

Hi Ben

Thanks a lot.
I've read the gesture register but this is always 00. I've googled and many have problems with it. I keep looking.
I also read the X position and this is a maximum of 320 pixels and independent of the component x size propertie.

regards

Stefan

X_new code:
x_new_2022-07-21_14-15-01.jpg
x_new_2022-07-21_14-15-01.jpg (15.27 KiB) Viewed 1287 times

Post Reply