I am a client of the optimus tag service (for English users, it’s a phone plan that includes free calls for any other phone using the same network plan).

Recently, I discovered they have a softphone like system called Webphone (Windows only), that allows you to place and receive calls, SMS, MMS, and other stuff, right from your computer.

My first thought was “this must use some kind of SIP service”. Since the SIP settings are not posted anywhere on the internet, and I don’t want to use Windows to use their client, I decided to dig deeper and try to find the SIP configurations so it can work on any regular softphone.

Although it was easier than I thought (Wireshark, I love you), there is one serious limitation that I couldn’t solve without hacking some open source code. Anyway here’s the main settings:

Optimus Tag SIP settings (to use with a SIP softphone)

  • server address: sip.optimus.pt
  • username: 351 your number@sip.optimus.pt
  • password: your webphone password
  • SIP proxy: asbg.sip.optimus.pt
  • User Agent: Optimus-SoftPhone/7.0.1.4124

Now, the last item is the worst part. If you don’t specify a User-Agent that starts with Optimus-SoftPhone, you’ll receive a “403 Forbidden User Agent” message. I tried to find a SIP softphone that allowed me to change the UserAgent but didn’t found one (I didn’t try hard).

So I decided to take the Twinkle open source SIP client, changed the hard coded User Agent, and got surprised when it worked flawlessly from the first time! I tried placing and receiving calls and it worked perfectly :)

If you’re interested on the trivial patch (I used Twinkle version 1.4.2) you can find it here.

If you know a SIP client for OS X or Linux that allows me to change the User Agent, don’t hesitate to comment bellow!

quick post to let you know my latest two mini-projects on github:

Ruby library to whit.me service API

whit.me is a wonderful service to shorten URLs. They have a public API, and I wrote this library that allows you to use the service in the middle of any Ruby script.

The project is available here. It is compatible with Ruby 1.9 and JRuby, and contains a full RSpec test suite.

newzbin XMPP search agent

After spending some time learning XMPP, I decided to try it and build something useful. So I hacked a simple search agent for the newzbin website to be used by me and my friends. It is poorly written, but it works.

Maybe you can learn something from the simple example. In case you’re interested, the code is available again on github. It uses the XMPP4R gem and CouchDB (overkill, I know).

Feel free to comment on any of the code and send me suggestions on how to improve it.

Quick note about the latest 24 episode (7×14). When FBI needed to decrypt an email that was sent using the Blowfish cipher, a “level 6 analyst” walks into a computer and says:

“The designer of this algorithm built a backdoor into the code. Decryption is a piece of cake if you know the override codes.”

Five seconds later, the file is decrypted :)

I guess Bruce Scheier, the author of the original cipher, should not be happy to hear this on a TV show :P

Next Friday, I’ll be giving a mini workshop about two technologies that I love: Sinatra and Capistrano.

The event is free but there are a (very) limited number of places.

You can find all the details (location, how to reserve a seat, etc) on this blog post.

The talk will be given in Portuguese and some of the 7syntax’s crew will be there.

Thank you Alex for this opportunity!

It finally has arrived! My Android Dev Phone 1 is here!

Android Dev Phone 1 unpacking

Let’s make this first review quick cause I’m too tired of spending countless hours trying (and hacking!) the device :P

Pros

  • The SO. Maybe I’m biased (cause it runs Linux), but this is the fastest mobile SO I ever touched. It never flicked once and I always get immediate responsiveness from the buttons I press.
  • The integration with Google. After the initial setup wizard where I introduced my Google account credentials, a little “sync” icon appeared on the top bar. Thirty seconds later, and all my Google contacts, GMail mails and Google Calendar were synched with the phone (over my 3G connection). W00t? Tried to edit a contact on the desktop’s browser and saw that it immediately replicated the changes on the device. W00t?
  • It runs a more up-to-date Linux version than most of my Debian machines (2.6.25)
  • Very fast GPS. It is definitely the fastest GPS device I’ve tried, getting a fix mere seconds after an application asks for the precise location
  • Good camera. It even does auto-focus (Hugo: it’s real auto focus :P), and applications can register themselves on the process of sharing a photo you just taken.
  • App Market: instantly browsed through dozens of free applications. Discovered an eBay app that allows me to capture a bar code from an object, and find it immediately on eBay. Got shocked when I pointed the camera to the first bar code in front of me, and it actually worked. W00t?

Cons

  • Bulky device. It’s clearly a bulky one. I can almost bet it is twice or three times as thick as an iPhone 3G. And since it has moving parts (the sliding display/keyboard), you constantly feel that is isn’t as solid as other devices.
  • Poor battery. What can I say? I really didn’t expect a high end device like this, with 3G, WiFi and bluetooth on to last as long as my Sony-Ericsson does. After this initial heavy-experiment usage, I predict that the phone will last a full day without recharging.
  • Poor bluetooth capabilities. I was kinda shocked when I realized I couldn’t send a picture through bluetooth. There isn’t any kind of OBEX push or pull on this device. Maybe a future firmware version? On the other hand, with just 2 clicks I shared the photo over GMail and 3G.
  • No video. The camera does not support video shooting. At least not with the default camera application.
  • No tasks? Maybe I’m just blind, but I didn’t find any way to create or sync tasks. Guess I’ll have to stick with the Calendar…
  • Not multi-touch enabled nor 3.5mm stereo jack. Sometimes I just hate you Apple…

Hacking

Being a totally unlocked phone, it was very easy to start hacking it. I installed the latest JF firmware (stable Google code + extra hacker tools) and gain a terminal application with easy root access.

After doing some reading it was time to Debianize it! :-) Installed the debian image on the SD card, and after a few commands on the terminal, I was running a Debian Lenny system with perl, vim, openssh, wget, aircrack-ng (!!!!) and the full GCC stack! It made me happy :-)

After playing around with Eclipse and the Google plugin, I realized that it’s very easy to debug the phone, because all Java processes appear on the IDE and can be inspected with 1 or 2 clicks, including threads and the heap! I guess that makes on-device debugging a piece of cake with Android.

Final thoughts

Overall I’m very impressed with the device. I’m hoping to have a little more time to explore the development capabilities of the platform, including the APIs and the community. In the mean time, kudos for Google for the Android’s effort.

( and without disclosing your name, thank you for helping me getting the device to Portugal :) )

About

photo of Ruben Fonseca

My name is Ruben Fonseca. I'm a Computer Science and Systems Engineer from Portugal that loves FLOSS.

I'm currently taking some time off to myself, but feel free to contact me anytime at or via LinkedIn:

View Ruben Fonseca's profile on LinkedIn

Feeds

handivi

Music