Galaxy S4 touchscreen low-level access - Hardware Hacking General

For my research in gesture recognition I need to interface with Galaxy S4 touchscreen. I would like to receive "raw" data from touchscreen driver, not Android events. I must admit I am do not know much about low-level Android, although I know a bit about Linux/BSD dev., so I am not totally clueless (I hope) I was wondering if any of Android gurus can help me to get starting by answering few questions:
1. When building custom ROM, where device drivers (touchscreen in particular) come from?
2. Are they binary or source code?
3. Anybody done some reverse-engineering of digitizer API?
In particular I am interested in touch screen proximity "hovering"/"air touch" on S4. It looks like touch screen sensor on S4 could detect finger presence even when it is not yet touching the screen. Some touch screens theoretically could do this (capacity sensors) but I am curios to see what information is sent from sensor to OS and how it could be interpreted.

Related

[App Req] Biometric Security

There are devices coming out with Biometric (fingerprint security). Thought it was really cool when it came out for your desktop computers. Was hoping someone would have developed it here. After a decent search through the archives, target acquired unsuccessful.
Maybe I missed an app that speaks to this. Let me know if you see anything.
I doubt it is possible using touchscreen. The sensor can detect only one point. It is nowhere close to reading papillary lines.
Did you know that lots of these touch sensors are mini cameras infact?
And if you need a device with finger recognition, HTC made one and unluckily it uses a typical fingerprint reader. So it seems we won't be able to unlock our Diamonds with fingerprints.
kosherpig said:
I doubt it is possible using touchscreen. The sensor can detect only one point. It is nowhere close to reading papillary lines.
Did you know that lots of these touch sensors are mini cameras infact?
And if you need a device with finger recognition, HTC made one and unluckily it uses a typical fingerprint reader. So it seems we won't be able to unlock our Diamonds with fingerprints.
Click to expand...
Click to collapse
Well that explains why it has yet to arrive.....that's because it's not coming at all...lol
Ok, thanks for that!
In theory, a program could be made that would unlock the phone when it detects your face. Some programs exist like this for certain laptops that have webcams built into the top of the screen.
This would be pretty inconvenient unless your phone has a front-facing camera, though, and it would probably be slower on Windows Mobile than just entering a PIN.
Cythrelo said:
In theory, a program could be made that would unlock the phone when it detects your face. Some programs exist like this for certain laptops that have webcams built into the top of the screen.
This would be pretty inconvenient unless your phone has a front-facing camera, though, and it would probably be slower on Windows Mobile than just entering a PIN.
Click to expand...
Click to collapse
Yeah, well the goal here is convenience and added security. Punching in numbers is not too bad but there is always that sneak suspicion that someone is watching you. Face or Finger recognition would be cool is it tends to eliminate the lose of security unless someone looks like you. i.e. twins...

FROYO on Blackstone - Touch Screen Calibration

