by Nik Kalyani
Saturday, August 30, 2008 7:54:35 AM (Pacific Standard Time, UTC-08:00)
T  he only thing missing from my BlackBerry Curve 8310 (service with AT&T) has been video. It did not make much sense since there is a 2MP camera on the device. Posts on the CrackBerry forums pointed to availability of this feature in v4.3.1 of the device OS (now called v4.5.0). Here is a list of all the new features in BB OS 4.5. Since AT&T takes an ungodly amount of time to release new software through its site, and I wanted the video feature, I decided to find the software and do the upgrade without AT&T's blessing. My upgrade went smoothly and my BlackBerry now has some shiny new features. I have documented the procedure here. It worked for me but may not work for you. In fact the likelihood is high that you will have a BlackBrick on your hands when you are done. Proceed with caution. Think carefully before doing this. Did I mention you could brick your BlackBerry? You have been warned.IMPORTANT NOTE: If you are reading this after Sept. 2008, there is a good chance that the software is now supported and available with U.S. carriers. Check your carrier's site and if they have the update, ignore these instructions.
The upgrade process itself is very simple: 1) Make a complete backup of your BlackBerry with the existing version of your BlackBerry Desktop software.
2) Download and install the latest version of the BlackBerry Desktop which is Version 4.6
Download the software here: BlackBerry Desktop v4.6 (from BlackBerry site)Quit the BlackBerry desktop software if it is running on your PC and untether your phone if it is connected to your PC. Install the software. 3) Download and install the BlackBerry OS v4.5 to your PC
Download the software here: BlackBerry OS v4.5 (from Vodafone Germany site)Note the difference -- step 2 is to install the "Desktop" software to the PC. This step is to install the "OS" software to your PC. When you perform this install, you will not find any new app icons. REBOOT the PC. 4) Remove Vendor.xml
If the file C:\Program Files\Common Files\Research In Motion\AppLoader\Vendor.xml is present, move it to some other folder. I did not perform this step because I got distracted in the middle of the upgrade but there seem to be no harmful consequences. Your mileage may vary. 5) Perform the upgrade
Turn off the Radio and Bluetooth on your BlackBerry Curve 8310. Tether the phone to the PC with USB and start the BlackBerry Desktop software. The software will recognize that the phone needs to be upgraded and will start the process. Some things to remember: - Choose Advanced... so you can customize what gets installed. I de-selected all the languages and added "Documents to Go" - The process can take from 30-60 mins and there is no progress indicator - When the upgrade is done you will have to go through the Setup Wizard, but all your settings, apps and data will be preserved. Overall, I am very happy with this upgrade. I now have video (albeit at a maximum resolution of 240 x 180), a much snappier photo app with geo-tagging and enhanced browser navigation. I am sure there are other things which I will discover as I use the phone and I'll update if there's anything interesting.
by Nik Kalyani
Friday, August 22, 2008 5:09:46 PM (Pacific Standard Time, UTC-08:00)
Joe Brinkman posted a technique to pass parameters to Javascript script files. The approach is simple -- append a standard querystring to the script URL and obtain the parameters by locating the script element using the ID attribute, and parsing the key-value pairs from the "src" attribute. A sample usage is like this: <script type="text/javascript" id="MyScript" src="http://www.foo.com/myscript.js?obj1=ABC&obj2=XYZ"></script>
This is a great approach and works well for most scenarios, except in those situations where HTML 4.01 Strict markup is desired. In this case there are two problems that would cause validation to fail: 1) The HTML "script" element does not support an ID attribute. Yes, this is true. Verify it for yourself here. 2) The ampersand ("&") character is a predefined entity and must be expressed as an entity reference "&" So, is there a simple way to work around this issue. Of course, otherwise the title of this post would be totally false advertising. Here is the revised code snippet I propose in lieu of the one above: <script type="text/javascript" src="http://www.foo.com/myscript.js#obj1/ABC/obj2/XYZ"></script>
Let's break it down. 1) The ID attribute has been removed. Even without the ID attribute there is still a simple way to reference the script element. The trick is to take advantage of the fact that as the browser is rendering the page, it executes JS code immediately when encountered. As a result, if the code in your JS file queries the DOM, the last script element in the DOM is a self-reference (i.e. a reference to the script element that loaded the code being executed). Thus, using document.getElementsByTagName("script") and referencing the last element in the array, provides an easy way to get the current script reference. 2) The standard querystring separator "?" has been replaced by "#". This is not necessary, but something I did for semantic reasons. To overcome the "&" entity issue, I used a slash ("/") character for separating not only key-value pairs, but keys and values too. The reason for this will become evident in a bit, but since I modified the querystring to something non-standard, I felt it was important to also remove the "?" separator which is a prefix for querystring. Instead, I used a hash ("#") character which is a pointer to a document fragment and does not have any semantic value in the context of a JS script URL. (In fact the JS URL hash technique is a common way to pass data in cross-domain XMLHttp requests for this reason and also because it does not cause a page re-load.) 3) Key-Value pairs. The last change I made is to use a path-based approach to key-value pairs instead of Key=Value format. I did this because it is a common technique in RESTful URL's, is easier to read and much simpler to parse. In fact, using a single "for..." loop, it becomes a trivial task to create an associative array of all the parameters for ready reference. Here's the code wrapped into a function with a sample call: var myParams = getScriptUrlParams(); alert(myParams["obj1"]); alert(myParams["obj2"]);
function getScriptUrlParams() { var scriptTags = document.getElementsByTagName("script");
// This code is assumed to be in a file so the "src" attribute // is guaranteed to be present...no error-checking is needed var urlFrags = scriptTags[scriptTags.length-1].src.split("#");
var urlParams=[]; var urlParamRaw = []; if (urlFrags.length > 1) { urlParamRaw = urlFrags[1].split("/"); if (urlParamRaw.length >= 2) { for(var param=0;param<urlParamRaw.length;param+=2) urlParams[urlParamRaw[param]] = (urlParamRaw.length >= param + 1 ? unescape(urlParamRaw[param+1]) : null); } }
return(urlParams); } What do you think? Is this a simpler approach or is it more complicated? Are there other techniques for working around the XHTML validation issue.
by Nik Kalyani
Monday, August 18, 2008 1:51:10 PM (Pacific Standard Time, UTC-08:00)
Om Malik posted about the NSF website chronicling the birth of the Internet. What a cool site. I skimmed it briefly and found this entry for 1980s: In the mid-1980s, NSF decided the time was right to try to link its regional university networks and its supercomputer centers together. This initial effort was called NSFNET. By 1987, participation in the new NSFNET project grew so rapidly that NSF knew it had to expand the capacity of this new network. In November of that year, it awarded a grant to a consortium of IBM, MCI, and a center at the University of Michigan called Merit to create a network or networks--or internet--capable of carrying data at speeds up to 56 kilobits a second. By July 1987, this new system was up and running. The modern Internet was born.
I came to the U.S. on Sept. 3, 1987 from India to begin my Bachelor's degree at Western Michigan University. I remember logging on to the Merit network that same month from the campus computer lab. Since, at the time, everything about computers was totally new to me (other than the Sinclair ZX Spectrum+, my home computer), I had no idea until today that this was a brand new network and more importantly, the first "network of networks."
by Nik Kalyani
Sunday, August 17, 2008 5:36:18 PM (Pacific Standard Time, UTC-08:00)
I have been thinking on and off about Posterous since I first used it and decided to put my thoughts down in a post. Nischal asked the question "Would you stick to Posterous?"
My answer today is "No" for the simple reason that it's difficult to
make the commitment to use Posterous as my primary blog until custom
domains are supported. Redirects just don't cut it.
Also, the brutally honest truth is that Posterous is on borrowed time.
If the service does not start innovating rapidly, get huge user
adoption and then create a significant reason for users to stay, it
will soon become irrelevant. Its primary feature -- email to blog -- is
not enough of a differentiator because technically it is not very
difficult to implement and other blog engines will be quick to offer it
to their users (some already do).
I think Posterous should be thinking about ways in which they can
continue to stay relevant and even attractive to bloggers by doing the
exact opposite of what they are doing right now. Instead of trying to
be a blogging platform, they ought to focus on being an email
publishing utility very much like FaceBook is positioned as a social
utility. The AutoPosting
capabilities available on the service are a great way to start, but
they could be so much more. Instead of just supporting vanilla posts
with title and body and hosting the photos/media here, they should go
all out and implement email to MetaWebLog and other API's. Being able
to use email to make a complete, detailed post to WordPress, DasBlog
and other blogging engines would be great. Add template, tagging and
categorization and it starts to get really interesting. And while they are at it, they should do it for not just 10, but 100's of other services. Basically, email enable every ProgrammableWeb.com API
for which email posting makes sense and that has any kind of traction.
That would be killer and greatly increase the barriers for competition
as users don't like changing habits unless there is a very good reason.
Imagine "posterous" becoming a verb for "posting something to any web
service using email." I think this would be a bigger opportunity for
the company and allow it to become truly indispensable compared to
where it is now -- a "me too" blogging platform which re-posts to other
services. Bottom line, forget the blogging and focus on the email.
by Nik Kalyani
Wednesday, August 13, 2008 10:50:23 AM (Pacific Standard Time, UTC-08:00)
I posted a comment on Rick Strahl's post on Server Errors when updating live Web applications online about a technique to update assemblies of live apps. I use the following approach: 1) I only keep the
assemblies unlikely to change in bin (i.e. components, third-party libs
etc.). I put my app's assemblies into a sub-folder of bin and name the
folder according to the date (for example: bin\20080801) 2) My web.config has the following: <runtime> <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> <probing privatePath="bin;bin\20080801;" /> </assemblyBinding> </runtime> When
I need to update assemblies, I just upload them into a new sub-folder
in bin, again with a name corresponding to the current date
(bin\20080812). After the upload is complete, I upload web.config with
a change to the sub-folder name. The app re-starts and picks up the new
assemblies and forgets about the old sub-folder assemblies which I can
leave or delete. Seems to work and has the added benefit of speeding up the app start since the sub-folder assemblies are ignored until needed.
by Nik Kalyani
Tuesday, August 12, 2008 5:59:17 PM (Pacific Standard Time, UTC-08:00)
Last month, a few days before my birthday, I decided that I needed to acquire some new skills and do some new things, while broadening my knowledge of things I already know (i.e. software development). More importantly, I wanted to not spend as much time in front of the computer. Instead of posting about it and then hoping to follow through, I decided to do the opposite. I started the process and am now happy to report that I have made good progress in five areas:
1) Building Stuff: I love working with tools and making things. My first project was to build a swing set for my daughters. I got lumber from Lowe's and built one from scratch. My kids love it and it's great not having to drive down to the playground every day.
My second project is to build earth boxes, five to be precise. Savi wants to grow vegetables and the earth boxes are the perfect solution. It's labor intensive to build one, but not very difficult. I have completed one and am working on the rest.
2) Baking: I love bread but rarely find bread I like at the store. Solution -- bake my own. Savi got me a bread-maker for my birthday and I love it. So far I have baked a loaf of plain, white bread and yesterday, I baked a walnut-raisin loaf. I am not much of a cook and making eggs is the extent of my culinary expertise. But after baking this bread, I am beginning to see why so many people love to cook. It is quite relaxing and to have an end product that family and friends can enjoy is quite rewarding.
3) Mixing: As I have mentioned on this blog before, I am an avid fan of A/V. Until about 2003, one of my favorite things to do was to V.J. parties and weddings for friends. I never did it for money as then it would become work and stop being fun. After moving to DC in 2003, I never did any gigs until last week. Friday (8/8/08), my friends Todd and Diana got married in Napa. My daughter Gia was the flower girl and I had the honor of providing the entertainment for the wedding. Since I did not want to abandon the wife and kids during the reception, I did something novel (for me) -- I created a video mix on DVD for the entire evening's entertainment. Everything from the bride/groom dances to the various dance sets were all on DVD and all I had to do was press Play. I used an 80's theme and mixed lots of music videos from the decade along with an intro scene from "Back to the Future," Todd's favorite movie. I enjoyed making the mix so much, that I am now motivated to create more DVD mixes of my kids photos/videos for family back in India.
4) Software: This item is more about broadening my skills beyond ASP.Net and DotNetNuke. I have been an avid fan of Google AppEngine since the day it went live. Since I had no prior knowledge of Python or Django, I had to come up to speed fast. I attended a few meet-ups at Google and picked-up a copy of Python Power. Between the book and the meet-ups and just tinkering with code, I now have progressed far enough to create fairly advanced apps on AppEngine in Python. I plan on continuing to learn more advanced concepts and focus on developing a single application that will also be the basis of my AppEngine presentation at the DotNetNuke OpenForce / SDN Conference in Amsterdam this October. More about this application in a future post.
5) Teaching: I love to teach kids. It doesn't matter what the subject matter is, it's just fun to be able to share and help them learn. This summer, I have undertaken to teach my 12-year-old nephew how to program, continuing indefinitely. After researching the topic, I settled on Phrogram as the language to use for instruction. So far, I am quite impressed with everything about the IDE and the language. I setup a virtual machine, put it on a DVD and mailed it to him (he is not allowed to use the Internet other than for class assignments). He was able to install VPC, get the virtual machine up and running and write his first Phrogram. I will have some detailed blog posts about my experience on this in the near future also.
Yes, it's true that three of the five things require time in front of the computer. But they still represent a shift and have helped me achieve my goals.
|