Enrico Zini: Playing with a Holux M-241
Playing with a Holux M-241
Here is how to download tracks from the Holux M-241:
gpsbabel -t -r -w -i m241 -f /dev/ttyUSB0 -o gpx -F date +'%Y-%m-%d-%H%M%S' .gpx
It might work also via bluetooth, but I have not tried yet.
Now, until M-241 support will be released in a stable version of
gpsbabel, here is how to compile the version from CVS.
Get the sources:
cvs -d:pserver:anonymous@gpsbabel.cvs.sourceforge.net:/cvsroot/gpsbabel login
cvs -z3 -d:pserver:anonymous@gpsbabel.cvs.sourceforge.net:/cvsroot/gpsbabel co -P gpsbabel
Untar this to
debianise the sources.
If it does to compile because of some errors in
lmx.c, apply this
patch.
Then you can install the resulting package and (hopefully) be
happy.
Note, after downloading the logs, gpsbabel currently turns on
logging.
Here is a patch to disable that behaviour.
Finally, if you want to hack around a little on the unit, you
can play with mtkbabel: the source
code is simple, and most of the MTK protocol is implemented, so you
can easily feed your own commands to the MTK. Documentation about
the commands can be found here:
- http://spreadsheets.google.com/ccc?key=pyCLH-0TdNe-5N-5tBokuOA&t=2046668448833862841
- http://www.rc-cam.com/misc/PMTK_commands.pdf
- http://www.tronico.fi/OH6NT/docs/NMEA0183.pdf
- http://www.sparkfun.com/datasheets/GPS/MTK%20Packet_User%20Manual.pdf
mtkbabel:
packet_send('PMTK300,500,0,0,0.0,0.0');
$ret = packet_wait('PMTK001,300,3');
And if you want to set the MTK to an insane 5Hz fix rate, to
take really fine grained gpx traces with your laptop, you
can use this:
packet_send('PMTK300,200,0,0,0.0,0.0');
$ret = packet_wait('PMTK001,300,3');

I ordered the - . It was not in the cards. The
was an acceptable compromise. I do love a good .
says that her grandma's is the bomb-diggity. I will probably
never verify this.
Linuxtag 2008 is over. Like 
I’ve spent more or less the last few days of spare time trying to figure out why gcc-4.3 built kernels were so unhappy on parisc. Basically the symptom was that any IPv4 networking operation would only complete once and a while, for example, ping would drop 90% of packets. This turned out to be a really troublesome bug to track down, and the fix was only 7 characters long.
gcc-4.2 wasn’t problematic, so that provided an interesting base. A bit of thinking ruled out some obvious parts of the kernel that would likely not be an issue. For instance, ARP appeared to be fine, so it likely wasn’t an issue at the network driver level. So rebuilding net/built-in.o on gcc-4.2, copying it to the gcc-4.3 tree, and rebuilding the tree using it resulted in a working kernel. Ok, excellent, we know it’s likely an issue in net/, what else can we rule out, and what do we know? ICMP is affected, so it’s probably not a TCP problem… Rebuilding the kernel with IPv6 enabled, and testing ping6? Ok, works. So it looks like an IPv4 issue. Test that assertion… yup, net/ipv4/built-in.o compiled with gcc-4.2 works.
Ok, peachy. What now? Bisecting the contents of the directory results in ip_output.c being the problematic file… Not all that helpfully, the differences between the code generated by 4.2 and 4.3 are extensive. Well, ok, let’s try turning off a variety of the added compiler options… nope, no luck, but the file works when compiled at -O0.
Next, I bisected the file until I found the problematic function (unfortunately for me starting in the middle, it ended up being the first function in the file.) Which was in a chain of inline functions, eventually calling some architecture specific inline assembly for ip_fast_csum. Ok, that looks like our canary in the coal mine… Look it up… SIGH. The routine touches memory, but didn’t have “memory” in the list of clobbers.
Adding the clobber and everything magically works again. Wasn’t that a party?
[ Of course, this makes things sound almost easy, except that at around 10 minutes to boot a test kernel, reboot, and boot a working kernel, this gets extremely tedious. I also didn't bother to talk about how many hours I probably wasted twiddling compiler flags trying to figure out which optimization pass might be broken... ]
As of yesterday, Czech is back to 3rd place, ahead of Portuguese, in the 
I used to help staff more exhibition stands
than I do now.
Part of the reason I stopped was that few
free software people seem to appreciate the
basics of running a good exhibition stand
and I got bored of arguing that we should
give people space, avoid putting a counter
across the stand, keep notes of contacts made
and basic stuff like that.
So, it was good to read


Buch of quickies:
strftime's time format does not support fractional seconds, but a lot of
people want to do that, based on a google search. It's been implemented as
an extension to several programs.
Each implementation I found uses a different conversion specification, and in
each case the character chosen was already used by something else in the
standard strftime. The only unused letters are: %f, %i %J %K %L %q %Q %w
(and perhaps some punctuation). Of these, "%f" has a good mnemonic for
fractional seconds. But I hestiate to poach from such a small space.
Looking at glibc's extensions to the strftime format suggested a different
approach. I suggest using "%.S" for fractional seconds. There's a good
mnemoic and this seems unlikely to be used for anything else. This could be
extended to include an optional precision ("%.4S").
It would also be nice to have a standard way of showing microseconds,
nanoseconds, and milliseconds too. "%uS", "%nS", and "%mS" would be nice to
use; unfortunatly, "%u", "%n", and "%m" are already used in strftime (so
are "%U, "%N", and "%M"). I don't have a solution for these, but they're
probably generally less useful than fractional seconds anyway.
With the cost of plane tickets approaching 2000 USD it is rather hard to sell me going to the Debconf 8 as that can be approximated as 3-4 months of my income. I did apply for travel sponsorship, but due to some kind of brainfart I misread “Amount I am unable to fund myself” as “Amount I am able to fund myself” and thus asked for far less money than I actually need. Therefore, after the Debconf team strictly stated that the requested amount can not be changed at this point, it has become clear that I cann’t come to Debconf 8.
/sadpanda
I would still love to come if there was sponsorship money to cover my fare and even suggested putting me to the end of the sponsorship priority list, but apparently that is not happening. Have fun, and see you all in Spain in 2009.