Alex Caldwell

Reachable at mailto:[email protected]

I'm a family doctor and amateur Tcl programmer. I put together a program called Tkfp and Tkfp Medical Practice Management. I use it in my office daily to manage the medical records on my patients. I've used many of the wonderful Tcl extensions (tclxml, Incr Tcl, tkhtml, TLS) and entirely embedded a number of great Tcl/Tk applications (tclhttpd, plume, impress) by the people on the Wiki into the Tkfp program. I wrote some of my own code to organize these and make them work together in a useful way for a medical practice. It uses tclhttpd set up with TLS and openSSL and I also use SSLtcl with my own home brewed secure server for secure access to patient records with both a Tk GUI interface and a web browser interface to the database. Using all this Tcl power, I've set up a system that allows a patient to view and even update parts of his own medical record on line. I'm currently working on medical EDI - electronic data interchange (ANSI 837 v4010) format that Medicare and other Medical Insurance Co's in the U.S. use to transmit medical claims data. If anybody has experience with this area and would like to help, I would really appreciate it.

I also did a project for a doctor friend that displays an interactive medical decision making algorithm in a Tk canvas widget. The output from interacting with it goes directly into the patient's medical record. We call it "MedMapper" . It uses object oriented programming with the tclpp extension and you can edit the algorithm while the program is running without knowing anything about programming. It can save its current state for the next session. It can run as a freestanding app. or as a Tclet in a browser using the Tcl plugin. There is a Tcler's wiki page about it.

MedMapper Medical Decision Suppport

My other Tcl/Tk projects also generally relate to my interest in electronic medical record systems or "EMRs".

Handwriting Word Recognizer

XML DOM Tk Text Browser Editor


I made a web browser for the Agenda VR3 Linux powered PDA [L1 ] based on Steven Uhler's html_library-0.3. I think it was the first web browser on the VR3 that could do inline images and render HTML forms. I currently can't find where I had last stored it, and the Agenda VR3 appears to be a dead end piece of hardware, sadly.

Another project was a POP3 email client for the Agenda VR3 based on tclmail by Sean Levy. It was one of the first working e-mail apps for the VR3, but will work on any computer that can run Tcl/Tk and Incr Tcl also. It's available at

I'm not a good enough programmmer to contribute anything new to the Tcl/Tk core, I am more of an "applied Tcl" type of programmer. I mostly just try to be on the lookout for things other people have done with Tcl/Tk and its many extensions that I can apply in my real world medical project. But I did have a couple of Tclets that were used as demos for the Tcl plugin on the plugin's web site. One of which is below.

Sailplane Flying Game

I had a little thing published on the old Scriptics Developer site about "rendering" XML into a Tk text widget by using an XML parser such as tDOM or TclXML along with a one to one mapping of the XML tags using Tk text widget marks and tags. It works pretty well in my Tkfp app. I can edit the xml data right in the text widget and it all gets stored in the background as XML.

AK: A bit of nitpicking, please don't take it too bad. The homepage you refer above contains some references to Scriptics. I believe that it might be better to switch this to the appropriate references into ' '.

As for the medical data interchange this might a case for binary, no ?

Well, it turns out that the ANSI 837 format is not a binary format. It's just a simple ASCII text file. They (Medicare carriers) don't even transmit it over the internet. They use an old fashioned dial up bulletin board system with x-modem for file transfers. The ANSI 837 has some fixed length elements in it and some variable lenth elements and "loops" for batched claims. Too bad it is not based on XML, it would be so much easier.

Alex Caldwell I just started reading a new Tcl/Tk book "The Tcl/Tk 8.5 Programming Cookbook" by Bert Wheeler from Packt Publishing. It is available as an e-book online at I'm hoping it will get me up to speed on the new things in Tcl/Tk 8.5. It looks quite nice.