My article about missing HTC TyTN II graphics drivers published on Moj Mikro

A while ago I wrote an article about HTC TyTN II and its missing graphics drivers for Slovene computer magazine Moj Mikro. Now the article has been published on-line, so check it out if you are interested in why TyTN II's graphics performance is dismal, or how HTC is treating their loyal customers. The article is in Slovene.

Read the article here.

Update since article has been written: new ROM has been delivered with Windows Mobile 6.1 and no proper graphics drivers.

Building your own Media Center

Since I have IPTV I am really annoyed by not having an option to save programs, like in old video recorder and cable network days. True, one can still save using video recorder, but the problem is that video recorder can't change channels on STB (set top box) and thus you are limited to a single channel. Pretty much useless. The other option is using personal recorder, a feature provided by my IPTV provider. But again, the drawbacks are enormous: there is a monthly fee, you are limited to 6 hrs of total saved content. Even worse limitation is that your content can be stored for maximum of two days (forget vacation, or drive back to home every two days to watch the saved content). But there's another drawback, in fact mother of all drawbacks: only a few channels and not all shows on those channels are allowed to be saved. Total useless crap.

Hence the idea of my own media center. After all I live by using my development skills, why not use them for this one. So, RH Media Center project was born.

The main objectives:

  1. ability to save from IPTV
  2. ability to schedule saving
  3. ability to playback saved content
  4. ability to control RH Media Center by remote

Hardware requirements

  1. A computer (server which is always on preferably) that will be used to save content
  2. A computer to playback the saved content (possibly attached to TV). In my case this is my laptop.
  3. A PocketPC device (remote control)

1. and 2. can be the same computer, whatever is feasible for you.


VLC media player ActiveX control is at the core of RH Media Center. VLC media player is a free, open source, cross platform application that plays just everything out there, including SIOL IPTV streams. And luckily for me, they have an ActiveX control, too. In fact I've build my application around this ActiveX control using Windows Forms UI. Here is how it looks:


Video (both IPTV stream and saved content playback) is rendered and saved by VLC. You can also see a bunch of controls on the top and the channel listing on the right. There is also saved content listing in the docking panel next to channel listing.


Test saved contents listing

Note that UI is pretty rough at this time as prettiness wasn't one of the objectives. Anyway the objectives 1. and 3. are done now.


Once the core functionality is done (see above) the scheduling is pretty easy. The application should parse command line arguments and start saving given channel for given time. The content file name should be made of given argument (i.e. name of the show) plus date. Here is an example:

RhMediaCenter.exe rec "Channel" ShowName 120

This means that content from "Channel" will be recorded for 120 minutes to a file name

ps is MPEG-PS extension. You'll note that I didn't specify when should the recording start aka scheduling. This step is done using Task Scheduler - no wonders there, just run that command line at any time you specify and that's it. A bit rough to configure but it works just fine (in future I'll enhance the configuration step).

Remote control

Every decent media center has remote control capabilities. How can you skip those commercials otherwise? I've figured out, that I have a bunch of PocketPCs lying around and collecting dust. At the same time I have a Wi-Fi network at home. Get the idea? Yes, I'll use PocketPC over Wi-Fi to control my media center. The technology of choice is WCF which is partially supported with .NET Compact Framework 3.5. BasicHttpBinding, here we go.

So I've build a simple Windows Mobile 6 application which looks like this:


It allows to connect to preferred RH Media Center through providing a proper IP, it can get a list of saved content and it allows you to play any of them. It features also a Pause button and move forward (left group of buttons) or backward (right group of buttons) for a given time span. And after creating a hole in Windows Firewall on computer where RH Media Control runs it just works.

The only problem is how to build WCF service client code for .net compact framework. This feature is provided by Power Toys for .NET Compact Framework 3.5's NetCFSvcUtil utility that does the similar job as Service Metadata Utility (SvcUtil.exe) for .net framework.


I solved the biggest IPTV issue - saving programs and playback of saved content using a remote control. By using .net 3.5/Windows Forms/WCF/Compact framework and VLC ActiveX control it took me only around 10 hours of total time over the weekend (most of the time I used for plumbing , user interface and figuring out VLC ActiveX oddities). If you wonder why I'd used Windows Forms instead of WPF: because I was experimenting at the beginning (and the project is still an experiment) and I have no 3rd party controls for WPF yet - so it was easier with Windows Forms. In future I'll be definitely using WPF.

I have to say that .net/VLC made it so easy to build this pet project - the ease of putting pieces together is amazing.

BTW, Is anybody interested in binaries? (I am not saying I'll provide them nor that I won't provide them :-))

My first article published in Moj Mikro, Slovene computer monthly magazine

