Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - Entropy

Pages: [1]
1
Off Topic forum / Reverse engineering an IR protocol
« on: March 20, 2005, 06:12:39 pm »
Quote
http://students.bath.ac.uk/enpsgp/Zaurus/accu-chek.html


Si

P.S. I received an email from a chap who was interested in adding support for this meter to the KPUMPE Project (of which I'd never heard I must admit). It seems to be a blood sugar analysis program, and OpenSource, just what I wanted :-) (though I'm sure there'll still be a place for Octave/R analysis too ;-))
[div align=\"right\"][a href=\"index.php?act=findpost&pid=65169\"][{POST_SNAPBACK}][/a][/div]
I haven't been here in a while.  (BTW, I'm not a Zaurus user, this was just the only place I could find any protocol information.)

Annoying that my attachment got nuked, good thing you've mirrored it, although I'm pretty sure I still have it on my laptop.  I still need to do some serious cleaning up of that script, I've just been too busy with other stuff to actually DO anything.  

BTW, could you post a communications log of the Compass software setting the meters' time?  I'd love to be able to add time setting functionality to my meter.

2
Off Topic forum / Reverse engineering an IR protocol
« on: August 13, 2004, 11:54:12 pm »
Attached is a somewhat cleaned-up version of my Perl script.  It's still a mess.   There are a lot of print statements commented out - uncomment them to see what the meter is spewing back.

This version actually pretty-prints the results and times.

3
Off Topic forum / Reverse engineering an IR protocol
« on: August 13, 2004, 09:17:45 pm »
Thanks for putting up your logs...

This has to be the most incredible timing, you started this thread the day my endocrinologist gave me an Accu-Chek Compact when I asked him about it.  (Gotta love the "give away the razor, rip em' off on the blades" concept that the bloodsugar meter companies adopted.)

Going through portmon logs is really unpleasant...  All those *$#@)* status checks, but I eventually figured out a good deal of what's going on by looking through the log you posted.  (I don't have Compass myself, nor do I even have the cable, but neither have stopped me thanks to your log.  

The protocol is standard IrDA serial, 9600 8N1.  If you happen to have a machine with an IrDA port (The Zaurus is a good example, I'm not a Zaurus owner myself but I do have a Dell Inspiron 8200 with an IR port that is dual-boot Linux/Win2k)., no need for Roche's $30 cable.

The protocol seems to be a mix of ASCII with the occasional nonprintable control character thrown in.  Most prominent are that all commands seem to have 0x0D as a postfix, and most return strings are preceded by 0x0602 and followed by 0x0406.  I have actually been able to see my bloodsugar results in plaintext returned from the meter.

I'm working on a Perl script that retrieves the readings from the meter.  I'll post it after I clean it up slightly.  I also need to bump up the count of readings by one so I can figure out which of the return values is indicating the number of current readings in the meter.  Yours is obviously at the maximum value of 200, mine isn't (5 right now...  Since I only have one drum I'm switching back and forth between my Compact and my Glucometer DEX.), and the number of readings to retrieve must be specified. (If you specify too high a value, it won't work.  Appears to give some sort of error, but I have no idea if it's actually an error or what.  )

Edit:  Just did my evening bloodsugar test, and the number of results is returned after the "`" command is issued.  Yes, one of the commands is simply "`" followed by 0x0D.

The other commands present in that log are:
C4
C 3
S 1
S 2
S 3
a 1 N - where N is the number of readings to retrieve.  The command actually be
a X Y - where X is the index of the first reading to retrieve and Y is the index of the last.

The second to last printable character of EVERY return string seems to be 6.

Another last edit:  For some reason you cannot send characters to the meter very fast.  In my script I need to put a small sleep in between each sent character - If I send them all at once, or each in a seperate write() command without any sleep commands in between, things break.

Pages: [1]