Archive for the ‘Misc’ Category.

Making SQLite Work

So I’ve been playing around with creating an offline application. Because I want dynamic data, I needed to figure out how to use a SQLite database. Honestly, I feel quite foolish because I was sure that I was doing everything correctly, following the tutorial (nearly) perfectly (sans “Girls” application, I enjoy being married!).

Despite working at if for several hours nothing I was doing was working. Then I caught it—the typo. Inside of my insert statement I had miss-typed the name of one of the table fields.

No errors. No warnings. No worky.

I guess this is my lesson that with a SQLite database there is no forgiveness. You do it right or you don’t do it. Apparently I just needed a reminder that I’m human.

Post Ratings: (No Ratings Yet)

jQuery Selector Test

The other day I was talking to one of my coworkers who asked me an interesting question. He wanted to know if there was any significant improvement, when using jQuery, to assigning a jQuery selector to a variable when you repeatedly are referencing the same object. Is there much overhead when jQuery instantiates the variable?

Neither he nor I doubted that there was some overhead, but we both wanted to have a more clear picture so I devised the following test:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
<script type="text/javascript">
	var tests = 100000;
	$(document).ready(function(){
		var date1a = new Date();
		edit1();
		var date1b = new Date();
		var date2a = new Date();
		edit2();
		var date2b = new Date();
		$('#one').html(date1b-date1a + " ms");
		$('#two').html(date2b-date2a + " ms");
	});
	function edit1(){
		for(var i = 0; i < tests; i++){
			$('#one').html(i);
		}
	}
	function edit2(){
		var two = $('#two');
		for(var i = 0; i < tests; i++){
			two.html(i);
		}
	}
</script>


And:

1
2
3
<div id="main">This is a test page.</div>
<div id="one">Test 1</div>
<div id="two">Test 2</div>

The results were pretty consistent as follows:

     This is a test page.
     3007 ms
     2497 ms

Post Ratings: (No Ratings Yet)

Cloud Computing

I’ve recently been using a new video game service called Onlive. The service currently lets you login and and play high end 3D games that are streamed to you over the internet. The game itself is running remotely, on the company’s high-end servers. It is only the video of the game that is streaming down to your local computer or television. As you use your keyboard and mouse to control the game, those signals are sent back through the internet and to the server running the game. This all happens fast enough that it feels as if the game is running locally on your computer. There are many benefits to this system. You don’t have to have very powerful hardware to play high-end games. You can login and play games anywhere you are, even on low powered devices like the iPad. All you need is a decently fast internet connection…

The thing that interests me most about this service is not the games. Games was the hardest problem to solve because they require low latency to make them fun to play. But what if you could run any software, not just games? I often deal with 3D animation software. Most of the time I’m limited to using my one (expensive) desktop machine when I want to do 3D rendering.  But with a service like Onlive, you could access high-end servers for this type of work, and access them from any device – anywhere. It’s just the video interface of what you’re doing being streamed to you, so again, all the high-powered computing is being done remotely.

With this type of technology, personal computer ownership becomes less important. We still need devices to access the cloud service, but these devices need not be so powerful. In fact, all the hardware can be put to use in rendering more interesting and useful interfaces, instead of being used up processing software.

And then there is the obvious benefits of the cloud. However, with a system like this, you could have your entire “computer” in the cloud. Presently we tend to trust only certain things to the cloud… Our email, our backups, picture transfers…

With a system like Onlive, you could “rent” a “computer” that has near infinite processing and storage capabilities, that is always on, and is always accessible from everywhere. Currently we tend to think of the cloud in terms of a place to “transfer” our content from device to device. Well if you’re streaming the whole computer interface and experience, there is no longer the need to transfer files to and from  your local devices. You are always just accessing your one personal super computer cloud from whichever device you happen to be on. There is no need to sync because all your files are always in just the one location.

So then you hear the usual complaints… “But then I don’t have ownership of my data!” or “what if the internet is down” or “I don’t want a company to have control of my data, what if they go out of business.”

Just as we currently use online services to backup files of site, you could back up your files locally with a local backup in your home. Problem solved.

I for one welcome the day when I can have limitless computing power and be rid the headache that is file management  today.

Post Ratings: (No Ratings Yet)

Smartphones and What Consumers Want

Okay, I’ve talked at length about what I’d like to see in my next computer—I don’t want another laptop I want a tablet that will replace my laptop—but what about other tech gadgets?

Let me just get this out in the open: Smart phone users aren’t getting what they want.

There are a lot of cool devices out there—the iPhone, a dozen Android phones, RIM devices, WebOS phones, whatever else—and none of them offer what everyone wants. The iPhone is cool, but it’s also so limiting—like moving into a high-class prison. Of course most of the inmates want to be there, but still, where is the freedom? Android is more open, but not as good as iOS. Every phone has some virtues and some vices. With that in mind, I’m going to make a list of things the perfect phone will have.

Open

  • Any developer can develop any app for it. This isn’t to say that an app store must allow every app, but a consumer may download it elsewhere if he/she wishes.
  • Program and interface interchangeability. I can download Google Voice for use on my iPhone. I can change between the Sense UI or the Vanilla version anytime I want. Those kinds of things. I’m not saying that HTC shouldn’t offer the Sense UI, but I’d like it if I got downloads faster and weren’t tied to you UI update.
  • Sprint, AT&T, Verizion, GSM, CDMA, let me have a choice! I hate it when the perfect phone comes on the wrong network!

Price

  • Yeah I want a WiFi hotspot!!! What? It’s $30 a month extra? … never mind. Don’t gouge.

Choice

  • I read an article a while ago that compared the HTC Evo with Apple’s iPhone. The iPhone won one of the writers points because it came with in 16 and 32 GB, even though it didn’t have a card reader. The Evo had a card reader but only one memory level. The author said that there was more choices with the iPhone, wrong. You can get an SD card in 16, 32, 64GB, however big you want it, which really has more choice?

Simplicity

  • Let me pinch to zoom or swipe to navigate pages, make things easy for me.

You’ll notice that hardware and software specs are not on this list. Yes, the specifications are important, but when it comes to specs it seems that phone makers are trying, not so with these other points. No phone on the market has all of these things. The iPhone probably does the best job, but it’s still lacking. I realize that the reason that most of these problems exist is because phone makers and carriers are trying to make money, but it still makes for dissatisfied customers.

What are your thoughts? Am I too hard on the phone industry? What do you think is missing from your phone?

Post Ratings: (No Ratings Yet)

Make Your Cooperation More Productive

I watched this this morning and I immediately recognized myself. Could we be more productive if we followed these steps?

Post Ratings: (No Ratings Yet)