Monday, March 08, 2010

GNUmed web interface

Hi all,

I am bringing this up every once in a while. There is no need to discuss the need for it again. I am simply interested in a proof of concept and collecting thoughts.

GNUmed has a wxpython based client. It is a wrapper around GTK on GNU/Linux. In the past I have wondered what it would take to hack a web interface for GNUmed.

There a far too many web toolkits to choose from. One of the ideas is to use a toolkit that will allow reuse of existing code as rewriting (e.g. the middleware) not feasible.

Toolkits that come to mind and have some userbase are Django, Turbogears and Pylons. All of them provide access to the PostgreSQL database and make use of python. However all of them are designed to talk to the database bypassing our middleware. Replicating the middleware makes no sense.

It is possible to reuse the midlleware we have. It can be done through XML-RPC. Mere chance has it I came across TinyERP Web on freshmeat. Digging a little deeper it looks like the solved the same problem. They have a default GTK-Client and now came up with a web-client based on Turbogears. They use XML-RPC. I am not sure if they use it to access what I would call the middleware. However if anyone wants to have a go at this here is their code to look at http://www.openerp.com/download/old/eTiny-1.0.1.1.tar.gz If you are going to attempt that I recommend to:

- create a webbased log-in dialog which resembles the fat client dialog.
- reuse GNUmed's python middleware for the connection
- glue it together by using XML-RPC to talk to the middleware
- implement a page that shows that you are actually connected to the GNUmed database

There is a project called 'medical'. It tries to implement an EMR on top of OpenERP which is the current version of TinyERP - the software the above webinterface is for.

http://medical.sourceforge.net/

Have fun,
Sebastian

Thursday, March 04, 2010

Voltcraft DL-140TH - data download fails

When building a house you sometimes want to continously monitor temperature and humidity. There are a few devices that can do that. Many of them can be programed via USB. The cheaper ones rely on the host PCs clock to make sense of the recordings while the more expensive ones carry an internal clock.

I got a Voltcraft DL-140TH. I can collect data for about 11 days if you program it to measure temp and humidity every two minutes. Unfortunately there is not software to read the data from GNU/Linux. A basic Windows software is available.

The other day I programed it and let it sit for 11 days. When I tried to get the data off the device it would download but not display it. It took two days and a bit of luck to find out that you cannot get a useful data transfer on USB 2.0 ports. When I plugged it into a USB 1.1 port it would work without a hitch.

So remember to plug it into an USB 1.1 port if you have trouble reading the data. If anyone has information on how to read that data on GNU/Linux I would like to hear about it.