Building a Better Windows Mobile Development Experience
I really want to do Windows Mobile development because I love the potential for mobile application augmenting our daily experiences. Web apps are locked in my browser which is locked in a desktop that just sits there. Location awareness is not really important and there isn’t much exciting reality to augment. The problem is that every time I open up a new windows mobile project in visual studio, I realize how much building something is going to suck. I’m still amazed that Apple went from no developer platform to the best one in about a year.
Here is a nearly comprehensive list of my gripes and suggested improvements:
- WPF / SL mobile. I’m all in on declarative markup for UI development. Especially on mobile with sizing things for different screen sizes / orientation, the WPF / SL layout system would be awesome. Not as excited about SL unless it runs out of browser with direct hardware access. Which would basically be WPF. So WPF mobile. Having animation and total control styling support is the only way to make experiences on par or better than the iPhone. The default WinMo forms look and feel doesn’t really cut it and animation isn’t exactly easy in WinForms. Right now the current state of compelling UIs is here. That is a lot of code for just a prototype to make a decent looking button.
- Managed APIs for sensors. Apple has cool apps with the accelerometer and GPS and compass because it’s easy to use the APIs around that. Granted they have basically one phone to support. But still, force phone makers to build drivers for a sensor API like the one on Windows 7. Look at the current situation – there is a “Unified” API on Codeplex for the accelerometer that supports 2 phone types. I don’t want to write one off code for this or that type of accelerometer. Also:
- Compass. Similar situation to the accelerometer. It’s hard to build an app in the app store using the accelerometer if every manufacturer is going to use a different driver API.
- GPS / Cell Tower Triangulation. Currently GPS has a nice API but cell tower location uses this mess. With all those caps I feel like the pInvoke is angry with me. Can’t this be wrapped into the same managed GPS GetPosition method? Sure I could write the suggested location factory and implement both. Or you could write it and put it in the framework so all developers could have 1 location API that works.
public delegate void RILRESULTCALLBACK(uint dwCode,
IntPtr hrCmdID, IntPtr lpData, uint cbData, uint dwParam);
public delegate void RILNOTIFYCALLBACK(uint dwCode,
IntPtr lpData, uint cbData, uint dwParam);
[DllImport("ril.dll")]
public static extern IntPtr RIL_Initialize(uint dwIndex,
RILRESULTCALLBACK pfnResult,
RILNOTIFYCALLBACK pfnNotify,
uint dwNotificationClasses,
uint dwParam,
out IntPtr lphRil);
[DllImport("ril.dll", EntryPoint = "RIL_GetCellTowerInfo")]
public static extern IntPtr RIL_GetCellTowerInfo(IntPtr hRil);
[DllImport("ril.dll")]
public static extern IntPtr RIL_Deinitialize(IntPtr hRil);
All APIs in managed code. I’m sure that’s a lot of work, but it’s not fun digging though the C++ docs to figure out how to pInvoke some function if you’ve already built the whole app in managed code because some key APIs are missing. It just feels wrong when I have to start dropping in some unmanaged structs to call SOMECRAZYLONGNAMEDFUNCTION
Speech Recognition. The .NET desktop one is good. Toss that on the phone. Don’t worry, I’m not going to steal your Voice Commander app. Just let me process speech.
Video Capturing. I fairly certain this can be done well enough via Direct Show, but this could be way easier. On openframeworks in C++ I can process a video stream in about 5 lines of code.
XNA. The Zune supports XNA, why not WinMo. Surely it must be possible. Oh and include some APIs for WinMo to XBOX connectivity to add a new dimension to games
Replace Compact Framework with full .NET. At some point can’t WinMo just be Windows 7 core running full .NET?
Expose everything via APIs. It seems like Apple just took all the APIs they use to make the built-in iPhone apps and made them public. Look at the apps other developers made on top of those.
Push notifications. That was a a good idea on Apples part. I think background tasks have a place like letting me stream music while doing something in another app, but I don’t need Facebook running 24/7 to poll for new mafia wars updates from some guy I barely knew in high school. This feels like it should be in Microsoft’s wheel house and could be much better than Apple’s.
Basic hardware requirements. A lot of WinMo phones are poor performing junk. Can’t there be some licensing restrictions around what minimum spec a WinMo phone need to meet? On the iPhone you know what to expect. On WinMo you have to worry about different resolutions or capabilities plus slew of really slow phones.
When I first started writing this post I had many more complaints. Then I did some digging in the WinMo docs and there a bunch of articles posted about month ago that address those issues. Like touch gestures. The developer experience does seem better than 1-2yrs ago. If I would man-up and use the unmanaged APIs, I’d probably feel the SDK was more complete. But I like managed code. Regardless, I think most apps are going to look fairly mediocre until WPF makes it to WinMo.