The article is all about HTC's dirty secrets behind its line of PocketPC's based on Qualcomm's MSM7x00 CPU/chipset and is my first article being published in such a large scale magazine or in any magazine I guess. Moj Mikro also brings my memories back; I remember when I was young and I was eagerly waiting for the magazine each month. At the time Moj Mikro was more or less the only Slovene computer magazine and one of the few Yugoslav ones (Slovenia was part of Yugoslavia then and there were a couple of Serb computer magazines, too).

Anyway, the magazine comes out on the first Tuesday in March and I hope you'll enjoy my article titled "Umazane podrobnosti HTC mobilnih naprav – dejstva, ki jih je HTC zamolčal".

Feedback appreciated of course.

HTC is giving a finger to its customers

I already reported about presumably lack of drivers in newer HTC devices. At the time it was all speculation. Now we have an official response from HTC. They are basically saying:

Yes, we advertise the devices as great, the devices have actually great hardware but we don't include proper drivers because it would take time and effort from us. Thus the devices perform worse than years older devices but it is still good for you. We won't provide drivers for actual devices, no, that would take time and effort from us. Instead, since you demand it, we will sell you future devices with such drivers, if you really want it. Maybe.

Now, let's play a couple of analogies. Let's say you bought 64 of the newest top notch graphic card, that features a zillion of pipelines and 64 way SLI. You plug them into your mobo that supports 64 SLI graphic cards and try playing Duke Nuke'm 4 only to find out that graphics perform same as with a single 4 year old graphic card. The reason being drives not included. Nor they are available at all. What? You did assume drivers were there?

Let's see a car analogy. You buy a great car, that includes a turbo charger. Yet, the acceleration and top speed are low. The reason being turbo charger is not working because is not connected. And you can't connect it since nobody is selling connection cables. What? You did assume turbo charger will work?

Now, let me state this clear, as there is some misunderstanding in the air. It is not just about video playback speed and quality. The entire UI is slow. Try running Windows in safe mode with VGA mode enabled and you'll get the point. This lousy UI performance casts a very dark shadow to [MS] Windows Mobile, too - many says that the slowness is because Windows Mobile sucks. Perhaps, but the core reason is the lack of hardware acceleration. No wonder that iPhone had such a success. In this case Apple did an integral product, not just created good hardware and throw it to the customers. No, they actually provide proper software, too. (I am still in favor of Windows Mobile devices though for other reasons, such as programmability). Looks like the Windows Mobile device manufacturers lack of common sense when comes to usability.

So, what does the biggest Windows Mobile device manufacturer do when its customers point out that it is selling an underperfoming device just because lack of proper drivers. Will they rectify the problem and provide proper drivers? Will they provide proper drivers for a small fee? No, HTC shows a proverbial finger at its loyal customers (HTC is also mentioning how much they value their customers in every press release). I only hope that this attitude will backfire on them.

The biggest mystery of this story is, why isn't HTC including these drivers by default. I mean what company wouldn't like to have best performing devices out there? I presume that there are two basic reasons:

  1. They are plain stupid (they don't see why those would be required, even now, with iPhone UI performance out there)
  2. They are cheap. Which is stupid again. Because they won't spend money on better software they'll loose additional customers. But if they did spend it would be certainly an overall profit for them.

I really can't think of other reasons.

So, it is not just about the lack of drivers, what really is sad, is the response and attitude from HTC.

But hey, let's give the finger back - I won't buy a HTC device again and I am sure that many others won't as well.

HTC devices and lack of proper drivers

If you are considering to buy a HTC device or already have one then you should definitely visit this website: IOW a range of HTC devices that have Qualcomm CPU (MSM7200 and MSM7500) lack of proper drivers. I own a TyTN II and I can confirm that UI is really crappy slow while the paper specs looks far better.

Now, why would a manufacturer decide to cripple its devices? My guess: most probably because there are no proper drivers from Qualcomm for Windows Mobile. Yet. So we all have to wait for proper drivers to emerge. And here we get a real problem. HTC is playing dumb, denying the problem and stalling which is a completely wrong attitude from such a company. Instead of saying something like: "Qualcomm screwed us with not providing the drivers, we are pushing them, will update drivers asap (i.e. month/year) and sorry for all the problems" they are playing dumb. "Luckily" the number of angry users is raising, petitions are being signed, news is spreading through online community and lawsuit is being prepared. And perhaps HTC will change the attitude, after all the public image is important and even HTC should understand this.

At the end, even though we might get proper drivers, a black spot will remain on HTC for a long, long time. The fact how they are dealing with the problems might turn away a lot of existing and potential customers. I hope that this will serve them as a lesson where to improve.

SpbBackup - a must have PocketPC application

SpbBackup is my MVP (most valuable program) for PocketPC. To be more precise, a backup application (such as SpbBackup) is a must have for anybody using a PocketPC device.

What is good about it:

  • it backups your data (entire data on PocketPC if you want to)
  • doesn't require ActiveSync to do backups (that's history anyway)
  • supports compression
  • supports encryption
  • supports scheduling
  • creates an exe file

