I posted recently to show that working multi-touch input is available on the T-Mobile G1 phone. Now the necessary changes to the Android software stack are finally in good shape, and the software is easily installable on your own phone. (“Easily” being a relative term of course — you have to re-flash your phone’s firmware, and that may void the warranty…)
Keep reading for links to instructions for installing multi-touch support on the G1, as well as source code and screenshots for several multi-touch demo applications
Please donate to support continued development of awesome features for Android!
Obligatory video
This video shows the multi-touch demo apps that are described below.
EDIT: Yes, these demos are a little slow/clunky if you’re used to the iPhone — but that’s not the point. The demo apps (and the hacked system apps, Browser and MapView) can be made a lot more responsive through the addition of:
- OpenGL acceleration
- kinetic zooming / inertia (so that “fling” is supported) — should be trivial to add to the multitouch controller, I just didn’t do it
- and, in the case of maps and the browser, the addition of an API that is designed for partial zoom factors: the current API for both just suppports “zoom in”/”zoom out” not “zoom to 1.053x current zoom”, and starts the builtin jerky animation to get there, jumping in/out by a big step each time the animation has finished.
This is a proof of concept, people — of course it will be optimized over time — the fact it’s not done yet doesn’t mean it can’t be or won’t be. Apple’s engineers were paid mega moola to implement their bling, I was not. It’s actually not that bad if you try it yourself — and here’s the real point: you can get working MT on your G1 TODAY and it was never designed for that. Try it out and you’ll agree that MT zooming in the browser is a freakish lot better than the zoom button solution that Google implemented in the 1.0 release.
Approach
I moved my original multi-touch code back into the kernel, because it turns out that currently it’s a lot easier to patch the kernel and get a working Android system than it is to patch the Android java stack and get a working system. (The Android java stack that made it into the G1 was branched and polished long before the source code was released publicly, and the source code in git usually doesn’t run without problems due to being in a state of flux.) You can find the kernel patch to the synaptics touchpad driver here. Many thanks to zinx for helping to polish the kernel patch and figure out the best way to get mutitouch info into userspace.
I also patched the Android browser to support multi-touch scaling, source/diffs are linked below. The patched version also includes support implemented by JesusFreke for autorotating web pages based on phone orientation (you turn the phone on its side without even sliding out the keyboard, and the web page you’re viewing rotates) — you have to manually enable this in the Preferences to get it working though. See a list of known issues with the browser below.
Note that this approach to multi-touch is completely backwards- and forwards-compatible: you can write an app that implements extra features if multi-touch is supported on the phone. (The technical details: currently there is no way for an app to detect whether or not the phone has this multi-touch patch until the user initiates a multi-touch gesture, but at that point the size field of a MotionEvent in the onTouchEvent() method will have a value greater than 1.0. You can read multi-touch information by parsing this value, as shown in MultiTouchController.java in the demo apps below. Unpatched G1s will never generate a size value greater than 1.0, so you know that a size value less than or equal to 1.0 is a single-touch event regardless of whether or not the phone has been patched.)
EDIT: I received the following comment on this blog post, and wanted to highlight it, along with my response: “So let’s add this kernel patch to the mainline linux kernel, then google has no choice but to include it (I’m sure goog devs would love this). So google pushes this kernel patch with a OTA update, and everyone can use multitouch. I’m sure google would then try to delete all multitouch apps off the marketplace or they fight it out w/ apple over their bogus lawsuit.” My response: “Won’t happen, this is just a hack. The mainline kernel doesn’t need modifying, it already generates multitouch events, the event pipeline in the Android Java stack just drops the info for the second touchpoint. I hacked the kernel driver to hide info about the second touch point in the first touch point’s size field, so that the Java stack doesn’t need modifying. However ultimately the correct solution is to fix the Java stack to pick up the multitouch info and pass it on to userspace. This will require quite a lot of re-engineering though.”
Getting Multi-Touch on Your Phone
Unless you want to build and install your own patched Android kernel, the easiest way to get multi-touch on your phone is to get root access on your phone and then install JesusFreke’s replacement Android firmware image v1.41, available here:
–> Rooting your phone and installing JFv1.41 firmware images <–
The JFv1.41 images include the multi-touch patches to the kernel and browser to support multi-touch zooming, as well as numerous other useful bits and pieces (such as busybox, ext2 support, easy “su” root access, a data partition backup utility, and more).
If you want more detailed directions, you can find them here and here.
IMPORTANT NOTE: Flashing your phone carries a non-zero risk of voiding your warranty (although it is not clear whether or not this is true) and/or of bricking your phone (meaning you could render it unusable). If you re-flash your phone’s firmware, you take full responsibility for any damage that may result. Generally if you are careful, you won’t run into any major problems — but note especially that all user-data will be wiped from your phone when you first re-flash back to RC29 to get root access. Any data that is synchronized with the Google mothership *shouldn’t* be lost due to the fact that it’s all primarily stored on Google’s system, but other non-synchronized things *will* be lost e.g. your SMS message history, your Market-installed applications and their data, and probably other things. There are a few backup utilities on the Android Market, e.g. one to back up SMS messages. Once you have root and have patched your phone to include the engineering bootloader, then you can use the nandroid backup utility to backup files so that this does not happen in future.
Note also that OTA (over-the-air) updates from T-Mobile are generally disabled when you install community-generated alternative flash images like the ones above. This is to prevent T-Mobile re-flashing your phone with an image that takes away root access from you again. This means that when T-Mobile releases an update, you will need to wait a few days for someone in the community to produce an updated system image that includes the update. Generally (and increasingly, as the public source code repository becomes more stable), community images will be far more up-to-date anyway than what T-Mobile pushes out to you over the air, but there is of course a risk that something might break. JesusFreke has images based off of both T-Mobile official firmware and development (ADP1.1) firmware.
MULTI-TOUCH DEMO APPS
I have written several multi-touch demo apps for the G1. In most cases these are not intended for widespread use but to demonstrate to developers how to make use of the new multi-touch information that is generated by the kernel patch. Each app contains a copy of a class MultiTouchController.java that I wrote to simplify writing MT apps. Note that kinetic panning or zooming has not yet been implemented in the controller, but it should be simple enough to add.

Looks identical to the regular Android Browser -- but much easier to zoom on...

Looks identical to the regular Android Browser -- but much easier to zoom on...
Multi-Touch Browser
This is a patched version of the standard Android WebKit browser that supports multi-touch zooming. JesusFreke has kindly included it in his v1.41 image as described above, and you can get the source/patches here.
Features
- Multi-Touch zooming using “pinch” gesture like on the iPhone. Fully working and ready to use for daily browsing.
- Some pages are not zoomable (even in the single-touch browser), and all pages have an upper and lower zoom limit. With multi-touch zooming, you are shown a new message when you cannot zoom into or out of a given page, in order to give the user more feedback as to why the pinch gesture isn’t working.
- Also contains a patch by JesusFreke to support autorotate of the browser display based on phone orientation. You have to manually enable this in the Prefs.
Issues
- When you zoom (even in the single-touch browser), the Android Browser changes the text wrap width of all major blocks of text on a page to fit the width of the screen, causing a reflow of the HTML page a second or two after zooming. With multi-touch, this causes the browser page to jump around as you are zooming — mostly noticeable on smaller pages that don’t take long to reflow, e.g. google.com “Classic”. EDIT: Note that there is an option “Auto-fit pages” in the Browser settings that you can turn off to disable reflow. This makes multitouch browsing much more responsive, because the browser is not constantly trying to reflow and doesn’t suddenly reset your view position when the reflow has completed, but of course if the text line width is greater than the screen width then you will need to scroll back and forth to read. It’s a tradeoff…
- There is a bug in the current release of the (single-touch) Android Browser where the embedded WebView remembers its zoom setting across page views, but the BrowserActivity does not. Therefore the BrowserActivity may be thinking it is displaying a page at a different zoom than it actually is. If you zoom all the way into a zoomable web page like say cnn.com, and then browse to a non-zoomable page like google.com “Mobile”, then the embedded WebView will still be zoomed all the way in, but the BrowserActivity will tell you you can’t zoom out on the current page. This bug seems to be present whether you use multi-touch zooming or the zoom buttons, but it is a lot easier to run into on the multi-touch browser, because zooming is a much more pleasant experience so you’re likely to do it more 🙂 Somebody should look into this bug, it’s probably not hard to fix. If you find a fix please send it to me…
- You need to keep your fingers at least an inch or so apart for the zooming to work well, due to the “snapping” problem that was shown in my first video, and in the part of the video in this post that shows the MTVisualizer application.

A rather boring screenshot of the MTMapsDemo application -- no fun unless you're actually using it 🙂
MTMapsDemo
This is a very basic implementation of multi-touch zooming on Google Maps. It basically just wraps a WebView and displays your current location on the map, which you can then scroll around and zoom into/out of. You can get the source here or an .apk (compiled binary) that you can install on a patched phone here.
Features
- Display maps showing your current GPS location, jump to current location, pan, multi-touch zoom.
Issues
- No directions, no searching of the map, and nothing else either — the main reason being, Google has chosen not to release their Google Maps app as open source for reasons that are beyond me, so you’re left with having to re-invent the wheel for every map application, and you have to work through with a WebView through an API that is very limited (at least from a navigation perspective).
- There are issues with the map jumping wildly and/or scrolling locking up if you zoom out too far. This is due to inaccuracies in the inverse-Mercator projection calculations. Google doesn’t give you much of an API to work with in MapView, unfortunately, or much example code — so it’s hard to get a maps app working as well as their one does. EDIT: it is almost impossible to browse Europe or New Zealand for this reason. I’m sure there’s a way to do this right using the API, it’s just complicated because the API is very small and limited, and converting between the different coordinate systems used (degrees, microdegrees, pixels, zoomed pixels, pixels-at-the-equator — as well as Mercator projection vs lat/long) makes this quite hard to do. Somebody please look into it, this is just a demo 🙂
- Additionally, I think there is an issue with the view jumping back to the GPS position sometimes when you’re zooming. Shouldn’t be hard to fix but this is only a demo of what can be done, it’s not intended for use as a real replacement for Maps… Some interested party should look into this, I am unlikely to keep developing this app myself. I hope somebody will pick this up and make a full-featured Google Maps replacement…

The photo sorter demo application

The photo sorter demo application
MTPhotoSortrDemo
This is a basic photo management application that demonstrates how to use the MultiTouchController to handle dragging and stretching multiple different objects. You can get the source here or the .apk here.
Features
- Allows you to move photos around in a stack, reorder them, and stretch/scale them.
Issues
- Limited to the built-in images. A simple improvement would be to load photos from the SD card.
- Somewhat slow because it uses Skia, it would be better to code this up as an OpenGL app.
- May occasionally run out of memory and crash — Android apps are limited to using 16MB on the G1, so image-manipulating programs have to be very careful about how they use memory. EDIT: Happens especially when you slide open the keyboard.

The MT Visualizer app. Touch points are at the endpoints of one of the diagonal lines.

The MT Visualizer app. Touch points are at the endpoints of one of the diagonal lines.
MTVisualizer
This is an app that allows you to visualize the multi-touch information, so you can see the limitations of the G1’s multi-touch screen (that it is a 2x1D device not a true 2D device, as I described in my previous post). You can get the source here or the .apk here. NOTE: For this particular demo, because the .apk file is very small, if installing directly on the phone you must download the .apk over wifi, not over 3G, because a bug in the browser causes the file to get truncated a couple of kb short. The app installer in that case will say that it wants to replace “Android System”. Some info is here.
Features
- Displays row and column of each touch point (vertical/horizontal lines), touch radius for multi-touch (big red circle), angle between touch points (with diagonal lines), midpoint between touch points (blue lines), pressure (yellow circle centered around midpoint).
Issues
- This app shows that multi-touch on the G1 is limited in several ways — you get some weird snapping/popping effects etc. when touch points get close in one or other axis. As a result, the G1’s screen is a much better device for multi-touch scaling than it is for multi-touch rotation or more general multi-touch input, because the distance between the two touch-points in multi-touch can be measured a lot more reliably than the actual position of the points.
Official support in Android?
There is no official statement from Google about planned multi-touch support in Android, although there is a driver in the kernel tree for an iPhone-like screen. In my opinion, it is unlikely that the G1 will ever get official support for multi-touch from Google in its lifetime, because it was never designed as a multi-touch device, and there are some limitations to multi-touch on this device. Google will also not accept upstream this specific workaround solution to hack multi-touch onto the G1, understanably so, as no multi-touch API has yet been proposed or agreed on. See this thread for more information.
Credits
Thanks to RyeBrye for his original work on multi-touch, JesusFreke for his awesome work on producing souped-up replacement images and for incorporating my changes into his latest release, zinx for helping polish the kernel patch, and DarkriftX and Disconnect for general awesomeness and help with documentation, testing and other aspects of this release.
Links
Shameless plug: If you like this work then please feel free to use this link for amazon.com purchases.
Also if you don’t have a G1 phone yet, you can buy one using this link, or if you already have a G1, you can buy accessories here.
Conclusion
That’s it! This is all the work I ever expect to do on multi-touch for the G1, because I have more interesting ideas for apps that I want to spend my time working on. Watch this space. I hope other programmers will pick up multi-touch and run with it. Since this multi-touch solution is backwards and forwards compatible, there is no reason people can’t start adding additional multi-touch capabilities to apps that they release to the Market, starting today. When an official multi-touch API is available, apps can target that instead.
Have fun.
—
Luke Hutchison
[…] operations such as two-finger zooming in normal android applications. You can see his post about the multitouch g1 browser, or watch the video here: (which has a nice catchy tune behind it) Multitouch zooming on the […]
Usually people only post elaborate hoaxes on April Fools day – but you are obviously trying to get an early start.
Zooming in objects… with only your fingers… ? clearly this is witchcraft.
but… more seriously… good work 🙂
[…] Read | Permalink | Email this | Comments […]
Lol ryebrye, dont burn him at the stake before the rest of the world gets their chance. You know as well as anyone that 30% of the comments on here will be “this is fake, just a clever hack to make it look like multitouch”.
[…] Read | Permalink | Email this | Comments Post tags: Android, Browser, Cellphones, Concept Phase, Demos, Engadget, Fingertips, G1, Hack On, Handhelds, Hiccup, Hoops, Jazz, Multi Map, Nbsp, Proof Of Concept, Risk, Sun, T Mobile, Touch Support Posted in: Gadżety | | […]
[…] Read | Permalink | Email this | Comments […]
[…] Falls Ihr es trotzdem probieren wollt: Die komplette Anleitung gibt´s hier im Blog von Luke Hutchison. […]
[…] here Share this: These icons link to social bookmarking sites where readers can share and discover new […]
[…] Read | Permalink | Email this | Comments […]
[…] Want this? Read this post by Luke Hutch […]
Thanks for sharing! In appreciation of Open Source wanted to let you know that I posted on LC…expect to be hammered with traffic.
Great work guys. Let’s cupcake android now….
[…] […]
What is the app you are using for “list of recent applications”?
“LaunchPad” — in the Market.
[…] Появилась возможность включить multi-touch на G1 уже сегодня, для этого необходимо заменить прошивку в G1. Включается поддержка мультитач на уровне драйверов, а так же в Google Maps и встроенном браузере. Вот видео, а за подробностями стоит зайти на страничку автора. […]
where can i get that app you use to switch apps using the notification bar
thanks!
“LaunchPad” — it’s in the Market.
[…] appeared on Engadget on Sun, 25 Jan 2009 02:12:00 EST. Please see our terms for use of feeds.Read | Permalink | Email […]
[…] lukehutch’s blog post for more information about the new multi-touch support, as well as a few other demo multi-touch […]
Great work!
The Multitouch browser works perfect!
I only had some issues with the MTMapsDemo. When your finger gets near the edge of the screen or gets released it sometimes locks up (you cant move the map). Tapping a few times on random places seems to solve this issue..
Also it was difficult to move the view to europe, it kept setting me back to the usa ;)…
Yes, I forgot to mention the jumping issue with the MT Maps demo… will update the post. Thanks.
Yes, this is a known issue (see the blog). It’s just a lameo demo app. I hope someone writes a real MT maps app.
[…] Read | Permalink | Email this | Comments […]
[…] Read | Permalink | Email this | Comments […]
[…] Read | Permalink | Email this | Comments […]
[…] hope that Google will make it official on the upcoming release of Android. [Read HERE via Engadget] Thanks Doug M.! Technorati Tags: […]
[…] Read | Permalink | Email this | Comments […]
[…] Read | Permalink | Email this | Comments […]
[…] pair of “sporty shoes”, and don’t forget the inhaler! Finally head on over to Luke Hutch’s blog and start the hoop […]
[…] Read | Permalink | Email this | Comments […]
[…] lukehutch’s blog post for more information about the new multi-touch support, as well as a few other demo multi-touch […]
[…] il firmware originale con il JFv1.4 firmware images. QUI trovate tutto il necessario QUI e QUI ulteriori […]
[…] Read | Permalink | Email this | Comments […]
Hey, just tried it out with the Maps Demo, it works really well. Great work! Hopefully somebody will push this back upstream.
Actually, couldn’t you submit the multi-touch stuff to Google, and let them add it to the dev tree?
[…] the Google Android Multi-Touch Software Install Information Here Leave a Reply Visited 1 times | Tags: Google Android, Mobile OS, Multi-Touch, Operating System […]
[…] Read | Permalink | Email this | Comments […]
Really awesome work, thanks so much!
[…] Read | Permalink | Email this | Comments View this Post in: Share and Enjoy: […]
Typing this on JF1.4 🙂 Awesome work.
[…] G1 Multitouch progress Luke Hutch has improved on his modified Java stack method and has provided a full G1 image that has […]
[…] Read | Permalink | Email this | Comments […]
[…] Luke Hutch has done all necessary changes to Android software stack to get multi touch working on G1 Phone, this is not cupcake so please don’t get confuse. If you are egger to see Multi Touch on your G1 Phone then you need to mod your G1 phone to get root and install JesusFreke’s replacement Android firmware image v1.4. […]
[…] Zoom-Zoom-Zoom — Get Multi-Touch Zooming Support on your T-Mobile G1 TODAY I posted recently to show that working multi-touch input is available on the T-Mobile G1 phone. Now the necessary […] […]
[…] We’ve been hearing for months now that both Android and the T-Mobile G1 hardware have some magical, top secret low-level support for multi-touch, but unless we can… you know, do something with it, it really isn’t doing anyone any favors. That’s where the lovely people in the ever-industrious dev community come into play, throwing together demos on their way to a full release that you — yes, you — can finally install on a G1 of your very own. It’s still in the proof-of-concept phase, but the load does include a multi-touch version of Android’s excellent browser, probably the single app that could use two fingertips more than any other. Needless to say, you should be installing this jazz at your own risk — but considering the number of hoops you need to jump through to get it up and running (hint: you need to start by gaining root access), the whole process should be enough of a deterrent for the casual types who can’t take a hiccup here and there. Video of the included multi-touch map browser app (among others) in action after the break.[Thanks, Ryan G.]Source […]
[…] Read | Permalink | Email this | Comments […]
[…] [Read] « Official Last.fm Player Now Available For Android […]
[…] Read | Permalink | Email this | Comments Written by startme in: Engadget | […]
Congratulations!
Good work!
[…] Read […]
[…] on the G1, you can actually enable it yourself on your own G1.However, as Luke Hutchison says, this is proof-of-concept. And, quite honestly, you’ll likely void your warranty and possibly brick […]
[…] Get Multi-Touch Zooming Support on your T-Mobile G1 TODAY [Luke Hutchison via Boy Genius] […]
[…] full details on how to go about this procedure can be found here, but do exercise caution as this is hardly authorized by T-Mobile. With that being said, if […]
[…] Reading? Coder and Android-enthusiast Luke Hutchison has developed a multitouch implementation for the T-Mobile G1, that takes advantage of the smartphone’s hardware multitouch support. […]
[…] some time and refinement, Android multitouch could well be within the reach of you average user. [Luke Hutchison—Thanks, […]
[…] some time and refinement, Android multitouch could well be within the reach of you average user. [Luke Hutchison—Thanks, […]
[…] Link | Zoom-Zoom-Zoom — Get Multi-Touch Zooming Support on your T-Mobile G1 TODAY […]
[…] If you’re still willing to take the chance or just want a few more details, head on over to Luke Hutchinson’s Blog […]
[…] OF!” then you might have what it takes to flash the firmware on your T-Mobile G1 in order to get this multi-touch hack up and running, courtesy of developer Luke […]
Amazing! I can’t get the MT-Visualizer to work though. Keeps saying Package Installation Unsuccessful. The other ones work fine.
Can’t wait to see someone beef up the photo app. That’s gonna be hot.
Strange — anyone else have this problem with MTVisualizer? I’ll rebuild it and re-upload the .apk in a second, try again soon.
[…] work Luke. For more details, full instructions, issues and more… take a few minutes and hit up Luke’s blog. Thumbs up […]
Those 4 apk packages worked fine here… Did you guys enabled the option “Unknown sources” in the Application settings of your phones?
[…] Tutorial […]
[…] some time and refinement, Android multitouch could well be within the reach of you average user. [Luke Hutchison—Thanks, […]
[…] you want to give it a shot however, instructions can be found here. VN:F [1.0.9_379]Rating: 0.0/5 (0 votes cast) Tags: Android Software, Development, Hacking, […]
[…] some time and refinement, Android multitouch could well be within the reach of you average user. [Luke Hutchison—Thanks, […]
[…] Luke Hutchison ha conseguido pulir la capacidad multitáctil del dispositivo G1, gracias a la modificación de la pila de Android para gestionar los datos de entrada y a la modificación de las aplicaciones para que puedan usar dichos datos. No es más que una prueba de concepto y pese a que funciona, según sus propias observaciones podría funcionar mejor, añadiendo aceleración OpenGL, zoom con inercia, y pudiendo tener acceso a pasos de zoom dinámicos, en lugar del fijo, impuesto en Android. Tags: google Noticias TI […]
[…] OF!” then you might have what it takes to flash the firmware on your T-Mobile G1 in order to get this multi-touch hack up and running, courtesy of developer Luke […]
[…] work Luke. For more details, full instructions, issues and more… take a few minutes and hit up Luke’s blog. Thumbs up Luke! var addthis_pub = ”; var addthis_brand = ‘Mobile Petrol’;var addthis_language = […]
http://www.sourceradix.com/ng.html
Would it be possible to implement the auto rotate in Browser at
http://www.koushikdutta.com/2008/12/auto-rotate-for-android-browser.html
plus the multi touch
[…] Download Via: Wired […]
[…] henz belli deil. Haberle ilgili detaylara ulamak, ve videosunu izlemek isteyen okuyucularmz buraya […]
[…] “I posted recently to show that working multi-touch input is available on the T-Mobile G1 phone. Now the necessary changes to the Android software stack are finally in good shape, and the software is easily installable on your own phone. (Easily being a relative term of course you have to re-flash your phones firmware, and will probably void the warranty if you do so ” Read more here: […]
[…] não possuir a funcionalidade Multi Touch, parece que a comunidade Open Source por meio do usuário Luke, desenvolveu uma solução que funciona de forma muito fluida e perfeita. Bem que poderiam criar […]
I am getting .zip files from the .apk links…? There is no .apk file found in them extracted….Am I doing something wrong?
I just tested and it works for me. Make sure you are looking at the binary links not the source links.
[…] 零售版本的G1还没有支持多点触控。但是得益于开源社区,我们在G1上见到了它。需要更深入了解,请到Luke’s blog. […]
[…] “I posted recently to show that working multi-touch input is available on the T-Mobile G1 phone. Now the necessary changes to the Android software stack are finally in good shape, and the software is easily installable on your own phone. (?Easily? being a relative term of course ? you have to re-flash your phone?s firmware, and will probably void the warranty if you do so?” Read more here: […]
[…] das Android-Handy G1, als iPhone-Konkurrent gestartet, mit einer experimentellen Firmware nun Multitouch-Unterstützung bekommen soll, ist das eine. Dass daraus bei Golem ein “T-Mobiles G1 unterstützt […]
[…] Multitouch beherrscht. Eine Anleitung wie man Multitouch auf dem G1 zum laufen bringt, wird bei Luke Hutchison ausführlich auf englisch […]
[…] Irgendwie ist es ja schon interessant, dass das Display des T-Mobile G1 für Multitouch-Gesten ausgelegt ist, das Smartphone diese aber in der aktuellen Firmware einfach nicht unterstützt. Genau das hat auch Luke Hutchison erkannt und die Firmware etwas modifiziert. Nun kann man das T-Mobile G1 mit den vom iPhone bekannten Gesten bedienen und etwa durch das Auseinanderbewegen zweier Finger Inhalte heranzoomen. Im untenstehenden Video wird das ganze auch nochmal demonstriert. Nähere Infos gibts auf dem Blog von Hutchison. […]
[…] prova de conceito, o desempenho e a navegação são realmente impressionantes. Excelente trabalho! Leia mais. posted under Mobile Design, Internet Geral, i2 tecnologia, Google, Android, Mobile Advertising, […]
[…] seen before that Multi-touch is certainly possible. In a nod to the power of open source, Luke Hutchinson has released an app for Android that will allow you to use Multi-Touch on your […]
[…] Android Gets Multi-Touch If you want the job done right, sometimes you just gotta do it yourself. That’s exactly what Luke Hutch did when it came to Android. We’ve seen him work his magic before, but now he’s done it in a way that you can install yourself. […]
[…] seen before that Multi-touch is certainly possible. In a nod to the power of open source, Luke Hutchinson has released an app for Android that will allow you to use Multi-Touch on your […]
[…] Luke Hutchison, ein Blogger, hat nun eine modifizierte Firmware bereitgestellt, mit der es Möglich ist, die bekannten Multitouch-Gesten des Apple iPhones auf dem T-Mobile G1 (Android) zu nutzen. Bei der gemoddeten Firmware ist gleichzeitig ein neuer Kernel dabei und einige Anpassungen am Browser sowie den Maps von Google wurden vorgenommen. […]
really great work, thank you very much
[…] These ads come at a point when things are heating up for Palm Pre and Android is going strong with its apps (Did you know about the Multi-Touch app for Android – Check-it-Out). […]
[…] Na videu je vidět, že technika přibližování je, přes malé mouchy, pro běžné použití naprosto vhodná. Chybí snad jen podpora plynulejšího ovládání při přibližování a oddalování. Nahrání a zprovoznění aplikace také není zrovna jednoduché. Je při něm potřeba flashnout G1, což při nesprávném zacházení může vést až k nepříjemnému zablokování telefonu. Podrobný postup a popsané kroky najdete na stránkách autora aplikace “Zoom-Zoom-Zoom“. […]
very nice work. the maps application has some issues like my location doesnt work right and maps over europe dont work either. other application are working just fine thank you
I forgot the photo application crashes it you have auto rotate enabled in your phone and try to autorotate but that is probably because of the limitations you already talk about
[…] ago a demo on multitouch functionality of standard Android phone. And just recently he has posted a greatly enhanced post with more examples and directions on how to hack the G1 to allow multitouch functionality. Great […]
To alleviate the choppyness when zooming in on the browser…
Would it be possible to add a delay to the auto-fit – say, once touch is released (onRelease?) – then auto-fit or, once touch is released, wait 1 second before auto-fit?
Besides that, AWESOME job on the software man, really, AWESOME.
Yes, you could probably add a delay before auto-fit quite easily. You probably know you can turn it off entirely in the settings, but this is not ideal either because it’s hard to read long lines.
I won’t be spending more time on this because I have a PhD to finish and a ton of app ideas I want to implement, but you should ask around on some of the Android developer bulletin boards to see if you can find someone who might want to implement this…
[…] henz belli deil. Haberle ilgili detaylara ulamak, ve videosunu izlemek isteyen okuyucularmz buraya tklayabilirler. […]
[…] Dokładną instrukcję instalacji patcha znajdziecie tutaj. […]
[…] It Out> Luke Hutchinson via Android […]
Awesome luke. Best of luck with your PhD – a good friend of mine finished MIT a few years ago, so I know how intense it can be.
Good to know you think it’s relatively easy, I’ll start probing a little at XDA to see what we can do
🙂
[…] G1 and the multi-touch thing was so cool. To have multi-touch on your G1, you can follow this link https://lukehutch.wordpress.com/2009/01/25/get-multi-touch-support-on-your-t-mobile-g1-today/ Share and […]
Wow im very impressed, it works a lot better than I expected, even on a device that was not intended for it. Good job and keep up the good work!!!! p)
[…] další pokračování miniseriálu o multitouch vlastnostech telefonu G1. Vývojář Luke Hutch připravil nejen hezké demo video, ale i podrobný návod jak ve svém telefonu zprovoznit iPhone-like zoom v mapách, browseru […]
[…] característica que Apple ha puesto de moda, pero hasta ahora su software no la utilizaba. Un tal Luke Hutchison le ha puesto solución a eso y ha conseguido modificar el terminal para que acepte este tipo de […]
Nice brazilian song!
THERE ARE NO .APK FILES IN THE ZIPPED FOLDERS FOR THE “MT Photo Sorter Demo” & the “MT Visualizer Demo”.
Luke Hutchinson can u please upload them for me. Somewhere.
IM LOOKING FOR THE OTHER TWO DEMOS!!!!
*What Im Lookin For Is the .apks For The:
-MT Photo Sorter Demo (MTPhotoSortrDemo)
-MT Visualizer Demo (MTVisualizer)
Please click on the LINK for the “MT Photo Sorter Demo” when u “click” where it says “You Can Get The Source Here Or The .apk HERE”
& click on “apk HERE “….
U download & unzip the “MTPhotoSortrDemo” folder & These are Folders & Files it contains:
-META-INF: (Contains CERT.RSA, CERT.SF, MANIFEST.MF)
-RES: (Contains “DRAWABLE” Folder wit pictures in it)
-AndroidManifest
-Classes.dex
-Resources.arsc
There Is absolutly No .apk Files in Any of the folders.
The .apk Files are also not in the “SOURCE” Folder Link for the MTPhotoSortrDemo app
Also I wanted to say that it is the Exact Same thing is true for the “MTVisualizer” app.
I’m sorry, I just double-checked the “get the .apk here” links for both those apps that you said don’t work, and they do work for me. Are you using Internet Explorer? If so maybe try Firefox or Chrome, or clear out your cache…
If all else fails then you can find everything here: http://web.mit.edu/~luke_h/www/MultiTouchV4
Yes i got them all thanks again. Great Demo’s. Seriously.
And great work. U are an revolutionary when it comes to the G1.
U should compile all the demo’s into one App & toss it in the Android Market to open everyone eyes.
Let them know in the discription that it only works on ROOTED phones with multi-Touch or tell them to get root access & get JF v1.41. rom or something. Lets get google to open there minds forcfully & get the people at 1phone to stop being pressed with there multi-touch patent.
Thanks again…..peace
I couldn’t possibly post these apps to Market. There are way too many stupid people out there that would brick their phone and then, furious, try to sue me or at least send around their gang buddies. Have you SEEN the comments on Market apps??
[…] install multitouch on your G1, please follow the guide given at the Multitouch App For G1 Link E-mail Comment Del.icio.us Digg Reddit Technorati […]
I like to read the App Market comment flame wars when I’m bored.
Thanks Luke for your work. I am geeking out! 🙂
So let’s add this kernel patch to the mainline linux kernel, then google has no choice but to include it(I’m sure goog devs would love this). So google pushes this kernel patch with a OTA update, and everyone can use multitouch. I’m sure google would then try to delete all multitouch apps off the marketplace or they fight it out w/ apple over their bogus lawsuit.
*chomps popcorn*
Won’t happen, this is just a hack. The mainline kernel doesn’t need modifying, it already generates multitouch events, the event pipeline in the Android Java stack just drops the info for the second touchpoint. I hacked the kernel driver to hide info about the second touch point in the first touch point’s size field, so that the Java stack doesn’t need modifying. However ultimately the correct solution is to fix the Java stack to pick up the multitouch info and pass it on to userspace. This will require quite a lot of re-engineering though.
[…] supports multi-touch on the G1 but there’s no implementation of it on Android. There is a hack, as you can see in the video, that you have to install but I’m sure its risky and I […]
[…] as Luke Hutchison says, this is proof-of-concept. And, quite honestly, you’ll likely void your warranty and possibly […]
Hi Luke,
seems you did a great job there – i just got my GERMAN G1 yesterday and i wonder with what files i should work with?
Your explaining link only tells what US and UK users have to do.
Can you give me a hint?
(I am little afraid to destroy my great new phone if i just use the US or UK files…)
THANKS SO VERY MUCH!
You should look online to see what the exact differences are between the German software and the UK/US software. The UK/US software have some different apps in them relative to each other (e.g. the US one has the MyFaves app for US T-Mobile). As far as I know though the hardware is identical on all G1s. So if you don’t mind losing any special German-specific features on the phone (e.g. German language support? Local service provider apps?) then you can just install any of the other images. I recommend the ADP1.1 image since it makes your phone into a developer phone, so it’s easier to do development on it in the future. If you’re worried about it then ask around on the bulletin boards until you find another German user that has done it first.
[…] auf T-Mobiles G1 Handy Kanta macht auf diesen Hack des T-Mobile G1 Gerätes aufmerksam. Hier beweist Luke Hutch, dass das G1 sehr wohl in der Lage ist […]
[…] neue G1 Google Handy kann sehr wohl, mittels eines Hacks sehr wohl Multitouch-Gesten verarbeiten und iPhone-ähnlich zoomen – hier hier im Video […]
[…] is credited for hacking the Android and getting multitouch, you can read more about it over here. But, in order to get multitouch and other goodies, you need to upgrade your RC29 phone to […]
got it working, nice work. are you planning on making it capable on actual google maps, not just the demo?
[…] lukehutch’s blog post for more information about the new multi-touch support, as well as a few other demo multi-touch […]
Hey Luke
I have some trouble to understand how this 2x 1D touchscreen works.
In your kernel patch you submit the middle point for multitouch.
What is the exact content of pos[]? Will somthing like this result in “wrong” values? cause it’s not a 2D touchscreen?
x = pos[0][0] ;
y = pos[0][1] ;
x2 = pos[1][0];
y2 =pos[1][1]);
thanks!
Hey ppose —
The original code submitted the info for both touch points in the event, but the info for one of the touch points was simply discarded in the Java Android stack. (See my original post.) The reason I submit the midpoint and then package up the “width” and “height” of the multitouch event into the size field is that that field is not really used by anything in Android, and all that info is passed through to userspace without any problems. Ideally the kernel driver would be unpatched, and the Android event handling code would be adapted for multitouch, but that’s the harder of the two options right now because it’s hard to rebuild the Java stack and have it remain compatible with all third-party applications (the API changed between snapshotting for the G1 and release of the source).
pos[0] is populated with the first touchpoint’s info, pos[1] with the second touchpoint. pos[i][0] is x, pos[i][1] is y. That info is pulled out of some binary-packed fields that are fetched from the hardware.
Yes, you can get some “wrong” values if the points are close together in X or Y — see my first multitouch post and video, and see also the MTVisualizer app I released with the second post. This is a hardware limitation though, not a driver limitation.
Good luck!
[…] Enlace relacionado: Multi-Touch Zooming Support on your T-Mobile G1 https://lukehutch.wordpress.com/2009/01/25/get-multi-touch-support-on-your-t-mobile-g1-today/ […]
Technology is getting beter and better
Regards,
Mobilecellphonereview
[…] you to run multi-touch, tethering, and even a task manager. The G1 multi-touch hack, courtesy of Lukehutch still has some bugs and isn’t nearly as smooth as the iPhone but it’s a step in the right direction […]
[…] a few days back, but better late than never. Luke Hutchison posted a proof of concept method to allow mutli-touch zooming on the G1. It’s not optimized for speed yet, but it’s definitely working as you can see in the […]
[…] More and find out how to on Lukes Blog This entry was posted on Wednesday, February 4th, 2009 at 11:10 am and is filed under Android. […]
Great job on the multitouch hack. With Apple’s patent on multitouch gestures being approved, I’m not too optimistic that it will end up in the Android code base.
Anyhow, I’m attempting to install MTVisualizer and and I receive the following message
“Replace Application
——————————–
The application you are installing will replace another application.
All previous user data will be saved.”
The application it wants to replace is “Android System,” so I’m holding off on that one. Any ideas/thoughts??
~Clark
Hi Clark,
You’re the first one to report that problem and honestly it’s pretty weird. I don’t have a clue why it would be asking you to replace Android System. My understanding is that an app is only replaced if (1) the keys used to sign the keys match and (2) the java package names of the apps match. I used the debug key to sign MTVisualizer and MTPhotoViewer (MTMapsDemo was signed with release keys because the Maps API requires it). I’ll probably go back and re-sign the APKs with release keys — but you can also just create a project in Eclipse using the source code that I linked to in the blog post, and launch the app directly from Eclipse. It will install it on your phone as a result of the launch.
Luke
OK, the .apks are resigned. Please try MTVisualizer again and let me know if this fixed the problem. Thanks.
Figured out the problem with the app installer wanting to replace “Android System”, the problem is described here: http://groups.google.com/group/android-beginners/browse_thread/thread/4f82b29159a341fe
Basically you need to download MTVisualizer over Wifi, not 3G, due to a bug in the browser that truncates data streams for small files when downloading over 3G.
[…] Multi-Touch zooming in your browser on the T-Mobile G1 today — visit Luke Hutchison blog. This is a followup to my previous video — multi-touch is now a reality in user applications. […]
[…] Ringraziamo Luke Hutchinson […]
[…] Download More Multitouch-Enabled Apps In the flashed ROM you just installed, only the burgasweb.comKit browser has been tweaked to accept multitouch input. But your fun shan’t stop there. Hutchison has provided a few more demo apps-including a simple Google Maps app, photo browser and fun Multitouch visualizer. You can download them all in .apk package format from his site. […]
[…] Download More Multitouch-Enabled Apps In the flashed ROM you just installed, only the WebKit browser has been tweaked to accept multitouch input. But your fun shan’t stop there. Hutchison has provided a few more demo apps-including a simple Google Maps app, photo browser and fun Multitouch visualizer. You can download them all in .apk package format from his site. […]
[…] Download More Multitouch-Enabled Apps In the flashed ROM you just installed, only the WebKit browser has been tweaked to accept multitouch input. But your fun shan’t stop there. Hutchison has provided a few more demo apps-including a simple Google Maps app, photo browser and fun Multitouch visualizer. You can download them all in .apk package format from his site. […]
[…] Download More Multitouch-Enabled Apps In the flashed ROM you just installed, only the burgasweb.comKit browser has been tweaked to accept multitouch input. But your fun shan’t stop there. Hutchison has provided a few more demo apps-including a simple Google Maps app, photo browser and fun Multitouch visualizer. You can download them all in .apk package format from his site. […]
[…] Download More Multitouch-Enabled Apps In the flashed ROM you just installed, only the WebKit browser has been tweaked to accept multitouch input. But your fun shan’t stop there. Hutchison has provided a few more demo apps-including a simple Google Maps app, photo browser and fun Multitouch visualizer. You can download them all in .apk package format from his site. […]
Is anyone in Vegas done this yet and if so could I get some help with it. Dont want to kill my new toy.
Need to check out the MTVisualizer again.
Anyone know of any real photo browser being developed that supports this? That would be amazing.
[…] Download More Multitouch-Enabled Apps In the flashed ROM you just installed, only the WebKit browser has been tweaked to accept multitouch input. But your fun shan’t stop there. Hutchison has provided a few more demo apps-including a simple Google Maps app, photo browser and fun Multitouch visualizer. You can download them all in .apk package format from his site. […]
[…] ứng dụng và demo có được điều này, trong đó có Google Maps… Tải về tại trang này dưới dạng file .apk và cài […]
[…] get multitouch up and running, all you need to do is head over to Luke Hutch’s blog and follow the steps explained (in a great detail) there. In short, you don’t have to […]
Ok now I fear, this is becoming a legal issue :
http://www.newlc.com/en/multitouch-feature-any-screen#comment-50240
Anyway I dont think this patent is not an innovation we’ve seen many application before of multitouch right ?
[…] si el rumor es cierto o no, lo que si importa es que mediante el uso de un hack por el programador Luke Hutchinson se puede obtener multitouch en el hardware […]
[…] For more development details about how this feature is implemented, please visit Luke Hutchison blog […]
[…] Download More Multitouch-Enabled Apps In the flashed ROM you just installed, only the WebKit browser has been tweaked to accept multitouch input. But your fun shan’t stop there. Hutchison has provided a few more demo apps-including a simple Google Maps app, photo browser and fun Multitouch visualizer. You can download them all in .apk package format from his site. […]
[…] o último enlace porque isso já emaranhou demais. Era só uma nota sobre o MacBook […]
[…] so appealing. The user interface instantly becomes more intuitive and fun to use. (Of cours you can enable the G1 for multi-touch, the device is […]
[…] Read the whole article with download links here. […]
[…] of requests for the code and to get this feature running on the phone in his blog. He has given a good demo about what he has done. You can download the code or get the software install it in your GPhone […]
[…] It’s not allowed to use it . It’s allowed only on Iphone. Anyway here are few links to do it by yourself: http://i.gizmodo.com/5146797/how-to-…he-t+mobile-g1 https://lukehutch.wordpress.com/2009/…bile-g1-today/ […]
[…] Download More Multitouch-Enabled Apps In the flashed ROM you just installed, only the WebKit browser has been tweaked to accept multitouch input. But your fun shan’t stop there. Hutchison has provided a few more demo apps-including a simple Google Maps app, photo browser and fun Multitouch visualizer. You can download them all in .apk package format from his site. […]
😦
would be cool, if mt could be implemented in the standard applications…
if these google engeneers say they don´t, another distribution basing on and compatible with android would be nice 🙂
Google is the best, I’m yuse google API to create advanced search with google map support. Its so cool. Google was let developer to use online API in any aplication.
[…] buttons to my Android posts. I should have done it before I got 200,000 hits on my site for the work enabling multi-touch on the G1! I have some great new ideas for Android and want to be able to spend more time on Android hacking. […]
Hey luke,
I have a issue, after installing the multi touch browser, if i visit a website that has both a standard desktop view or a mobile view, it only lets me access the mobile view even if i click standard view or desktop view it just loops back to the mobile view. And this dosent just happen on one site t happens on multiple sites like yahoo or twitter. Any sugestions would help. Thanx
Hi Joseph,
Thanks for the bug report. Are you totally sure this only happens in the multitouch-enabled browser? It is unlikely to be because of the multitouch feature, all it intercepts is touch events. It is more likely some weird interaction between the browser and the website. It is possible that the browser identification string changed or something in the OS image you are using (donut on cyanogen?) and the website isn’t handling the switch between mobile and full versions of their website properly. Let me know if you find out more info.
Any plans to update your examples (specifically MTVisualizer) for the official Android 2.0 multi-touch API?
Yes, most definitely 🙂 I’ll probably work on that over the break, along with a patched browser for the Droid and Nexus One that will be parallel-installable without having root access on your phone. Thanks for the nudge.
I noticed that you posted more about your multi-touch controller, but how are those sample app portings coming? Do they just need to be recompiled with your updated controller? Sorry if I sound like I’m nagging or ungrateful; I do appreciate your hard work! 🙂
Hi Tianon– Yes, the demos just require recompiling with the updated controller, the demos themselves need no code changes to work on the new MT API, because the controller abstracts away the event API. I still have a G1 so haven’t ported to the new API yet, I’m really just waiting for my Nexus One phone and the accompanying 2.1 SDK to get the motivation to do this. (My phone hasn’t been delivered due to a mixup — and the 2.1 SDK isn’t released yet. Actually though this should work on the 2.0 API too as present on the Droid.) Thanks for the reminder though, I’ll put it on my todo list to do soon as it won’t constitute much work. (You could recompile them yourself if you want, if you have any Java ability.)
Dear me, my apologies. I had completely forgotten that you’d released the code! Thanks for the remind. By the way, Cyanogen’s mod has the new multitouch updates, in case you missed that update. 🙂 I’ll go recompile those examples with the new controller and see how they’re working! 😀
Once again, showing my stupidity. Of course you knew, you wrote most of the code for it! 🙂
No, you’re right, I actually have cyanogen’s unreleased eclair code running on my phone, but it’s so painfully unusable most of the time (due to the memory problems (not just on the eclair version), cyanogenmod bug #646) that I’m not doing anything serious with the phone right now and just biding my time until I get the N1. Actually I could get the code running on 2.0 on the emulator, but I wouldn’t be able to actually test it there because there’s only a single touch point.
[…] operations involving the distance between the touch points and their orientation. There is also a *lot* of finicky behavior on current capacitive touchscreens on touch up / touch down events (e.g. one axis but not the other […]
Seems like if the Android guys are serious about this Multitouch API in 2.0 that they need to update their emulator with some hackish way to supply multiple finger inputs. 🙂
There is a way — MPX — and it should be implemented in the emulator. I’m sure it’s not yet. It would be a good feature request or patch for AOSP if you’re feeling ambitious 🙂
http://code.google.com/p/android/issues/detail?id=5977
As the summary suggests, I’ve just barely learned that MPX has been merged for quite some time, so I think a patch is beyond the scope of my current knowledge, but I’ve created the feature request. 🙂
Tianon — you asked about the MT demo apps. I ported them all to Eclair, and full sourcecode is available in the following blog post:
https://lukehutch.wordpress.com/2010/01/06/my-multi-touch-code-ported-to-eclair/
[…] To make multi-touch feature working on G1, the developer has patched the kernels and flashed the firmware. The developer has posted a detailed guide and a tutorial on how to tweak your G1 to enable multi-touch in it. […]
Hy lukehutch,
many thanks for the great work you have done and for posting all information in your blog..
I’m compiling kernel source of Acer Liquid and I implemented your multi-touch approach in the auo_ts driver (not synaptics) and it kind of works.. Using your MTvisualizer I can pich zoom and works, tested on mtmaps and works too (: ..
I’m having an issue in it, think because the screen is WVGA, the pinch zoom works too fast, a slight move makes it zoom much than what needed.. Can you tell me what can I do to make it zoom in/out less??
Many thanks again (:
You know what, you’d be *much* better off porting the official Linux multitouch API to the Acer kernel, and then porting the Eclair MT API to the Acer version of Android — although it will be more work. The reason is that my kernel hack is really just that — a hack — and Acer will be doing an Android 2.1 OTA pretty soon from what I hear.
However, to help you debug what you have already done: Does the MTVisualizer app work perfectly? Which apps zoom much too fast? If MTVisualizer works perfectly then there’s just a constant you need to change in the other demo programs that scales the zooming by a certain amount to make it feel more responsive, and that constant just needs to be tweaked.
Well, guess it would really be more work, hehe .. I know, think in March Liquids will have an eclair update , but for know I’ll try to polish the liquid’s corners (: ..
I don’t really know what I would be expecting in MTvisualizer because I cannot see the youtube vid, removed
.. Only tried mtmaps and a slight finger move makes it zoom in/out to max .. Can you tell me witch constant so I can give it a try..
I’ll compile your brouser source and take a look on how it works too..
The constant in the Maps demo is ZOOM_SENSITIVITY. The PhotoSortr demo doesn’t scale the zoom factor like this IIRC. But really the first thing to get working is the MTVisualizer, what should happen is that there should be a rectangle with the two touch points at diagonal corners, and a circle with the correct pinch diameter that goes through the touch points. This should move in realtime as you move the two touch points on the screen. If that’s not working then nothing else will work.
It’s possible also that what’s happening is that because the screen is bigger, the number that’s being packed into the size field of the touch event is overflowing. I’m pretty sure I scaled it up (in fixed point form) so that I got the maximum resolution possible for the G1’s screen size. You might need to use fewer bits for this. Are you familiar with fixed point representation? If not I’ll pull out the old code and see if I can help you get this working. What’s the Acer screen size exactly?
Sorry, didn’t see your comment here..
I get similar results in MTvisualzer.
when I touch with only one finger I only see a green circle with blue lines. When I put the second finger I only see a big yellow circle with centre in the midpt of the two fingers and a small circle inside the grows/shrinks as I aproximate the two fingers.
Let me try to describe what I think is wrong, sorry, I’m portuguese but I’ll try to speak clearly..
If I want to zoom out, I put the two fingers in the screen and then approximate slightly the two fingers until they reach each other, and what happens is that the circle keeps shrinking to minimum size and when it reachs the minimum size it appears big again and start shrinking again. It keeps in this loop until I stop decreasing the distance between my two fingers..
I think that changing that value it would solve the problem.. I try to test it.. I don’t have much experience in that, so if you want I’ll much appreciate your help. The screen size is 800×480 ..
Many thanks again (:
OK, I think I know what’s going on — will switch the conversation to email.
many thanks for the help (:
[…] Download More Multitouch-Enabled Apps In the flashed ROM you just installed, only the WebKit browser has been tweaked to accept multitouch input. But your fun shan’t stop there. Hutchison has provided a few more demo apps-including a simple Google Maps app, photo browser and fun Multitouch visualizer. You can download them all in .apk package format from his site. […]