Thursday, September 04, 2003

If You Are Not A Techie, Skip This

[Cloned from my Slashdot journal.]

So my title has been settled: my new business cards will state I am a 'Senior Research Engineer'. I think it sounds cool.

My current research gig is taking over a project from the person whose position in the group I am filling. Its current shape is a collaboration with an IBM Alphaworks project from a group in Austin TX. I want to do a site-visit, but can't find an angle to make it necessary, yet.

The project is about a system that makes it easy for programmers to make programs that communicate between mobile devices and back-end servers[0] at fixed locations. My end is to make the programs that can run on Series 60 phones -- these programs are called "clients" -- in various languages to show off how easy it is for programmers to use their system to do this, co-ordinating server and client objects.

First demo client was coded by my predecessor, it is going to be shown off at some mobile conference. I took a look at it. I have been in a demo-driven lab before, at CHIP, I have even stood on a demo floor at a trade-show for three days, showing off some medical-system prototypes to disinterested CFOs, CIOs, CEOs, journalists, doctors, and other clinical personnel shopping for systems, in a booth sponsored by SUN that was trying to generate medical buzz for their new-fangled JAVA language. I know what a demo needs to have to be credible. This thing was close, but not close enough. I sent a memo in email.

There was some consternation among my manager and my predecessor who would make the demo better, since I have to work on the next client, in C++. They were stopping in my cube to tell me I should ask some of the other researchers in my group for help, because I might be overloaded. I smiled and nodded and fired up Eclipse, configured Antenna, spent half a week learning my way around J2ME, and made the changes. JAVA is my native tongue now, people. J2ME only makes it smaller, which makes it even easier. The demo is good now. The person organizing the collaboration, managing getting it to the conference, and a source of future funding, likes it, likes the touches I added. That's what I do, baby, get used to it.

The next client is not in the confines and simplicity of J2ME, it is in C++. Symbian's version of C++. A fucked up version of C++, no exceptions, no polymorphism, and tons of traps and macros and double-stage constructions, all designed to deal as resource-starved as possible with the possibility that somewhere, in some call, the phone will say "fuck you and your program, I ain't got the free memory / connection / screen" and yet still be able to run for years uninterrupted. It is a nightmare for the novice of resource files, utilities to change one type of descriptive file into another, packagers, linkers, more linkers. I have spent a week now just acquainting myself with the tools and the strange organization of programs. The OS practically enforces a Model-View-Controller separation, and everything is a also a library. Oh, and don't use standard C++ types. Ever. Only Symbian derived-variable types, please.

I am having the worst case of Empty-Project syndrome, I can't get myself to start. The only way this is going to work is by pilfering one of the many, many example programming projects supplied and reworking it. I must start tomorrow.

On the other hand, even though I haven't coded a single line, I feel how powerful this system is I am working in. I have access to all the systems on the device, going through the endless APIs I even found the calls to use the voice-commands sub-system. JAVA shields you from the computer, gives you a neat little sandbox, but also shields you from the raw power, the real windowing system (which is why all JAVA programs look slightly out of place), the real sound system, the real libraries of other programs. I got used to it over the last, oh, 6 years, and coded around it, always making approximations, little wanna-be's. Now I am back suffering the pain of touching the real OS and the fucked up memory- and resource models, but there is also the reward of the power, all the possibilities. Pity I won't I have to time to explore it.




[0] Jargon: the communication-protocol is SOAP, a protocol for marshaling and unmarshaling objects, so that to a client it looks like the objects on the server, the ones with all the data, look like they are running locally. Offering objects over SOAP like that is called "WebServices". IBM's WebServices for Mobile Devices Toolkit is supposed to make generating the client- and server-stubs very easy. Austin sends me the library of client-stubs, I code a little program around them.