yashsingh1/xdaforums huggingface dataset:
[Atrix 4G Android Development] uskr:
If I plug the regular HDMI cable that comes with the Atrix on my phone/TV, a motorola logo shows up on the TV and my phone gives me the option to enter "Entertainment Center", which I think its the media center mode. I can watch the videos, see the photos and listen the music using a media center-like interface on the TV, that I control from my phone. A "remote control"-like interface shows on the phone when I enter that mode.

I can also get into webtop mode using adb shell as root and the trick I described on my other post. But I cannot control the webtop desktop. The bluetooth keyboard/mouse I paired with the phone have it's input directed to the phone interface and not the webtop X session.
[Atrix 4G Android Development] Ririal:
If no-one has posted a log of the phone actually docked by Friday, I'll have my Atrix with the laptop dock and I can get you guys whatever you need.
[Atrix 4G Android Development] GenesysLV:
Could some of the options in the build.prop file have anything to do with it?

ro.hdmi.mirror.enable=false

ro.hdmi.default.app=

hw.overlay.path.config=

# temporary enable AT&T NSUI feature from system prop.

# This should be removed once Flex is enabled in Olympus.

ro.mot.FTR.NSUI=true
[Atrix 4G Android Development] t0dbld:
I have spent most of my day doing edits to the build.prop for a variety of things.... most old tricks fail , and things there like you pointing to are resulting in no change , I have figured out alot how ever and will post when completed..... this is not the way to go though ignore this for now it will not get us desktop dock
[Atrix 4G Android Development] cegna09:
If you'd be kind enough to let me know how i'll be glad to. I know my way around a computer, but i'm really a mechanical guy.

Dock will be here tomorrow, so tomorrow night after work i'll get the logs and everything before i rip it apart.
[Atrix 4G Android Development] t0dbld:
sure

1. install the appropriate sdk for what ever OS you computer is running (aka windows etc) via http://developer.android.com/sdk/index.html

after download and install is complete run android out of the platform-tools folder

update the system so you have to proper drivers... once that is complete goto command prompt or terminal or what ever and navigate to the platform-tools folder exp cd "cengna/Desktop/android-sdk/platform-tools"

while all that is down loading and setting up you can plug your phone in via usb cord and select windows media sync from the notification menu on phone... let the drivers install on your machine and repeat for the other options in the menu

2. now on your phone from home screen hit the menu button than tap settings than goto applications than goto Development and check the box for usb-debugging. now plug phone into computer via usb

3. in the command prompt that is at platform-tools: type adb devices hope fully you see your device listed if so we are good

4. setup dock but do not turn .........

It is at this point i realized a problem in getting this log how can he keep usb plugged into pc for logging through log cat or ddms yet plug it into the dock ? The dock plugs into both usb and hdmi .... only if he uses a usb to usb male to male connection from dock back to pc ?
[Atrix 4G Android Development] pokey9000:
Get adbwireless from the market. Skip adb over USB altogether.
[Atrix 4G Android Development] xdraconis:
Ok, I'm trying to help but I am brand new to android as of when I got this phone a few days ago so cut me a little slack.

I figured out how to get the SDK, get ADB, run it over usb, store it in a place that the thing could actually write to, plugged it into my laptop dock, waited a little bit, and pulled it back out.

adb_log.txt is attached. If I did something wrong please let me know, I am very interested in helping.
[Atrix 4G Android Development] cegna09:
Installed adbwireless. If you just give me the commands for generating the log you need you'll have them tomorrow night. Assuming no one else beats me to it.
[Atrix 4G Android Development] t0dbld:
OK thats great jsut a quick look through looks like we need to launch com.motorola.dock.DesktopDock/.DLauncher when hdmi gets connected i think if we manage that it will take care of the rest
[Atrix 4G Android Development] t0dbld:
I will have a droid x dock to use this weekend , i will test the magnet theory than
[Atrix 4G Android Development] timtucker:
Sadly I won't be able to jump into the game in earnest until tomorrow evening(ish), but I have the phone and dock now. If more logger output or other info is requested I'll do my best to find a few spare minutes to help the cause.
[Atrix 4G Android Development] psufan5:
Ive run a magnet all over the body of the phone... its not a magnet. Its probably in the USB connection which might warrant a JIG attempt to trip it.
[Atrix 4G Android Development] Andrmgic:
In the original droid, it was a magnet in more than one place.. but in this particular case it is probably just device ID..
[Atrix 4G Android Development] shawnbuck:
There doesn't appear to be a magnet in the device. Here is a tear down for it:

http://www.ifixit.com/Teardown/Motorola-Atrix-4G-Teardown/4964/1

Also, I want to say that it is software controlled, because it was working originally in CES. I bet they just disabled the feature, so the Atrix itself would not compete with the multimedia dock AT&T is selling.
[Atrix 4G Android Development] infrared411:
Fully working webtop without dock (plus all other docks' features)

I have it completely working with usb otg host mode and a cheap usb 2.0 hub connected. A keyboard and mouse are plugged to the hub for the webtop session. I need to pull the files and check what change made it work but I have to go to UTA this morning for a lecture. I did see bluez problems and that is what caused the interface to echo HID to the Android OS instead of the webtop session. I am unsure if bluetooth HID can be enabled without the dock, it should be possible though.

BTW the usb hub has been hacked to pull pin 4 (ID) to pin 5 (gnd) low at a predetermined time. It also has to be a powered hub (i am seeing less then 100 ma sourced at the atrix micro usb which is too little for a keyboard/mouse). For some reason the atrix refuses to charge with the powered hub with it in host mode and the battery suffers. I had 92% battery when webtop started and it was at 79% after only 8 min of hdmi output.
[Atrix 4G Android Development] cegna09:
see, i knew i wasn't talking out of my ass with the ID pin thing. I just wasn't calling it the official name (USB OTG).

anymore details you can provide? I was going to mess with the exact same thing tonight when i got the dock to see if i could replicate it.
[Atrix 4G Android Development] infrared411:
config

It is in the configuration and there is different values being sent to the atrix over the USB telling it which dock it is using and how to configure charging. It has hung on me twice so I am thinking there is one more thing I am not seeing but the keyboard and mouse were working the first time I started. After I rebooted the phone (could not exit webtop after disconnecting hdmi) it would not accept the mouse keyboard from the hub. I will experiment more when I get home.
[Atrix 4G Android Development] tomit12:
I'm not super sure how to edit there logs down so they aren't huge, but attached is the log for when I plug the phone into my HD Dock and start the webtop, and the other is for when I plug the phone into the lapdock.

Let me know if there is something else I can do that would be more helpful. :)
[Atrix 4G Android Development] phreak9i6:
Hi I'm new :)

I've gotten this far as well. I did some poking around and it looks like the xorg.conf (because the startX.sh is launching xorg) has Mouse1 and Keyboard1 defined. traditionally its Mouse0 and Keyboard0...

that being said, we may be able to attach a bt keyboard/mouse and create device links to /dev/mouse /dev/keyboard or what not. It would be initially a little hacky... or better yet, modify the xorg.conf (for 1920x1080 output!)
[Atrix 4G Android Development] phreak9i6:
also how are you guys attaching a kbd/mouse via bluetooth (sorry im a bit fresh with android)
[Atrix 4G Android Development] phreak9i6:
okay I did it!

I got mouse support by linking /dev/hidraw0 to /dev/mouse

I bet I can do the same with a keyboard :) and here we go... :)

for those wanting to try you need to remount / as read-write

mount -o remount,rw /
[Atrix 4G Android Development] joeavery2:
Interesting thing

Ok so I plugged my phone into the Laptop dock but not all the way. The HDMI connected to the frozen Laptop/webtop screen but because I had not seated the phone all the way the USB was not connected and the phones display was on and showing the options for media center or do nothing. Maybe that give some insite to it's operation.

