Pages

Thursday, 24 March 2011

Using Mobile Broadband in Singapore with Huawey Mifi

How to use mobile internet when visiting Singapore?

I’m currently on holiday in Singapore and I carry around an Iphone, an Ipad and a Vaio (as you do when you’re on holiday). I bought a Mifi device (Huawey E585) a few weeks ago, which means I can create my little Wifi hotspot anywhere I go as long as I have a 3G SIM card.

Starhub sells a pre-paid SIM card called MaxMobile Prepaid. It contains a credit of SGD12.

  • You can buy it in any Starhub outlet (they tend to run out of stock at the weekend). You will need to show your passport during registration.
  • The SIM card goes into the Huawey (I use the E585) and connects to Starhub network immediately.
  • However it’s not operational until you activate the credit. Because you registered using your passport, the only way you can activate the credit is by talking directly to customer care on 1633.
  • To identify yourself you will need to quote the 8-digit number that appears on the package of the pre-paid SIM that you bought.
  • The lady on the phone will ask how many days you want to activate using your available credit. After she activates it, you will be able to connect to the internet immediately.

To top up your account,

  • buy a SGD18 Happy Top-up card from Starhub or Seven-Eleven. 
  • call 1633 to credit your account and activate more days.
  • You will need to quote your 8-digit SIM identifier as well as the codes that appear on the Happy Top-up scratch card.

I used Starhub with the Huawey without any problem during my stay in Singapore and could connect the IPhone, IPad and Vaio to it.

Saturday, 19 March 2011

Self-Defense Techniques

It took me some time before I got to a stable and convenient backup system. I think I got there now. It’s hassle-free, complete and entirely automatic. This is the setup I use now for backup and synchronisation between all my portable gizmos.

1st level

Dropbox to synchronise my essential documents between

  • home PC,
  • 2 VAIO laptops,
  • IPhone
  • IPad.

I have less than 2 GB of essential documents so the free version of Dropbox is fine. I find the synchronisation very fast and more reliable than using the Windows offline files feature or Live Sync. This acts as a first form of backup since all files are saved on the Dropbox server by default. Dropbox files are always available offline under Windows. On the IPad/IPhone versions of Dropbox you must manually tick the files to make them available offline. By essential files I mean

  • technical Books
  • travel documents, flight tickets, travel insurance policy, conference tickets….
  • Visual Studio projects
  • OneNote files

2nd level

Daily incremental backup on an external hard drive of all documents on my D drive using the backup tool that comes with Windows 7. The drive is a 1TB Western Digital. This protects absolutely everything in case my main drives fail, which is a very likely occurrence.

3rd level

Off-site backup with Mozy, just in case my flat burns or I get burgled. This is an industrial-scale backup: documents, video, raw sound files, VM files, everything gets saved. I currently have 130GB saved on Mozy. At the time I bought the subscription, the backup size was unlimited. No matter how big a video is it will save it, it’s just a matter of time. It took me about one week to finish the initial backup. After that it does very quick daily automatic incremental backups.

I’m happy about this system so far, it’s entirely automatic and very exhaustive.

Saturday, 26 February 2011

Books I currently flip through #9

 

41vMVJPzNBL._SL160_

  • Introducing Silverlight 4 (Ashish Ghoda)

51IvXoq4JtL._SL160_

  • Programming Windows Phone 7 (Charles Petzold) Free e-book that now works on the IPad (the version from a few months ago had trouble being displayed on Ipad/Iphone)

Monday, 24 January 2011

Preparing a trip to South East Asia…

I’m gathering some info about the countries around Singapore, with a mix of web links, books and Kindle books.

General

Lonely Planet: South East Asia on a Shoestring

41up4BBrZUL._SL160_

southeastasia.org

Singapore

Singapore Journey Planner (SMRT)

Taiwan

Lonely Planet: Taiwan, ebook Edition

31HuVLbb7VL._SL160_

Taipei Insight City Guide

51CMb6F2X1L._SL160_

Malaysia

Timeout Kuala Lumpur

Diving Spots

Sipadan: Dive the World.com, sipadanvacations.com

Monday, 10 January 2011

How to re-build your PC in less than 2 hours

 

Pre-requisites:

  • Your data is on D:, the OS on C:
  • Your backup is done (nothing to do because you have an automatic full C+D-drive incremental back-up scheduled to run every day )
  • Your CD case with all legally acquired original CDs for software and drivers
  • Access to the spreadsheet where you carefully store all serials for the above.
Go:
  1. Boot from DVD
  2. Format C:.
  3. Click Next, OK, next, Ok, I agree, OK, Next, London GMT
  4. Install your favourite software. For me it is:
    1. Microsoft Security Essentials
    2. Slysoft Virtual Clone Drive
    3. Office
    4. Chrome, Firefox
    5. Set-up backup with Mozy
  5. Check the time: if it took you more than 2 hours, start all over again.

Friday, 31 December 2010

The Mystery of Safari To Go: why is it so bad?

A lot of applications make the IPad shine: they’re fast, responsive, elegant and take full advantage of the touch screen: Flipboard, Ocado, Twitter and most magazines (Wired, Economist, New York Times, …). Swiping is smooth, the whole screen is used.

And then you have things like BBC IPlayer, Amazon Touch Shopping or Safari To Go that in terms of user interface are plain rubbish.

Take Safari To Go: I was expecting to be able to easily flick through my collection of Safari books stored offline, it was the reason why I bought the IPad in the first place. Well it turns out you can’t even swipe the pages!!! You have to press left/right arrow buttons to navigate. It’s full of strange rounded dialogs that waste space. It’s very buggy. The table of contents appears in an annoying modal dialog right in the middle of the screen, the table hierarchy is flatten and slow to scroll down… I actually find the web version of Safari Online Books to be much more usable than the IPad app, even if the web version does not support offline storage.

Flat modal table of content that's slow to scrollWTF???

Amazon Touch Shopping is not as buggy but you will find similar clunky rounded dialogs, wasted space, slow scrolling plus some very annoying sounds that acknowledge every user action.

Although it’s fantastic to be able to watch BBC programs on the IPad for the price of a TV license, the BBC IPlayer app suffers from the same sort of web-like sluggishness.

What’s frustrating is that we’re not talking about cheap farting apps here: Safari Books Online, BBC IPlayer and Amazon are all extremely useful platforms supported by companies that have a habit of being innovative. I guess it’s just poor technological choices. I don’t know how they’re designed but I suspect that all 3 apps are actually web browsers running javascript… At least that’s what they feel like.

Update: (13/02/2011)

  • I read that OReilly removed Safari To Go from the app store on 24/11/2011, 3 weeks after it introduced it. They’re currently working on a new version (yeah!).
  • There is now a proper BBC IPlayer (released 10/02/2011) designed for the IPad from the ground up. It’s much much much nicer than the previous one.

Wednesday, 3 November 2010

Friday, 29 October 2010

Watching PDC10…

PDC10 Player

I’m  impressed with the live streaming video system that Microsoft set-up for the PDC.

You can watch live or past sessions. I’m watching the keynote right now that took place just a few hours ago.

The player lets you switch between slide view and stage view.

I wish they did that for the previous TechEd events… Too bad the Ipad doesn’t do Silverlight.

Update: when the US sleeps (now 07:54 BST), quality switches to HD, see below:

HD

Monday, 25 October 2010

Notes from DDD8a

Microsoft Campus in Reading

The DeveloperDeveloperDeveloper event at the Microsoft offices in Reading was split in two tracks of simultaneous sessions.

Notes from some of the sessions:

It’s Time to Look at Entity Framework

Speaker: Julie Lerman (twitter @julielerman) thedatafarm.com

The Entity Framework was initially designed to reverse engineer existing databases but you can now also create them from scratch.

The designer generates a DDL. It doesn’t actually create the DB, it creates a script. Then you give the script to a DBA (Not sure how you specify paths for database and log files ?).

Support for POCO classes: your classes don’t have to inherit from Entity Framework classes, you can keep your model totally separate from EF and still work with the designer. The way you do this is through T4 templates, some of them you can download from Visual Studio Gallery.

If you tweak the T4 template you can totally abstract the EF layer (ObjectSet, etc…). In other words your code can interact with EF only through interfaces, which makes unit-testing possible.

TODO:

  • check out T4, CodeFirst

Packaging in the .NET World

Speaker: Seb Lambla (twitter @serialseb)

Seb demoed OpenWrap www.openwrap.org (the site is going live live in a few days), a packaging tool that you use to inject dependencies into your build. The dependencies must be available as “wraps” for this to be possible. You inject the dependencies with a simple command-line tool.  

The openwrap commands can also be used from within an msbuild file.

There is another open source tool called Nupack (maintained by Microsoft) released on codeplex.

TODO:

  • Check out Scott Hanselman’s blog about Nupack

Is NoSQL the Future of Data Storage?

Speaker: Gary Short (twitter @garyshort)

  • Term introduced by a programmer from LastFM.
  • NoSQL
    • often does not implement ACID
    • avoids joins
    • no fixed schema
    • scales horizontally (adding more machines)
  • Types of NoSQL DBs
    • document Store
    • graph storage: nodes and edges
    • key/value stores: on disk/on RAM
    • “eventually consistent”
    • object DBs. You provide your own indexing rules.
  • Good for:
    • geographic regions, large quantities of data, game server sharding (what’s sharding?)
    • often written, rarely read > Key/Value
    • binary data
  • Example: Twitter
    • they tried RDB > didn’t scale.
    • built FlockDB
      • not optimized for transversal, because not needed.
      • optimized for adjacency lists: graph stored as set of edges
      • idempotency: useful for computing set unions and intersections.
    • Lessons learned: use aggressive timeouts

TODO:

  • check story of Twitter (DB angle)

Modern C#: this is not your grand-daddy’s language

Speaker: Jon Skeet and his pony. (twitter: @jonskeet)

Inspiring talk about the evolution of the language features of C#.

Jon illustrated how powerful C# has got by writing a MaxBy() implementation in various versions of C#. MaxBy() should return the element of a collection containing the maximum value of a specified field. It should work with any field and any collection.

He wrote the solution in C# 4 use generics, lambdas, method extensions and inferred types.

In C# 1.0, he started with a simple for loop: this lead to code specific to the class being compared. To make the code a bit more generic he used a delegate and some downcasting from System.Object to the type compared: it worked but was somewhat verbose and not as type safe as the C# 4 version.

Jon’s quotes:

“Knowing how things work under the hood is important. However you need to be able to shift gears so that you think at a higher level when you need to”

“We need to be jolted out of the idea of what a language should look like.”

“You can express yourself more clearly without having to write things you don’t need. What needs to be expressed is expressed only once.”

“Learning F# helps you understand the new features of C# 4.”

Things you should know about SQL as a developer

Speaker: Simon Sabin (twitter: @simon_sabin)

  • Do not truncate the transaction log > you loose point-in-time recovery
  • Re-indexing
    • You may just need to update the statistics.
  • Shrinking
    • usually bad, files grow for a reason
    • shrinking makes sense after a big import job only
  • Clustered indexes on dates
    • make them small and unique
  • Types of joins
    • Loop: for small datasets
    • Hash: large datasets
    • Merge: requires sets to be ordered
  • user-defined functions
    • bad performance!
      • interpreted
      • can’t use parallelism
    • demoed a padding operation done with UDF vs one done with a CLR function. The CLR one significantly faster.
    • Prefer CLR functions over UDF.

TODO:

  • Look into taking snapshots vs restoring from backup.

 

More blog posts about the event:

Danny-T.co.uk

The Ninja Ferret

Slides:

Chris Hardy’s WP7 talk