My (very) old PocketPC/Phone was Qtek 2020 (Himalaya). Cool device by any mean, however it had a very nasty problem. Sometimes (perhaps once per two months) it would freeze and only hard reset would bring it to life again. Meaning that data in primary storage is gone. And even worse, usually the contacts (and other) data stored internally was corrupt (WTF?). The oddities won't stop here. This freeze was almost certainly to happen when I was abroad (looks like it was an intelligent bug) and left me without telephone numbers and e-mail addresses. Unless I had my laptop handy (restore through ActiveSync restore functionality, assuming I was doing backups, which was an annoying process by itself - or manually configure everything from the scratch), I was in the dark.

This was a huge problem until I found SpbBackup. This backup application is practically fire and forget sort of application (you can do backups manually, too) - just schedule it to run periodically and you are protected. But what really shines is the ability to restore PocketPC from within PocketPC - SpbBackup creates executable files. When (if) PocketPC crashes hard and looses all the data, you just run the latest executable backup and bum, you are where you was at the time of when backup was created. No hassles, no laptop required, just run the last backup.

So that makes backup applications a first application everybody should install. And SpbBackup is a great backup application.

Speeding up build times dramatically

I have a VS 2005 solution with 19 projects.In total it consumes ~600MB of disk space (entire solution folder, including binaries). Needless to say that build times are relatively high. They are high even though my workstation has 4GB of RAM, RAID 0+1 7200rpm disks, 4GB ReadyBoost USB key and Core 2 Duo 6600.

The bottleneck in my situation is definitely disk I/O - building a solution results in plenty of reads and even more writes. The logical choice would be buying WD Raptor disks that spin at 10,000rpm. It should reduce build times somehow. However, there is another solution that reduces build times dramatically. Literally.

It is called RAM disk. Instead of working with files residing on physically disk, you work with files residing in RAM.
Here are the pros:

  1. latency is almost non existing
  2. nothing beats transfer speed (RAM to RAM)
  3. build times are reduced dramatically

Nothing has only good sides, even RAM disks don't:

  1. files are not persistent. IOW if your computer experiences blue screen you can say goodbye to the files on RAM disk
    Let's dig into this problem. First, a serious workstation shouldn't experience blue screens at all. My Vista is pretty stable and I don't see blue screens. Next, you can create backup scenarios - perhaps your RAM disk driver supports  periodical backups to physical disks. So you loose just recent changes. Or you can use other backup software that does backups for you. Backup shouldn't interfere too much since building is done entirely on RAM disk. Or, if you want to be on the safe side, use RAM disk for output only. And don't forget using source safe which is always a necessity regardless of the underlying disk type.
  2. you have to allocate RAM
    You loose working RAM. This might be not that bad as it sounds. First, RAM is cheap and running on 4GB (usually only ~3.5GB or less are available due to PC architecture) machine is not uncommon. Next, RAM disks might use OS dedicated RAM AFAIK. (You know, in 32 bit Microsoft OS is RAM usually divided like 2GB to applications and 2GB to OS). And if RAM is still an issues then one might consider switching to a 64bit OS where RAM size is not limited to 4GB.

RAM disks are an risky extreme solution. On the one hand they boost I/O to the sky while on the other hand your data is volatile. However, understanding the risks and taking proper precautions this scenario is very feasible, at least for me. I am all for using RAM disk for my entire solution.

And here is my RAM disk pick: RAMDisk from QSoft (supports all flavors of Windows, both 32 and 64bit, periodical backup, excluding RAM ranges, etc.). It is my first pick and I am very careful right now. I'll see how it goes and if I don't have problems with it I will stick with it. Ah, it is also dirty cheap. And my build times are down to the ground, VS looks lightning fast.

Peculiar problem involving Windows 2003, VMWare Server, SQL Server 2005 and networking