I think the HDMI Xsession is always active but the USB triggers it by a call, This may all be stuff you guys know already. I've read in the dual root forum some of this. The two should probably be combined.
[Atrix 4G Android Development] cegna09:
I can mount a bluetooth kayboard and mouse (ok it's the logitech DiNovo edge so it has a built in touch pad) without any dock.

have dock, acquiring logs now, then tearing it down to figure it out.
[Atrix 4G Android Development] cegna09:
adb wireless used. started the logcat, put in dock, started webtop, launched firefox, went to the front page of xda, pulled from dock, plugged in just the HDMI, launched entertainment center, exited, stopped log.

if you want something different, or i did something wrong let me know.

Edit: i'll upload the log again tonight. i want to remove a little bit of it. somehow i don't think the world needs to see the bits about my wifi and some other stuff. I don't think there is really anything damning in there, but just to be safe...
[Atrix 4G Android Development] slhawkins:
Thanks cegna09!!!

I'm not going to post all of the code.. but here's the more 'relevant' part. Copy the timestame and open his log.. do a search to find it and then read below this part. It does a couple more things with the Dock ID.

02-24 17:34:34.729 4001 4001 D DockService: onStartCommand()
02-24 17:34:34.729 4001 4001 D DockService: intent action = com.motorola.dock.webtopevent
02-24 17:34:34.729 4001 4001 D DockService: flags = 0
02-24 17:34:34.729 4001 4001 D DockService: startId = 15
02-24 17:34:34.729 4001 4001 D DockService: DockHMDIEventHandler()
02-24 17:34:34.729 4001 4001 D DockService: Received Intent with action com.motorola.dock.webtopevent
02-24 17:34:34.729 4001 4001 D DockService: Dock Status = Connected
02-24 17:34:34.729 4001 4001 D DockService: HDMI Status = Connected
02-24 17:34:34.729 4001 4001 D DockService: Dock ID = 6C2154028265,1A8000
02-24 17:34:34.729 4001 4001 D DockService: Dock Type = Smart Dock
02-24 17:34:34.729 4001 4001 D DockService: mLastDocked=false
02-24 17:34:34.729 4001 4001 D DockService: mLastDockType=Smart Dock
02-24 17:34:34.729 4001 4001 D DockService: mIsChargingByAC=true
02-24 17:34:34.729 4001 4001 D DockService: mACPresentTime=1298586873834
02-24 17:34:34.729 4001 4001 D DockService: interval =905
02-24 17:34:34.729 4001 4001 D DockService: Dock true HDMI true Event received
02-24 17:34:34.729 4001 4001 D DockNotification: UpdateDockNotification()
02-24 17:34:34.729 4001 4001 D DockNotification: Dock Status = Connected
02-24 17:34:34.729 4001 4001 D DockNotification: HDMI Status = Connected
02-24 17:34:34.729 4001 4001 D DockNotification: Dock ID = 6C2154028265,1A8000
02-24 17:34:34.729 4001 4001 D DockNotification: Dock Type = Smart Dock
02-24 17:34:34.729 2441 2486 D PortalService: Stopping Foreground Status and Intent
02-24 17:34:34.739 2441 2493 D PortalService: Starting Foreground Status and Intent
02-24 17:34:34.739 4001 4001 D DockAppUtility: StartCustomPickerUIActivity()
02-24 17:34:34.739 4001 4001 D DockAppUtility: isDockConnected : true
02-24 17:34:34.739 4001 4001 D DockAppUtility: isHDMIConnected : true
02-24 17:34:34.739 4001 4001 D DockAppUtility: Dock ID = 6C2154028265,1A8000
02-24 17:34:34.739 4001 4001 D DockAppUtility: Dock Type = Smart Dock
02-24 17:34:34.749 1504 1509 I ActivityManager: Starting activity: Intent { act=com.motorola.dock.action.LaunchCustomPickerUI flg=0x10000000 cmp=com.motorola.dock.service/.ui.DockExperiencePickerActivity (has extras) }
[Atrix 4G Android Development] naturefreak85:
You got that with alogcat? The real question is, does each dock have a different ID? I'll go to the AT&T store here and check it out with alog (hopefully it will capture it) and we can see if the ID's are the same.
[Atrix 4G Android Development] bendoe91z28:
Somebody figured it out. Now we just need some fine tuning and an app.

http://xdaforums.com/showthread.php?p=11640501#post11640501
[Atrix 4G Android Development] DJ_smooth:
Hello, first post to XDA Dev.

Don't know diddly squat about Android software yet but I know a lot about hardware. I just got the Atrix last week and it is my first Android device.

I'm interesting hacking dock mode and hacking USB host mode.

The previous posters are all correct and I think we are almost there.

USB On the go standard calls for grounding the 5th "ID Pin" of a Micro or Mini USB connector to send a USB OTG capable device from the default slave mode into the host mode.

But I'm betting motorola got creative and uses a variable resistance between the ID pin and ground to allow the Atrix to "know" what kind of dock it is connected to.

The kicker is the car dock... If you plug an atrix into a car dock that is totally unpowered, the atrix knows it is in a car dock. And the Atrix can apparently differentiate between at least four different USB plug in events (car, charger, laptop dock, and multimedia dock.

I don't own any of the docks but does anybody who owns the dock have a good ohmmeter with needle probes? I bet if you measure the resistance between ground and the ID pin you will get different values for each type of dock.

David
[Atrix 4G Android Development] cegna09:
I don't fully trust my multi-meter right now, since it hasn't been consistently reporting resistance right, but i did get it to lock on to a resistance of 1.426Mohms between pins 4 and 5 on the multimedia dock when it had nothing plugged into it (power, HDMI, usb, etc)

I wish Labview wasn't so damn expensive, i want a license. If i had one i could set up a DAQ to watch the resistance between those pins as the phone goes in and out of webtop.
[Atrix 4G Android Development] DJ_smooth:
It is not going to be something that changes and you can't measure normal resistances like that anyway when the circuit is powered.

Wonder if the local ATT store would freak if I probed their display docks :)
[Atrix 4G Android Development] cegna09:
:o

I read this line from your first post to mean that they had variable resistance in the dock.

I'm a mechanical engineer, so while i do know some basics of electrical, they aren't my specialty. If you want to know anything special about the multimedia dock i'll do my best to provide info.

I've tried making a usb cable with identical resistance values to the dock and tricking it, but no dice, i think there is more at play here. Or i'm just failing at getting the resistance right. either is possible.
[Atrix 4G Android Development] bimmerd00d:
I just bought the car dock that only has USB. It somehow knows to launch the car dock app using only the USB, so maybe the extra "pin" is in that not the HDMI...thoughts?
[Atrix 4G Android Development] DJ_smooth:
Sorry, did not mean to come across as snotty...

I mean that most likely a car cradle has one resistance, a multimedia dock another, etc.

Your homemade cable with the resistances, did it inject power onto the V+ line or did you leave it floating? Usually USB OTG devices won't supply power.

anyway, I'm supposed to be working on other stuff so I will have to delay until this evening.

David
[Atrix 4G Android Development] cegna09:
Yup, it certainly is in the USB, not HDMI. If you want to help out you could get a reading on what the car dock resistance is. Go to radio shack, get a microUSB to miniUSB adapter (female micro, male usb). You can then use an x-acto knife to split open the plastic housing and expose nicer access to the backside of the mini plug for probing.

we need the resistance between pins 4 and 5
[Atrix 4G Android Development] cegna09:
you didn't, was just explaining my background. And yes, what you said about the different resistances makes sense, it's actually the same thought i've been having.

I did have power, since the dock provides power to the device when attached. I'm going to play with it some more tonight and see what else i can figure out.
[Atrix 4G Android Development] cegna09:
ok, new log, trimmed down. It should start just before i plug it in. Put it in the dock around 17:37:00 or so. Removed from dock at about 17.37.27.

now back to my attempt to dismantle this thing.
[Atrix 4G Android Development] bimmerd00d:
Why do i need the adapter? Can't i just place my meter on the pins of the dock's connector? What's the mini-usb adapter for? I can definitely do this tomorrow, but im unclear on what the method is.
[Atrix 4G Android Development] cegna09:
pins on the micro are just tiny. when you open up the adapter it gives you some larger pins that are easier to probe on the back side on of the mini plus.
[Atrix 4G Android Development] :
Isn't this what you guys are trying to do?

http://xdaforums.com/showthread.php?t=969195
[Atrix 4G Android Development] t0dbld:
did you not read the form you linked to first ? That is launching an inoperable webtop- dock, so it is at this time useless, we are trying to find the right way of doing it
[Atrix 4G Android Development] cegna09:
Since i'm useless with software, i'm continuing my hunt with hardware. They actually bring the ID pin wire to the board, so whatever ID method they're using is being done on the board. Once i sort out why my multimeter refuses to read resistance anymore i'll track down what is actually going on there.

HDMI is literally a pass through cable to the connector on the back. Oh, and there is a metal plate on the bottom cover to give the dock weight. nice.
[Atrix 4G Android Development] DJ_smooth:
First if you are in or around Houston, game on. I'll bring my oscilloscope and digital logic analyzer and we can figure this out.

Second, could you either take better quality images at higher resolution of the board or at least read off the markings on the bigger chips? If we can figure out what IC's it is using, it might help the effort.

Progress. The fact that the ID pin is on the board means it is critical.

David
[Atrix 4G Android Development] cegna09:
I'm in NH, sorry.

I'll get some better pics this weekend. My good camera's battery was toast, so i was forced to use the Atix's camera. So until i can get you some better pics, here are the chips.

Black

M430F5522

T1(i?) 08K D looks like a lower case i without the dot

E39X G4

Red [BB]

DIR9001

06TG4

D76D

Orange [BB]

PCM1753

OAC17K

Yellow

TI chip

DRV602

06TG4

AHZ0

Grey TI chip

LM358A

07K

EPERG4

Red TI Chip

54231

08M

ACSX

Blue SMSC

USB25148

D1036 A2P10

WJ1433230

CT1-TW
[Atrix 4G Android Development] DJ_smooth:
Is it possible that SMSC chip is a USB35148? That would make some sense and I am not able to find that part number family on their website.

David
[Atrix 4G Android Development] pokey9000:
Looks like the DIR9001 receives the spdif over HDMI and drives the PCM1753 DAC, and the DIR602 is the line level amp. The black chip is a TI MSP430 micro, probably for performing CIR to USB for the remote and doing the dock ID handshake (if it exists). The unpopulated header is probably for programming and debug.

The SMSC part might be a USB2514B. That part has a configuration interface via an external EEPROM or SMBUS, which the micro likely drives.

I can't figure out what the LM358 and the big inductors on the end of the board are for.
[Atrix 4G Android Development] cegna09:
I think this is right. It's defiantly USB2514X, where X is either an 8 or B

tiny chip and my magnifying glass isn't great.
[Atrix 4G Android Development] kriffer:
I'm wondering wouldnt it be possible just to make another xsession and we could then access webtop that way?
[Atrix 4G Android Development] slhawkins:
I do believe the issue at hand is the ability to use a mouse/keyboard with Webtop. However - maybe creating our own XSession we could direct the bluetooth mouse/keyboard to the Webtop. I do believe there are "options" for such a thing in the XSession configuration files but I could be wrong.
[Atrix 4G Android Development] droidbird:
kriffer,

I'm thinking along the same lines as you. From my poking around last night it is just an X server running on the HDMI display, there doesn't appear to be anything overly unique about it. I won't be in front of my dock until tomorrow and plan to take a look. First up is changing /osh/etc/X11/xorg.conf to up the resolution from max 1280x720 to 1920x1080 as the modelines are already in the conf file. More about my first pass findings here:

http://xdaforums.com/showpost.php?p=11681379&postcount=49
[Atrix 4G Android Development] kriffer:
@droidbird, so you can see that phreak9i6 had the same idea and from my poking around changing the res shouldnt be to hard. now i'm not totally understand the linking of the keyboard and mouse but couldnt we just set it so; say from a laptop running exceed or x11 we could then just access the webtop session. we would then have a keyboard/mouse/screen all through an ssh session.
[Atrix 4G Android Development] Smith7018:
AFAIK, ssh is only command line based so what you're looking for is a VNC server. VNC allows one to remotely view/control another computer.
[Atrix 4G Android Development] droidbird:
I'm thinking XDMCP session by fixing the X startup script or killing the existing X and launching from the command line.
[Atrix 4G Android Development] phreak9i6:
I also symlinked /dev/mouse to the bluetooth device for the mouse and got full functioning mouse support (although it mirrored on the phone display as well...).

Basically when you attach any hardware to the linux system a device node will need to exist in order to use it, in more modern linux distros this happens automatically. For the BT mouse i used, I got a /dev/hidraw0 device (IIRC). X11 is looking for something else, typically its /dev/mouse. So easy fix "ln -s /dev/mouse /dev/hidraw0".

While I applaud the hardware hacking, this has to be easier at the software level. We should be looking at attaching a keyboard/mouse via BT, and launching the webtop bootstrapping (for lack of a better term) scripts. A few symlinks or modified conf files will go a long ways.
[Atrix 4G Android Development] kriffer:
Awesome, thanks for that info phreak. After a little reading through the /var/log/Xorg.log file I noticed that it wouldn't set a resolution and then went to the "Virtual" size. Anyways, I changed the numbers there and the res changed when i loaded it up via hdmi. I still have the screensaver though. I may buy a bt mouse and keyboard tomorrow and do the symlink but I would like to just get the ssh -X working. Wondering does the virtual desktop 0,1 or 2 have anything to do with the actual session? Lastly there are no -nolisten tcp flags in the xorg file, but I did find one in the xserverrc. Could they be anywhere else?
[Atrix 4G Android Development] droidbird:
kriffer,

The --nolisten tcp wouldn't be in the xorg.conf, it would be in the startx (or similar) routines and would likely be found somewhere in /etc/X11 or maybe in /etc/init.d, depending on how it is started.
[Atrix 4G Android Development] infrared411:
MSP430 mcu

You are right about all of that. The lm358 is an op amp that needs the inductors (sourcing current from or to?) Was wondering what the large black blobs in the pics are.

I develop with MSP430's and have many of them in my home doing things.

I really want the code for the msp430 on the dock. If you have a dock, I can walk you through connecting spy-by-wire to the IC and dumping the firmware. PM me for details.
[Atrix 4G Android Development] pokey9000:
I don't have a dock, and won't even have an Atrix until later today. But I do have a spi-by-wire ice from a Chronos devkit. Maybe if Costco wants to cut me a deal on a dock...