Wednesday, July 30, 2008

new milestones

Well I pushed a new build of talkLock out to Sourceforge. There are some new event-driven things happening, but mainly I successfully got talkLock to cope with the fact that different phones sometimes use different audio encodings.

It is ugly and hacky, but by using Manager.getCapabilities, I was able to tell whether talkLock was running on a blackberry or an LG CU500. The blackberry just does straight up wav audio, while the LG does amr. With this code audio recording and playback works on the LG as well as the Blackberry :)

This is cool, since in order to have conversations between phones with different encodings, the program will have to know what type of audio it is playing back. I really hope the LG will be able to play back wav that was recorded on the Blackberry. I think that playback is much more mature than recording in MIDP, so I am optimistic.

Now I am starting to work on the networking code. I won't really comment much on it, but after being mocked for a couple of days by Tomcat and trying to do things the servlet way, I have decided not to inflict that on others by writing the talkLockServer component in Java. Instead, I already have a little experience working with HTML forms using PHP, so talkLockServer will have a .php suffix.

Also I think that I will use some kind of database, maybe MySQL, to store and retrieve the hunks of audio data. Since it does some smart caching, I don't think the audio will actually get flushed to disk very often. If everything happens in RAM, it should be pretty quick.

I hope to finish "processing" and mulling soon and get some more code written.

No comments: