Motorola Lapdock's internals documentation project

Keep a log of a project build here. Be sure to include pictures and as much documentation as possible.

Motorola Lapdock's internals documentation project

Postby gima » April 4th, 2014, 2:43 am

Hello everyone,

I'm not sure if this is worthy a project, or does it belong into this category, or is it even providing any value to the community, BUT I'm still going to post this here in case others want to join.

Any help with the project would be greatly appreciated ♥

Summary
First of all the Lapdock is just screen, keyboard, touchpad and battery + some trinkets, it's not a laptop by itself.

My aim is to recreate the Lapdock's "main board" which makes it possible to connect the keyboard, mouse and screen to any other device that one wants to use. Either using off-the-shelf components and/or with FPGA(s).

Done
  • Bottom board's pins and function is known.

Under work
Interfacing the touchpad driver chip.

Cannot find datasheets, nor can I identify even the manufacturer. I've done inital logic captures of it's communication with the main board, and all of it is documented in the github repository. Communication happens via one data pin and one clock pin at what seems to be 12kHz. Haven't been able to find out where the data- and clock pins connect to on the main board, but I'd assume it's programmable logic anyway.

Yet to be done
  • Interfacing screen (assuming lvds, and guessing a direct & simple protocol because of the 1366x768@60Hz speed and raw panel :P)
  • Interfacing keyboard (should be simple).
  • Battery control.

Repository
https://github.com/gima/motorola_lapdock
User avatar
gima
 
Posts: 2
Joined: April 4th, 2014, 2:12 am

Re: Motorola Lapdock's internals documentation project

Postby Retroplayer » April 7th, 2014, 9:53 am

As I understand, the keyboard and touchscreen are USB interfaced and the display is using HDMI (to the external world, I mean.) I am thinking of the Atrix. Is that what you are working with?

Internally, the touchpad sounds like I2C. Throw it on a bus-pirate (or Arduino or whatever) and experiment away. The keyboard and battery are probably also on the I2C bus. It is commonly used in systems like this.

Since they are all most likely using I2C, they are likely all using the same 2 signals. That may be why you are having trouble locating the signal on the mainboard.
Retroplayer
 
Posts: 127
Joined: May 30th, 2011, 6:28 pm

Re: Motorola Lapdock's internals documentation project

Postby gima » April 9th, 2014, 6:21 pm

Retroplayer wrote:As I understand, the keyboard and touchscreen are USB interfaced and the display is using HDMI (to the external world, I mean.) I am thinking of the Atrix. Is that what you are working with?

The Lapdock has male mini-usb and male mini-hdmi connectors that make connection with the Motorola Atrix. I don't have that phone, but I've been running the Lapdock (w/ modified connectors) clunkily using Raspberry Pi.

Retroplayer wrote:Internally, the touchpad sounds like I2C. Throw it on a bus-pirate (or Arduino or whatever) and experiment away. The keyboard and battery are probably also on the I2C bus. It is commonly used in systems like this.

I've done some initial captures with Open Bench Logic Sniffer and committed them to the repository. The clock seems to tick at 12kHz which to my wikipedia-thin "research" seems to be way below even the earliest standards' speeds (100kHz), which led me to think that it wouldn't be I2C. On the other hand I'm only beginning to learn these things, and it seems that things rarely go perfectly by the specs..

I don't think I'm brave/patient enough to poke around using unknowable commands with the driver chip. Who knows, I might even make it re-calibrate itself upside-down :( I'm building a recorder with which I can capture the data exchange happening from power-on to moving the mouse. That ought to shed some light on things - or the least enable a barely usable implementation which can talk with the driver.

Retroplayer wrote:Since they are all most likely using I2C, they are likely all using the same 2 signals. That may be why you are having trouble locating the signal on the mainboard.

A-ha! Didn't think of that, even though I've read it many times. Bleeh me. Thank you. I'll probably take all components off the board since the one I'm experimenting with component-wise is already ruined. Makes for an easier time tracing the LVDS connector pins as well.
User avatar
gima
 
Posts: 2
Joined: April 4th, 2014, 2:12 am

Re: Motorola Lapdock's internals documentation project

Postby Retroplayer » April 10th, 2014, 3:16 am

"I2C" Actually comes in many flavors. At it's based it's just a Two Wire interface and the definition is purely electrical. The different semi-standards can have their own protocols on that physical interface. Unless they completely re-invented the wheel, however, it is likely using one of them. And clock speed doesn't really matter as long as all things on the buss agree with it. It is synchronous communication, which means the clock drives the data on the lines. So it goes as fast or as slow as it wants.

There is TWI, I2S, SMBus, DDC, and many numerous flavors including bit-banging (just SPI is just a serial register interface which is why it works with shift-registers pre-dating "SPI".) So, don't get too hung up about it.

As far as randomly and accidentally doing something permanent, I would worry about that. To actually store values, most devices require an algorithm of sorts to do that. It would be very difficult to accidentally enter those algorithms. If you get an undesired effect, power cycling would cause the whole device to be reinitialized.

The first thing you need to know are the addresses of the components on the bus. With the bus pirate, you can run the I2C sniffer tool to find those. If you have a linux based system with I2C, it would poll devices and give you a bunch of information about them. Once you have the addresses, you can query it for registers. And then you are cooking with gas. Unfortunately, you won't know the purposes of the registers yet, but that is where experimentation comes in. But the serial engine is pretty common, so at least some of the registers will be documented in other chips.

It costs money to re-invent the wheel, and most manufacturers aren't going to do that. That is something all hackers should keep in mind.
Retroplayer
 
Posts: 127
Joined: May 30th, 2011, 6:28 pm

Re: Motorola Lapdock's internals documentation project

Postby Retroplayer » April 10th, 2014, 3:38 am

Starting with the touchscreen as an example... a resistive touch screen is just 2 to 4 resistors. A controller for this takes the resistance values using an ADC and outputs X and Y values. Parameters to set in the controller are just points to reference zero position, and total range. You want to define a window, meaning your extents will be max X and min X and Max Y and Min Y. That defines the maximum and minimum resistance values it should expect. This is all that gets stored in the controller. Now, calibration routines ask you for more points than this but they are using math on the program side to get more accurate values for the rectangle defined above. The controller then takes these min and max values and divides them by the resolution of the ADC to give a number of discrete values (like 0 to 255 for example.) So a value of 0 for X would mean the absolute left most point on the screen.

That is the calibration and from that point, it simply outputs X and Y values in reference to the min and max positions. A capacitive TS isn't going to be much different from the programmer's perspective. The difference being that it will have multiple X and Y values to register multiple touches.

Some controllers don't even store any of this information and instead it is left up to the software to handle that. Instead, they just output x and y values that readings directly from their ADC. However, one thing most controllers do is generate an interrupt when a conversion is available in order to sense a touch event.

So, as you can see, the number of registers needed isn't going to be all that many, and the device controller handles so much of it, that from the programming perspective life is pretty simple. All you need to know is which registers hold those X and Y values, where to access the interrupt register, and where to store write zero and extents values, and off you go.

But the question is this... what is your end goal here? All the hardware already terminates in USB and is functional using HID drivers. With the reverse engineering, what are you trying to accomplish beyond that? You want to be able to access this using the 2 wire interface instead of USB?
Retroplayer
 
Posts: 127
Joined: May 30th, 2011, 6:28 pm

Re: Motorola Lapdock's internals documentation project

Postby Retroplayer » April 10th, 2014, 3:56 am

BTW, Synaptic is the leader in touchpad controllers. Don't be surprised if this IC is just a clone of a Synaptics chip. Which, btw, use I2C and there appears to be information on the developers portion of their website:
http://www.synaptics.com/en/developers.php#info_content

Specifically, look at their MEPs protocol that is used over the I2C physical layer:
http://www.synaptics.com/sites/default/ ... 11-01c.pdf
Retroplayer
 
Posts: 127
Joined: May 30th, 2011, 6:28 pm

Re: Motorola Lapdock's internals documentation project

Postby modder_mike » May 5th, 2014, 8:12 pm

HA! I finally tracked down the owner of that touchpad IC. Sentelic Corporation, http://www.sentelic.com/en/index.php ... looks like they're mostly a provider to OEMs, so there is sparse information on any of their parts, and none on this one, a STL3898. There is some information on STL3888 out there, maybe they're similar?

Side note: Thanks for providing inspiration for me to start a new IC logo identification website. idmyic.com, coming soon to an internet near you. Mind if I use that chip image? I don't have a Sentelic product of my own to photograph.
modder_mike
 
Posts: 55
Joined: July 20th, 2013, 6:59 pm

Re: Motorola Lapdock's internals documentation project

Postby m00ny » January 24th, 2016, 2:17 pm

I've looked up STL3898 in the web. The only link I can find is this forum thread :lol:
Does anyone know where to get a replacement for this touchpad? Mine is just doing weird movements, randomly, by itself. My Lapdock was B-stock (I do regret that...)
m00ny
 
Posts: 1
Joined: January 23rd, 2016, 4:13 pm


Return to Project Logs

Who is online

Users browsing this forum: Google [Bot] and 2 guests