adventures in technology
Posts tagged mobile
Hosts files and the Google Android emulator
Feb 13th
Using the Google Android emulator is a good way to test how a website behaves on Android devices.
Connecting to your local computer
http://10.0.2.2 is the URL to connect to a website hosted on your local computer. localhost or 127.0.0.1 will not work! This is all defined in the documentation on Android emulator networking.
Using a hosts file
The Android emulator will not make use of your local hosts file. This is unfortunate when your website relies on host headers to work correctly (eg. SharePoint). What you need to do is edit the hosts file on the Android emulator image itself.
- start your Android Virtual Device (AVD):
emulator -avd myAvdNameHere -partition-size 128
Located in C:\Program Files (x86)\Android\android-sdk-windows\tools\ on Windows 64bit
Note
The partition-size parameter is needed to expand the image size to prevent an error in step 5. If you try and perform these steps after starting the emulator from the UI you will receive the following error:
failed to copy ‘c:\temp\hosts’ to ‘/system/etc/hosts’: Out of memory - remount the device image as writable:
adb remount
Located in C:\Program Files (x86)\Android\android-sdk-windows\platform-tools\ on Windows 64bit
- save a copy of the existing hosts file to a temporary location on your host computer:
adb pull /system/etc/hosts c:\temp
- edit the hosts file adding an entry pointing to your host computer:
127.0.0.1 localhost 10.0.2.2 mytesthost
- save the edited hosts file to your Android emulator:
adb push c:\temp\hosts /system/etc
You can now browse to your entered hostname in the Android browser.

Windows Phone 7 Series – notes from launch
Feb 16th
Microsoft announced Windows Phone 7 today. It looks pretty amazing. The only negative point is that it won’t be out until the fourth quarter of 2010.
Below are my notes from the launch:
Approach
- WP7 changed approach, focused on end users, business and otherwise
- visual design is called “metro” graphical intense, high motion ui
- home screen is called the “start bar”
- focuses on tasks rather than apps – tasks form a hub
- Syncing to social networks seems to be a hands-off experience, sign in and it does the rest
- Microsoft want to maintain stricter control of the look & feel of the device while still allowing for third-party innovation
Hardware
- three hardware buttons (back, start, search)
- require capacitive touch (minimum 4 point touch)
- WVGA screen
- FM (or digital?) radio
Search
- context sensitive – different results based on where you are in the phone (contacts, email etc.)
- automatically uses GPS
- search can be of three types, attempts to choose the most appropriate one automatically (local, news, web)
Web Browser
- based on PC code for maximum compatibility
- pinch zoom
- tap to zoom (zoom to column on page)
- sub pixel positioning for text)
- recognizes phone numbers and addresses and makes them linkable
- supports tabs
People Hub
- Aggregates all your contacts from social networks (no twitter yet by the looks, I imagine this will change)
- Shows people you have communicated with recently
- “What’s new” feed: feed from all your social networks
Office Hub
- Access to Microsoft Office apps like OneNote, Excel, Word etc.
Games hub
- Syncs with Xbox live
- Focus on social gamer experience
- earn gamer score, achievements
Me tile
- Simultaneously update your social networking status to multiple sites
- Supports all common providers including gmail, yahoo as well as Exchange (of course)
- Never see a loading bar, works against a local cache (very fast experience)
Text
- Supports SMS, MMS
- Supports portrait/landscape typing modes
Calendar
- Automatically merges your personal and work calendars
Pictures
- gallery lets you browse all pictures
- “mosaic” shows recent or favourite pictures
- “What’s new” feed shows latest pictures from your social networking sites (Facebook, Windows Live etc)
- Album view combines folders from photos synced from Zune software on your PC with albums from Facebook, Windows Live
- Social networking comments are displayed when you view a picture
Music and Video
- Full Zune HD experience
- Supports Zune pass/subscription
Other
- toolbar is always available at the bottom to access “enhanced” commands
- UI is not completely done (especially some of the buttons you see)
- one press to correct words you’ve messed up in keyboard mode
More information:
http://channel9.msdn.com/posts/LauraFoy/First-Look-Windows-Phone-7-Series-Hands-on-Demo/