Right, since this is such a significant impairment (and some users don't seem to experience it), I decided to create a separate thread for it:
If anyone finds out how to properly CALIBRATE the touchscreen on Froyo on Blackstone, please post it here.
So far, the "msmts_calib=0x395.0x3c9.0x79.0x77" results in random keys etc being pressed on the left hand side of the screen.
Thanks
z.
zero0007 said:
Right, since this is such a significant impairment (and some users don't seem to experience it), I decided to create a separate thread for it:
If anyone finds out how to properly CALIBRATE the touchscreen on Froyo on Blackstone, please post it here.
So far, the "msmts_calib=0x395.0x3c9.0x79.0x77" results in random keys etc being pressed on the left hand side of the screen.
Thanks
z.
Click to expand...
Click to collapse
well, there is a bigger problem as the calibration part ...
in froyo it seems to be, that the calibration willb e done automatical and it is not necc. to do anything extra...
but the module/driver for touchscreen is buggy ...
better for testing is the app dotty (can be downloaded from market).
there you'll see, that if you press via finger middle botton, that it jumps on screen touch to left botton - only sometimes ......and with this bug it is almost not possible to use the phone via fingers ...
my boot paramter for calibration is: msmts_calib=0x395.0x3c9.0x79.0x77
but as told above ... the problem is the touchscreen doesn't work correct if using finger ...
if you use the stylus, then it is working, so i think it is a bug, that if the touchscreen driver is getting multiple zones on touching the display, then something strange happen, and then it add an extra point on the left side, which makes using keyboard (SIP) almost impossible.
the only questions would be: does this bug also happenon 2.1 ?
because it it is there working, then we can try to implement the driver from 2.1.
cu camel
Slow down...
Slow down guys...
For 99% of users the calibration works fine, you're in the minority experience tolerance issues.
Touchscreens drift over time, and with heat fluctuations (quite dramatic ones only) etc.
You guys are just unlucky and have devices that have clearly drifted by some amount....
Now, there ARE instructions floating around about how to fix calibration issues, but they aren't on the Blackstone thread, they are elsewhere and I can't recall quite where, but they DO exist.
When it comes to used a finger instead of a stylus, here you just have to live with the differences between a resistive and capacitive touchscreen. Resistive is the one used on Blackstone and most other touchscreens older than 18 months old, whilst never devices tend to have capacitive screens.
What's the difference?
Resistive need physical pressure against the screen, but can be highly accurate in ONE position. You can use these screens with or without a stylus, so can be good for handwriting recognition etc.
Capacitive need NO physical pressure against the screen, but are less accurate.
However they can detect multiple presses at the same time in different parts of the screen.
You can't easy use these screens with a normal stylus and so they aren't ideal for handwriting recognition or fine detail work.
When it comes to using your finger on resistive screen, a lot of accuracy is lost... you're just pressing a large area of the screen and the screen can only deduce ONE point under your finger. This can lead to inaccuracy and wrong buttons being pressed with a UI that has tiny icons and controls.
If your touch calibration is ALSO out, then things get worse still.
Now, before any techies get too techy, there ARE some 'smart' techniques for trying to have multi-touch on resistive displays, but we will no go into that here, and they are generally 'hacks' that don't work in all scenarios.
You guys just need to get your displays recalibrated... that should cure 95% of all your problems, and the remaining 5% are just the stuff we all face... like no multitouch, pinch to zoom etc
It's definitely wrong to give the impressions that XDAndroid releases simply don't work correctly with touch screen. That's very misleading indeed.
i too have issues with touch screen accuracy (both 2.1a and 2.2 v1.0)
80% of the presses are fine, but the other 20% xdandroid would place my finger about 1" to the right, slightly down of when i first contact the screen, and then work out where i've actually pressed a fraction of second later, translating it into a swipe etc.
the touchscreen tool in the debug area proves this fact.
WM is perfect.
weirdly, it seems not to occur at all/noticably less using the stylus. maybe something todo with pressure/contact area?
i do think the OP has a valid issue tbh.
TheBrilliantMistake said:
Slow down guys...
For 99% of users the calibration works fine, you're in the minority experience tolerance issues.
Touchscreens drift over time, and with heat fluctuations (quite dramatic ones only) etc....
Click to expand...
Click to collapse
Thanks for the info.
First, I didn't mean to mislead anyone. I just noticed increased inquiries about this issue and I wasn't aware of the 99% of users having it perfectly working...is this a fact btw?
Besides, I am aware of the different types of displays but obviously, pinch zoom etc are not exactly the main concern, we are just looking to use the phone with our fingers mate!
I agree - I have been using the phone for many months running WM and I had no issue, whatsoever. I am not much of a techie but you are still referring to the software calibration, correct?
Thanks for sharing some valuable info again. I would love to see those instruction on how to do this calibration as without it and along with much of resentment to use stylus, it pretty much makes the phone running Froyo useless )
zero0007 said:
Thanks for the info.
First, I didn't mean to mislead anyone. I just noticed increased inquiries about this issue and I wasn't aware of the 99% of users having it perfectly working...is this a fact btw?
Besides, I am aware of the different types of displays but obviously, pinch zoom etc are not exactly the main concern, we are just looking to use the phone with our fingers mate!
I agree - I have been using the phone for many months running WM and I had no issue, whatsoever. I am not much of a techie but you are still referring to the software calibration, correct?
Thanks for sharing some valuable info again. I would love to see those instruction on how to do this calibration as without it and along with much of resentment to use stylus, it pretty much makes the phone running Froyo useless )
Click to expand...
Click to collapse
But windows mobile typically makes you calibrate your screen when you reflash a ROM, making the calibration specific to your device.
It's also not clear where the calibration info is stored, other than the registry it MAY be stored in E2, or some flash area somewhere. Regardless, it usually forces you to recalibrate (some custom ROMs skip this).
The XDAndroid chaps deemed to 'auto configure' Blackstone calibration for some reason, and this is the most probable reason why folks are having issues.
As for 99%, hummm well, just my releases alone have over 20,000 downloads, and my stuffs one of the lesser used!... yes, some folks have calibration issues, but the majority aren't reporting any... I've maybe seen/heard 20 folks with the issue... that's not too many all in all across all the various releases. AND, some of those guys were also the types of guys saying "this sucks, the battery lasts 2 hours".... as if we didn't all know that ;-)
There was a calibration tool floating around somewhere, plus, those values CAN be edited to suit your device, so there is some home!
Wow, I thought I was one of the only people that had the calibration issue. X_X It's what caused me not to use XDAndroid as much. =(
Anyone have any idea what the calibration tool was? I tried searching calibrate and calibration but no tool was mentioned in the Blackstone droid threads.
PS. I have no idea on how to change the calibration values... =/ When I open up the ts_calibration it shows up as blank. When I open up the startup.txt ("msmts_calib=0x395.0x3c9.0x79.0x77") I do not know exactly what the values affect.
Update:
I tried using the stylus but it currently has the same problem as if I was just using my finger... Does that mean that my touch screen is going out on me? =(
I have a problem too with touch screen calibration.....I guess i'm 1% of users...
im curious as to how maany others have this issue - seems theres a few coming out of the woodwork now
im sure the XDAndroid FAQ or the release thread says the devs are aware of almost all issues so dont bother reporting them (or something to that effect), yet i havent seen anyone mention touchscreen issues upto this thread.
does anyone see a need for a bugtracker for the XDAndroid, or are the forums sufficient? to me, forums seem a bit 'unofficial' with reguard to bugs - maybe an official bug tracker (specific to the android project) would help everyone to see what people are experiencing and numbers involved.
i must say i am only a user, so i dont see or get involved in the development side so maybe this thing already exists in closed circles.
to put it another way, each phone has their own android subforum so it must take the devs alot of time to collate info. bug tracker could be a better way to manage this?
I have the same problem, since 1.6... i touch the screen and is like i touched 1cm outside the screen on the left for 0.001 seconds, so is extremly difficult to type without stylus.
with the stylus is much better but still not good
Ps. i remember the first version of android working on blackstone (1.5 i think) was working good, and the touch screen was fine
veehexx said:
im curious as to how maany others have this issue - seems theres a few coming out of the woodwork now
im sure the XDAndroid FAQ or the release thread says the devs are aware of almost all issues so dont bother reporting them (or something to that effect), yet i havent seen anyone mention touchscreen issues upto this thread.
does anyone see a need for a bugtracker for the XDAndroid, or are the forums sufficient? to me, forums seem a bit 'unofficial' with reguard to bugs - maybe an official bug tracker (specific to the android project) would help everyone to see what people are experiencing and numbers involved.
i must say i am only a user, so i dont see or get involved in the development side so maybe this thing already exists in closed circles.
to put it another way, each phone has their own android subforum so it must take the devs alot of time to collate info. bug tracker could be a better way to manage this?
Click to expand...
Click to collapse
I was actually thinking about the same thing..unsure how to proceed though...
mitikos said:
I have the same problem, since 1.6... i touch the screen and is like i touched 1cm outside the screen on the left for 0.001 seconds, so is extremly difficult to type without stylus.
with the stylus is much better but still not good
Ps. i remember the first version of android working on blackstone (1.5 i think) was working good, and the touch screen was fine
Click to expand...
Click to collapse
I would dig up that version along with calib code in the startup txt file then!
well, i've put the idea forward in the main android subforum here.
it would certainly be useful from a user side perspective to see progress and known issues. fingers crossed
edit: and when did i move to 'Senior member'!!?
I experience similar issues with 2.2, didn't notice it to the same extent in 2.1. When I type on the on screen keyboard, pretty often i get an added button press detected off to the left (about 2 - 3 cm). The problem does occur a lot less when using the stylus instead of the finger.
This is NOT likely to be a calibration problem, as in that case all presses would be off consistently (e.g. always half a centimeter in the wrong direction or something like that).
It looks as if the Touchscreen sends some "incorrect" data that WM filters as too short of a press or whatever and that is affecting some users.
mmm, questionable.
Calibration is as far as I'm concerned done each time, individually with new system (ROM) unless using a saved one from previous attempt install (my Froyo case).
To my understanding of the matter, wrong calibration doesn't necessarily have to mean your display is "shifted" 2cm to the left or so. Simply, it just doesn't work properly i.e. you have the same problem as all other people in this thread.
Maybe reading TheBrilliantMistake's post about different types of screens earlier would help you understand...
after all, we need that calibration tutorial/tip which is allegedly somewhere around here...
StevieBallz said:
I experience similar issues with 2.2, didn't notice it to the same extent in 2.1. When I type on the on screen keyboard, pretty often i get an added button press detected off to the left (about 2 - 3 cm). The problem does occur a lot less when using the stylus instead of the finger.
This is NOT likely to be a calibration problem, as in that case all presses would be off consistently (e.g. always half a centimeter in the wrong direction or something like that).
It looks as if the Touchscreen sends some "incorrect" data that WM filters as too short of a press or whatever and that is affecting some users.
Click to expand...
Click to collapse
I have the same problem, exatly the same.
Cant we set android to ignore the first 0.1seconds of a pression on the screen?
StevieBallz said:
I experience similar issues with 2.2, didn't notice it to the same extent in 2.1. When I type on the on screen keyboard, pretty often i get an added button press detected off to the left (about 2 - 3 cm). The problem does occur a lot less when using the stylus instead of the finger.
This is NOT likely to be a calibration problem, as in that case all presses would be off consistently (e.g. always half a centimeter in the wrong direction or something like that).
It looks as if the Touchscreen sends some "incorrect" data that WM filters as too short of a press or whatever and that is affecting some users.
Click to expand...
Click to collapse
ah - finally
now you got it - this is exact the problem what i want to tell everybody ..., and i'm sure, that this happen, because the touch screen driver doesn't calculate correct the position when a bigger range (like touch from a finger) is touched. This doesn't happen, when stylus is used ...
to remove the first 0,1 sec or something ... don't think, that this would help
...on the other hand ... which module is responsible for touch screen ?
Just for a start the background of calibration (it's on security risks with touchscreen based voting machines but the principle is obviously the same) - http://vote.nist.gov/threats/papers/touchscreencalib.pdf
I believe TheBrilliantMistake in this case thought we'd sometimes hit adjacent buttons. But fact is, it always does trigger to the left and in addition to the correct press being detected, so well there's something else to this one.
Guess it will be ironed out eventually as it's a lot less common in 2.1. But it's annoying to the point of making texting a real pain in 2.2.
StevieBallz said:
Just for a start the background of calibration (it's on security risks with touchscreen based voting machines but the principle is obviously the same) - http://vote.nist.gov/threats/papers/touchscreencalib.pdf
I believe TheBrilliantMistake in this case thought we'd sometimes hit adjacent buttons. But fact is, it always does trigger to the left and in addition to the correct press being detected, so well there's something else to this one.
Guess it will be ironed out eventually as it's a lot less common in 2.1. But it's annoying to the point of making texting a real pain in 2.2.
Click to expand...
Click to collapse
does it means, that under 2.1 there is no such kind of "touchscreen bug with finger" ?, because then we can take a look to the modules - maybe we can compare the difference to 2.1 ...
I didn't experience it there but I have to admit that I didn't use 2.1 for too long. Maybe it's a speed issue with 2.1 being more optimized and polished then 2.2 which leads to it occuring on a less frequent basis.
Due to the known problems with powersafe modes not being supported yet in XDAndroid I'm currently mostly running WM6.5 but I'm looking forward to the advancements with XDAndroid, great project.
Add 2 more devices to the 1%.
I'm experience the same issue. My friend which has a newer Blackstone than me let me put my XDAndroid mSD card into his phone and there goes the same issue.
Tested with some drawing applications, here is what i experienced:
Just like others stated before most of the times when the bug occurs I get a line starting like 2 cm to the left of my finger (and a little lower) and ending under my finger. It's like I've been dragging my finger across the screen for 2 cm. Sometimes it goes as far as the left side of the screen.
Since this is inconsistent I doubt it's a calibration issue. I must assume it's the driver. But I might be wrong.
Anyway I believe a lot more people than 1% are experiencing the issue but they aren't posting about it since they believe it's a known issue.

Lenovo A3000-H "autoresponsive" touchscreen

Hi guys,
I have an Ideapad A3000-h from a relative lying in front of me, with something is "not working" as the only description I got. I noticed that apps would automatically start up or close and when I went to the options menu it randomly selected different entries without me doing anything. I got the impression that the touchscreen was getting 'signals' without anything or anyone actually touching it - I decided to call this 'autoresponsiveness'. I confirmed this hypothesis by making the touch actions visible via the developers menu (which was a pain in the *** with the tablet constantly inputting actions on its own) and sure enough, on the right centimetre of the screen I randomly get short touch impulses. They become faster, more erratic and generally occure more often if I myself touch the right margin on the screen.
I think this is an issue of the hardware and I would recommend to have the touch screen and digitizer swapped. However I don't have any experience with Lenovo stuff and I just wanted to ask if you guys have any ideas if this could be a software (potentially malware) issue. I don't think so, as my relative has allegedly already done a hard reset and the problem still persists. I just can't be completely sure if what was done was actually a real hard reset or just something that was mistaken for it by my technologically impaired relative
If anyone needs video to understand the underlying problem - I honestly don't know if my description is any good - I will gladly provide visuals.
Thanks in advance guys
Cheers
PS: While we're at it. Does anybody know of a good instruction on how to replace souch a touch screen unit? I only found a russian video but I don't know what kind of solvents the guy used as everything is in Russian

Adding compass sensor to Galaxy Tab A

Hi!
I'm new on this forum, and really happy to join the community.
I bought a Galaxy Tab A SM-T550 for my daughter, and I discover that there is no gyro/compass/magnetometer sensor that prevent using some apps.
After some cry, I decided to look for a DIY solution.
After some research, I found that some Android compass sensors have a I2C interface (e.g. AK8975) (sorry I can't post links yet).
I also found Android linux kernel drivers for this sensor.
As I have professional soldering skills/tool (even for BGA), and good Linux / kernel / driver skills, but nothing on Android (except modifying small programs and follow tutorial to install custom roms), I'm wondering if it is feasible to simply solder this sensor to the Galaxy Tab Mother board and directly have the compass feature in Android apps.
The requested actions I identified:
1. identify and order the sensor
2. Identify the I2C bus on Galaxy Tab A motherboard, plus power and ground signals
3. Identify a place to solder the sensor without risk to prevent casing mounting
4. Solder
5. be sure that the stock kernel supports this driver
6. Be sure that the driver is embedded in the kernel or the module is loaded
I'm wondering if someone with android and hardware experiences could help me to:
- tell me if this idea is totally crazy or seem feasible
- tell me if I identify the good tasks
- to find informations for some of the tasks (specially locate the I2C bus on motherboard)
- maybe propose another solution.
Thanks a lot!
Laurent.
In two years I have been the only other person sufficiently annoyed to look up something along these lines. I don't have your level of skill so I guess it would be pretty crazy for me to attempt this. I really wish they would have done something about this though, they have them in all phones so why not put them in tablets? They have more space to fit them in and I don't think they are hugely expensive.

Help! connect phone directly to hdmi monitor (replace touch screen).

Hello folks,
I guess this is the most appropriate subforum to ask this kind of question.
I'm having a broken screen Samsung Galaxy Note 5. And instead of find a touch screen replacement, I want to just get rid of the screen entirely
and instead connect the board to external monitor via hdmi interface preferrably. I believe the part that connect the touch screen is called "LCD fpc connector", correct me if I'm wrong.
So I guess I need something like an adapter that convert "fpc connector" to "hdmi connector".
The question is, is this hack possible? can the phone board output to hdmi monitor at all?
If yes then how to do it properly.
Please englighten me, I'm a total noob on this
Many thanks!
Hey huannb,
I also wanted this badly enough to stumble upon your post. From the light research i have done so far, it seems like this is a project only for those who have well labeled board diagrams and a deep understanding of LCD driver technologies.
FPC stands for "Flexible PCB Connector" and it's usage is ubiquitous in the small form-factor electronics space. If you are working with a FPC connector, you are probably handling a one-of-a-kind engineered interface. There are some hardware hackers who have achieved great feats such as THIS JAPANESE HARDWARE HACKER who build a driver board to adapt iPad retina displays to HDMI. I haven't stumbled on a write-up depicting and FPC interface to HDMI conversion yet. If you find one, please post it here because i would like to meet the person responsible for making it.
The way i see it, we have two choices from here. Reverse engineer a device and build a snowflake adapter which only works on one device, OR recycle the device and continue to live within the realm of consumer hardware.
kipziptie said:
Hey huannb,
I also wanted this badly enough to stumble upon your post. From the light research i have done so far, it seems like this is a project only for those who have well labeled board diagrams and a deep understanding of LCD driver technologies.
FPC stands for "Flexible PCB Connector" and it's usage is ubiquitous in the small form-factor electronics space. If you are working with a FPC connector, you are probably handling a one-of-a-kind engineered interface. There are some hardware hackers who have achieved great feats such as THIS JAPANESE HARDWARE HACKER who build a driver board to adapt iPad retina displays to HDMI. I haven't stumbled on a write-up depicting and FPC interface to HDMI conversion yet. If you find one, please post it here because i would like to meet the person responsible for making it.
The way i see it, we have two choices from here. Reverse engineer a device and build a snowflake adapter which only works on one device, OR recycle the device and continue to live within the realm of consumer hardware.
Click to expand...
Click to collapse
Hi,
Thank you very much for your insight, it is super helpful and somewhat deep enough for me .
It does seem to involve quite a lot of hacking and there isn't a universal approach.
For my case, it is not worth the effort anymore, I have found a way to use most android mobiles to external monitor without fixing the screen itself without much complications.
I doubt that I can find anyone competent enough to explore this realm any further .
Thank you so much again for your research. Cheers

Categories

Resources