PDA Development


Welcome to my PDA development page. It used to be my Sony Clie development page but I would like to have this become less specific to any one particular PDA. So far I've only made one "contribution" but I know my page has become one of several repositories for the Sony SDK patch so I think it's something worth having here. I've even left all of the old folders intact so I don't break links that search engines might produce.

Sony SDK Patch
Setting up the development environment for the Sony Clie has been an interesting experience. After installing Palm's PRC-Tools and configuring those to work independent of my GBA development (they both use cygwin) I signed up for Sony's developer program. From there I got their SDK and had to sign an eight page contract in order to gain access to their development ROMs. That process took a little over a week but that's not the end of it. When I tried to compile my first program using Sony's SDK gcc dumped dozens of lines of assembly and complained that they were possibly bad call sequences. Great, some kind of inconsistency between Code Warrior's compiler (which is the only compiler Sony supports) and gcc. Well after inquiring about the errors I found out that these were actually bugs on Sony's part. Apparently the C standard states that passing enumerated constants to macros has undefined behavior when translating to assembly. Well Code Warrior lets this slide but gcc doesn't. Since Sony only supports Code Warrior I guess they didn't bother testing on any other compilers. So eventually I found a Perl script that fixes the bugs in the SDK... well mostly. Below you get to see my first contribution to the Sony Clie development community! Well at least I can start getting into development for this new hardware now, just too cool.

This script was originally written by Ronny Iversen and you can download the original script at Falch.net. There are two versions, the first was updated by me to fix the SonySndLib.h file in addition to Ronny's fixes and works only with SDK3. The second is even better yet. It was updated by my former roommate, long-time friend Keith Batten and it will patch the SDK5 files. More detailed information is provided in the next paragraph, which is followed by the downloads (probably what you came here for).

The original script fixed three files in the Sony SDK: SonyMsaLib.h, SonyHRLib.h, and SonyRmcLib.h. These are where the bulk of the problems occur but there is one other file that contains the bug: SonySndLib.h. Since the original script was so well designed I thought it would be a one line addition to fix this file as well but it turns out that the typedef in the SonySndLib.h file is formatted differently than the other three files so I had to do a little work. I won't bother explaining all that I changed since it's nothing really Earth-shattering. I guess you can just compare mine and Ronny's scripts to see what I had to do differently. Keith added support for SDK5 and I haven't looked it over too much so if you've got questions about the SDK5 part of it you should ask him. Brian Apps has also made a contribution here. He ported the Version 5 fix to VBScript so that MS Windows users don't need to download and install Perl to fix the SDK. This is pretty handy if you ask me (even if you don't ask, I'm telling you now :). I imagine many if not most Clie developers develop on Windows so this will definitely help people get to the coding phase faster. The link for his files is below. Let us know if you find these files useful!


Special thanks to Ronny Iversen and John Marshall on this one.