Over the weekend I've built my new server - yes, the content you are reading right now is served from it. Perhaps more about this new server in another post. Back to the point. Host OS on the server is Windows 2003 R2 x32 and there is also a SQL Server 2005 running there. I've had x64 bit before but it is just too much trouble running it since the drivers and support situation. So, if you don't need more than 4GB of RAM then I don't see a compelling reason to go with 64 bits. Why I say "host OS"? Because I am running VMWare Server on top of it. And there are two guest OS running inside virtual machines: Another Windows 2003 that serves web content (it uses SQL Server located on host) and Windows Home Server that takes care of backups. So, after I've installed everything I fired up my web virtual machine and take a took a look at my blog - it was a no go. Virtual machine was working fine, just the Community Server wasn't running. After turning off custom exception handling I ended with a exception reporting page which I was looking for. However the error was an odd one. It stated that connection with SQL Server (running on host) has timed out. Hm. I investigated further by creating a test application that reads a table from database. Running on my workstation it read the data just fine. But when running from within web server it read just first n rows (i.e. 20) and then it timed out, always at the same row - which was really puzzling. The same symptom appeared to any SQL Server client running within guest OS. So it was obviously a problem related to VMWare Server. Yet, if I've turned off Windows Firewall on the host my application worked even on guest OS - this fact deceived me to thinking that the problem is firewall related (perhaps it was in a way) - after half an hour testing with any possible firewall configuration I gave up. Since I knew it has something to do with VMWare Server I then started searching their forums. And soon enough I've found a solution (at the bottom of the thread):

Disable TCP Offload on the host

While the solution talks about disabling TCP Offload Engine on Windows, I've disabled TCP Offload LargeSend (it sounded enough similar to me and a good candidate for my problem) and it worked like a charm. This is how it looks on my computer:


Perhaps networking now consumes 0.00000000001% more of my CPU but at least it works fine. I am not sure whether this is a bug or not, I'll contact VMWare anyway. Funny, the building and installing my server took less than troubleshooting this problem.

Playing video or audio in Vista is a booby trap

Since I switched to gigabit network some months ago I often saw a lousy network performance against other computers in my local network. It wasn't enough annoying to actually investigate. However, one day I said: enough is enough. Time for an investigation even if I have to loose a day (which I lost).

So I equipped myself with pcattcp network performance tool (found through Coding Horror blog) which is a great and simple utility - perfect for me. So I started testing and tests confirmed that local network performance is sub 100Mb/s even though I am on 1Gb/s speed. Why would that be? My first instinct was that there has to be a hardware/driver issue. After praying a bit (on the knees next to my computer, experimenting for a couple of hours with different network cards, cables and configurations) it was obvious that this wasn't it. It has to be a software problem then. So I've restarted Vista in safe mode with networking only (which I should have done from beginning) and the network performed as it supposed to perform (~60MB/s). Hua, it looked like a service or some other application that runs at startup interferes with my network.  My instinct was again active and suggested NOD antivirus that I am using (mostly with its real-time features disabled). It is a fine antivirus, but still, it is an antivirus which might create collateral damage.

So I restarted with only NOD disabled and guess what, network worked with full speed as in safe start. I said, OK, that was it, cursing antivirus software - unjustified, as you'll see soon.. And started working the usual stuff. After a while I rechecked the network performance only to, my disappointment, see that it is stuck again. Oh well. Sorry NOD, I wrongly accused you. But why did the network problem manifested only after a while? Then it struck me, perhaps not that obvious, that I am currently listening Winamp's shoutcast radio. Can Winamp have such a power to cause Vista network problems? I closed Winamp and network regained the full speed. Even though my odd experience with iTunes I didn't believe that Winamp is actually the culprit. I was right, the same happens with Windows Media Player (or any other audio/video player) - as soon as one starts listening music or watching video - bum, there goes 2/3 of your precious bandwidth.

It has to do with QOS or something like that then. Now, that I had pinpointed the problem I was able to make a phone call to [MS] local support. As soon I told the engineer words: network, audio and playing he said: "Right, it is a known 'feature' in Vista with no currently available official fix". He kindly sent me two links, one is referencing Mark Russinovich's blog post describing the background (Multimedia Class Scheduler - MMCSS being a culprit) and one link to a possible workaroundLuckily the workaround works, kudos to Courtney Malone and to  local [MS] support.

However, the bitter taste remains. Who the heck developed such a lame solution? The collateral damage is just incredible. Imagine driving a car on the highway, you turn on the radio and bum - there goes your speed from 130km/h to 40km/h. Though radio might play better.

Was MMCSS programmed by a high school intern? By a person who doesn't know the real world? Who knows. We can only hope that this issue is addressed in SP1.

Is your Seagate 7200.10 disk using SATA or SATAII?

Another detail regarding the Seagate 7200.10 disk (and perhaps other series as well). These disks are SATAII capable but aren't SATAII enabled by default. The difference is 300MB vs 150MB transfer rate. It actually does matter only when you are running RAID array because no single disk has 150MB sustained transfer rate so far. At least a mainstream disk. If you aren't on RAID then it is not that important (there is no big performance gain - most of the gain is only when PC is reading from disk's internal cache). Anyway, if you have SATAII capable motherboard then you might double check whether you are on SATAII or not. To enable SATA II  you have to remove a jumper located right to the data cable connector (it is also described on the sticker attached at the top of the drive). That's it.