How To: Fastboot or ADB on Ubuntu returning no devices or “Waiting for Device”? Here’s how to fix it.

I was having some issues getting my devices recognized in fastboot/adb on Ubuntu.

“fastboot devices” just returned back to the terminal prompt, without showing any connected devices, so I tried using the -i option to specify a usb vendor ID, like “fastboot-linux -i 0x413c reboot”. This just hung on “waiting for device”. I kinda ignored it, since I actually use my mac for most fastboot/adb, but tonight I was bored and fucking off on the CyanogenMod forums shoutbox, and someone was having the same problem. I did a bit of googling and found a solution that worked for me (and M.P.)

As usual, I’m not responsible for fucking your phone up or accidentally dividing by zero or going back to the future or hacking the gibson or anything else that happens. I’m not an expert. I wouldn’t listen to me, I’m kinda an asshole, I have no idea what I’m talking about, I’m usually just guessing. Proceed at your own peril, etc, etc, etc.

Here’s the step by step fix, assuming you’re running ubuntu 10.04:

1. Open a terminal window.

2. Log in as root.

sudo -i

3. Create a UDEV rule file.

cat > /etc/udev/rules.d/51-android.rules

This should give you a blinking cursor at the very beginning of a blank line, it’s waiting for you to tell it what the file needs to contain.

4. Enter this AFTER YOU REPLACE “XXXX” WITH YOUR VENDORID:

SUBSYSTEM=="usb", SYSFS{idVendor}=="XXXX", MODE="0666"

(You can find your vendor ID on this page.
For example, for my Dell Streak, I would use:

SUBSYSTEM=="usb", SYSFS{idVendor}=="413c", MODE="0666")

5. Press CTRL + D to save, it should return you to the terminal prompt

6. chmod the new file

chmod a+r /etc/udev/rules.d/51-android.rules

7. Try fastboot. It should work now.

fastboot devices

Hopefully you get “Attached devices” with your devices serial number, if so, you’re good to go, fastboot should no longer hang at “waiting for device”. To be sure, try

fastboot reboot

If your device reboots, you win life.

Does your HTC Desire/Nexus One have an AMOLED screen or a Super LCD screen? Here’s how to tell the difference.

After a few hours of pulling my hair out digging around in the system files in an attempt to find a way to determine if someone’s HTC Desire has an AMOLED screen or a Super LCD screen, I realized there was a much easier way to tell the difference.

An AMOLED screen doesn’t actually display the color black at all, it simply turns off any pixel that is supposed to be pure black.

An LCD screen, on the other hand, does actively render the color black.

As such, an AMOLED screen displaying a black pixel looks exactly the same as an AMOLED screen that’s “turned off”, while an LCD screen looks decidedly different.

So, if you open photoshop/paint/whatever, and make an image that’s totally black, (hex code #000000), or just use this one I’ve so helpfully provided, it will look a lot different on an AMOLED screen than it does on an LCD.

This is black.

This is that very same image displayed on a Nexus One, with an AMOLED screen (left) and a Dell Streak, with an LCD screen (right), in the dark.

And both off, in darkness.

Note the AMOLED Nexus One looks the same, where it’s obvious when the Streak’s screen is on.

Now in normal light. Both powered on. Nexus One on the left, Streak on the right.

And again powered off.

Again, you can clearly tell when the Streak’s LCD screen is powered on, but the Nexus One’s AMOLED screen looks the same. This should be a pretty easy indicator as to which screen you have.

How To Unlock Your Nexus One and Flash a Modded ROM.

I wrote this for a forum post, and figured I would share it here too. Hope it helps. Check the XDA Developers forum and http://www.cyanogenmod.com/ for a lot more info. None of these files/roms were written by me, and all credit goes to the people who did the hard work. As usual, I assume no responsibility. Unlocking your bootloader will technically void your warranty. I’m just telling you what worked for me, I’m not a professional. I wouldn’t even listen to me, I’m usually drunk. There’s a solid chance I’m just making all of this up. Also, I did this all on a Mac running OSX Snow Leopard. If Linux/Windows/Whatever is vastly different, you’re boned, and it’s not my fault. Essentially: Don’t come crying to me.

Download the Android SDK:

http://developer.android.com/sdk/index.html

This will get you a .zip file. I would extract it to the root of a drive or just one folder down (like to C:/ or ~/ in mac or C:/sdk) You’ll understand why later. After it’s extracted, go find the “tools” folder. Double click the “Android” file. It will pop up a command/terminal window, then a GUI. In the GUI, click on “Available Packages”, select all of them and install. This will take a bit. When it’s done, you can just close the window and the command prompt.

Now you need to add fastboot. You can compile it yourself, but that would be silly. Here’s a windows 32 bit version I found on XDA:

http://files.me.com/mzsigler/v94lxh

Extract the zip to the “tools” folder in the android SDK.

Here’s the Mac version, it’s not compressed, just download it and put it in the “tools” folder of SDK, no need to unzip.

http://files.me.com/mzsigler/29kua4

In all honesty, I don’t remember where I downloaded that file, but it works great. If you compiled it, please let me know and I’ll credit you.

Then you need Amon’s recovery image. Save it in the “tools” folder in your SDK (picking up on a pattern here?).

http://rapidshare.com/files/366400383/recovery-RA-nexus-v1.7.0.img

Then you need a new rom. Download it to your computer, then move it to the SD card on your phone, don’t unzip it or anything. I highly suggest this one from CyanogenMod. His roms are fast and stable, by far the best I’ve found.

http://n0rp.chemlab.org/android/nexus/update-cm-5.0.6-N1-signed.zip

I believe in windows you need to download some drivers, but I’m not sure, as OS X didn’t require any drivers. Windows users should google “Android USB drivers” right about now, and come back when they’ve made sure they have the right ones.

Connect your phone via usb and put it in bootloader mode by turning it off, then holding the trackball down while you power it back on. It should boot a white screen and say “Fastboot USB” near the top.

On your computer, open Command Prompt or Terminal, depending on your OS, and navigate to the folder the SDK is in and find the “tools” folder. If you listened to me and saved it somewhere easy, like the root of a drive, this is simple. Say you saved it in C:/sdk. You would click the start button, then “run”, then “cmd”. This gives you a command prompt. To get to the proper folder, you would type “cd\” to go to the root of C:, just so we’re all on the same page, then “cd sdk/*android_sdk_orwhatevertheynamedit*/tools”. In my case, on a mac, it’s “cd /android/android-sdk-mac_86/tools” If that still doesn’t make it clear, you might be better off just leaving your phone on the stock rom. Effectively, navigate to the tools folder of the sdk in terminal/command.

Now type “fastboot devices” and hit the enter key (Or “./fastboot-mac devices” for a mac) and see if it recognizes that your phone is connected If so, you’re ready to go.

*When you unlock the bootloader in the next step, it will wipe the phone and erase all of your data. Any pics on the SD card are safe, and you can redownload the apps you’ve paid for, but if you have a text or something you find important, make sure it’s backed up*

First unlock the bootloader. Type “fastboot oem unlock”  then hit enter (Mac: “./fastboot-mac oem unlock”). It should walk you through the unlock process and warn you that your warranty will be void. Just follow the instructions. Once you’re done, boot back into bootloader mode by holding trackball and powering up. You should have an open lock under the multicolored Nexus X now.

It will take you back through setup, but you can just power down, since you’ll have to setup again when you flash the new rom.

Now you’re gonna flash the recovery image. Again, hold the trackball while you boot the phone to put it in bootloader mode, and again, in command prompt, navigate to the /tools folder and type “fastboot flash recovery recovery-RA-nexus-v1.7.0.img” (Mac: “./fastboot-mac flash recovery recovery-RA-nexus-v1.7.0.img”)

It should flash the recovery image. Now reboot into bootloader again. (Hold the trackball while you power your phone on)  This time use the volume and top (screen lock) button to navigate. Press the top button to select “bootloader”.

It will load another screen. Press the volume down button to select “recovery”. At first it will do nothing, this is normal, it’s checking the device. You’ll see a few things flash on the screen in green, again, normal.

It will go back to the menu, and now you can use volume down to select “recovery”.

Highlight it and press the top button to select it. You’ll see the multicolored X as it boots into recovery. At this point, your trackball will be used to select things.

Go to “Wipe” and do a “Factory Reset” wipe first, then go back to the main menu.

Select “Flash zip from sd card”, pick the file I had you download above (the rom file), confirm that you want to flash.

Once it finishes you’re done. Boot up and set up your phone.

Email mobilesig@gmail.com if you spot any mistakes.

How to: Add “Send in email” to your right click menu in Snow Leopard.

Just checking out automator on the new Macbook, so I thought I would share what I learned. The video is fairly self explainitory, but here’s the gist:

Open Automator.

Pick “Service”

In the right hand pane, at the top, set it so it reads receives (Files or Folders) from (Finder)

Now move to the far left and pick the Mail section.

In the next pane to your right, find “New Mail Message”, and drag it to the right.

Now save as something that makes sense, in my case “Send to mail recipient”

You’re done. Right click any file or folder on your computer, and at the bottom you’ll see “Send to email recipient” or whatever you named it.

Sounds complicated, but it’s really insanely simple, the video does a better job of illustrating how easy it is.

Install Windows 7 from a USB Thumbdrive, perfect for EeePC’s

So you’ve got a netbook that came with Windows XP, and you want to put Windows 7 on it, but it doesn’t have an optical drive. You could buy Asus’ External DVD Drive, which is pretty slick, but if you only need to install Windows, there’s a way to do it without dropping the money on an optical drive. Pick up any 4GB or larger USB thumb drive, if by some chance you don’t already have one. I  used an 8GB A-Data Drive I had lying around. Get your copy of Windows 7. If you downloaded it, you’ll need to find where the ISO was saved on your computer. If you’re using a disc, put it in the disc drive on your other Windows based computer, but don’t run it, obviously.

Stick the USB drive into your windows based computer, and disconnect any other external drives, just to be on the safe side. You need to make your thumbdrive bootable and format it. Luckily you can do this with a program built into Windows.

Click start, and select “Run”. A box will pop up asking you what you want to run. Type “cmd”. This will open a command prompt.

Type “diskpart” (without quotation marks) and it will open the command line program DiskPart. You’ll use this to prepare your thumbdrive.

First, type “list disk” and press enter. This will bring up a list of the volumes connected to your computer. You need to determine which is your thumb drive. It should be pretty easy based on the disk size. In my case, I have two 100gb HDD’s, a 2GB SD card for a camera, and the 8GB thumb drive. The thumb drive is disk 3. Use whichever disk your thumbdrive is, and type “Select Disk X”, with X being the number of your drive. This is vitally important. We’re about to format the volume, which will erase everything on it. If you select the wrong disk, you’ll lose all the data on the disk you select. Be EXTRA sure you pick the volume number that corresponds to your thumb drive, and if you fuck up, don’t come bitching to me.

Ok, now we’ve selected the thumb drive. Type “clean” and then hit enter. This will clean the volume.

Now type “create partition primary” and hit enter. This creates a primary partition on your thumb drive.

Now “active” and press enter. This marks the newly created partition as active, so that you can boot from it.

Finally “format fs=fat32″ and press enter. This will format your thumbdrive using the FAT32 file system. It will probably take a few minutes, depending on the size of your drive. Here’s a screenshot of the whole process, so you can compare.

Now you can close diskpart. The next thing you need to do is extract your windows file to the thumb drive.

You’re gonna need a program to extract the files, and the best one I know of is 7zip. 7zip is free, open source, and multiplatform. Download and install it from 7-zip.org. It installs like any other program, so I’ll let you handle that.

Once you have 7zip installed, Hit “Start” and “My Computer” or “Computer” depending on your version of windows. Navigate to where the Windows 7 ISO is located. If it’s on a disc, it will be in your disk drive. If you downloaded it, it will be where ever you saved it.

Right click on it, and you’ll see a new menu option, “7zip”. Hover over it, and another menu will pop up. Click on “Extract Files”

Once you do, you’ll get a popup menu with options to extra the data from your disc image file (ISO). Click on the ellipses (…), and click “Computer”. Navigate down to your thumb drive, and select it as the location to put the extracted files. Should look like this, except with the drive letter of your thumb drive, if it’s different from mine.

This might take a few minutes, depending on the speed of your computer and the speed of your USB drive. You should end up with a USB drive that looks like this.

Now “Safely Remove Hardware” and remove your USB drive. You’re ready to install.

Shut down your netbook and stick the USB drive in it. Boot it up, and go into boot options. On an EeePC, you just tap ESC while it’s booting up and you’ll get a menu. On others, you might need to go into BIOS and change the boot order to make USB first. Select the USB drive from boot menu, and hit enter.

It should start loading windows setup as normal, and from there it’s all the same as installing from a disc.

Enjoy your new windows installation!

Buy Windows 7

How to: EeePC SSD Replacement

I actually upgraded my EeePC SSD from the factory 4GB to a Super Talent 16GB unit a few months ago, but I finally got around to doing a how to. As such, I didn’t actually swap anything, the SSD is the same in all the pics.

First, break out your new SSD.

1

Power your netbook off, and remove the battery. The right side slider should flick to the right and stay there.

IMG_2227

Slide the left one to the left, hold it there, and pull the battery toward the rear.

IMG_2228

Toward the bottom, you’ll see two phillips screws. Remove them both.

IMG_2229

Pry up a little on the access door, and it will pop right out. The SSD is at the top, the ram is at the bottom.

IMG_2230

On the right side of the SSD, you’ll see two more phillips screws.

IMG_2232

Remove these, and the SSD will pop up, like so:

IMG_2236

Slide it out to the right.

IMG_2238

Now slide the new one in, and reverse the steps above. Once you get everything buttoned up, install your OS from a thumbdrive or external DVD, and you’re good to go.

IMG_2241

Enjoy your extra storage space :D

Super Talent SSD on Amazon