Older blog entries for dhd (starting at number 84)

Interesting.

As it turns out the USB headset/microphone that I bought was missing its USB interface module. The manufacturer has very graciously sent me a new one, but the tech support guy made some very discouraging noises about the possibility of using it with Linux (for the record, it's a Telex, and their other microphones actually work quite well with the USB audio driver).

Guess I'll be getting acquainted with the wonderful world of USB sniffers.

Burf. Also hurf.

Hacking telephony stuff again, trying to get all necessary and actually working updates (as opposed to gratuitous features and API changes) from the OpenH323 ixj drivers into Linux 2.4, with a fairly good degree of success - the driver is obscenely huge but actually really simple. It seems that PSTN ring detection works a lot better in the stock kernel driver. Some other PSTN-related stuff is a bit messed up though.

My phone server works pretty well as far as I can tell - I wrote a client interface for it whose design I rather like, and which I'll probably reuse in the future. Namely:

  my $c = Phone::Client->new({ Domain => 'UNIX',
                               Sock => '/tmp/.phoned' })
  	or die $!;
  $c->attach('/dev/phone0', 'PSTN');
  my $s = IO::Select->new($c->fh);
  while (my @s = $s->can_read) {
    foreach (@s) {
      if ($_ == $c->fh) {
        $c->read_more;
	if ($c->inmsg_pending) {
	  while (defined(my $msg = $c->inmsg_dequeue)) {
            handle_msg($msg);
        }
      }
    }
  }
And so on... Except of course I'm using POE instead of IO::Select. Next item on the agenda is to make a POE component (or wheel, I'm not sure - I need something that will demux the various message types and turn them into POE events) for it.

The plan is to extend the phone server to be a general purpose streaming audio server for various devices. Yes, I'm fully aware that this has been done ten-billion times before ... and guess what, they all suck!

Getting phone lines at the office today. Better bring my modem...

Sprint PCS:

  • We'll fuck up your billing, then disconnect your service without warning.
  • Oh, we counted your deposit as a payment. Oops.
  • You have no credit, therefore you can't pay with a debit card.
  • To do an electronic bank transfer, we need a cheque number.
  • Call back in 8 months, maybe we can help you then.

If you move to the US, do not attempt to get a cellphone until you have lived here for at least a year. Take it from me, it's no fun at all.

If you do decide to get a cell phone, do not get Sprint PCS. They are assholes of the first degree. I want them to die. Even Verizon must be better than them.

Because I have no credit history in this country, my business does not matter to them. Therefore, they feel free to do things like:

  • Disconnect my service the instant that there is an outstanding balance on my account, before I have even received a bill for said amount.
  • Refusing to let me pay by cheque or debit card (I must go to one of their phone centres and pay a $3 service charge, or go to Radio Shack and wait 48 hours - and I must supply an invoice, which, as noted above, I have not received).
  • Refusing to tell me why these arbitrary restrictions are being placed upon me.
  • Giving me a password for their web-based account management system which does not work.
  • Requiring a $125 deposit, requiring me to pay via a phone centre or Radio Shack (and then, in cash, at said location), then sending me a bill for this deposit nearly a month after I paid it.

I am fed up with them, but ... guess what! ... I cannot switch providers, because my phone only works with Sprint. Welcome to the golden age of free markets and competition for the airwaves.

Well, sorry folks, I'm not going to make it to linux.conf.au this year (hopefully, the organizers are reading the lca-speakers list and won't find out here first!)

In other news ... more hacking. It feels like I haven't really accomplished a whole lot. I may be guilty of trying to do things right the first time. Of course, I'm also actually documenting my code. Unfortunately the highest priority work right now is things like CGI scripts for the company website (mind you, they are talking CGI scripts :-)

The Sphinx-II Perl bindings (to be called Speech::Recognizer::SPX) will probably be released simultaneously with the next version of Sphinx-II. I also have some Edinburgh Speech Tools integration that is mainly intended for future versions of PointyClicky but should also be useful for other fun stuff (spectrograms, pretty pictures, etc).

I never thought I'd actually lose weight working at home, but that seems to be the case. At least, judging by the amazingly scientific pants-o-meter. I guess it makes sense, since I almost never eat at restaurants anymore. This might also explain why my kitchen is actually clean.

"Bell Atlantic is now Verizon", and they finally managed to install my loop, and I have DSL. I haven't had this kind of connectivity at home for ... probably the better part of a year now. Of course I have to abuse it for a little while ;-)

Napster seems to be marginally useful, so unfortunately I'm not ready to Burn All MP3s yet (though I've been steadily amassing Ogg Vorbis files of my vinyl/CD collection). I found the (fairly common but out of print) GISM bootleg CD whose name escapes me (with the tracks from "Detestation" and "M.A.N." on it) as well as the recent INFEST bootleg and of course the usual assortment of hard-to-find satanic heavy metal. Sounds like the new Catharsis album is rather good too, guess I'll have to buy it (being lame, I missed not one, but two shows on their tour ... one in Ottawa before I moved, then one in Pittsburgh after. Doh!)

Lots more Perl and XS hacking (fun) and some C (not as fun) at work. I'd forgotten how time consuming and aggravating it is to write networking and text-munging code (i.e. for text based network protocols) in C. But Perl and asynchronous I/O don't play nicely, and though POE is pretty awesome, it adds a lot of latency to the system which the telephony junk proved unable to cope with.

That said, I am rather proud of the design of the telephony server I've written to get around this problem. To satisfy the petulant telephony device it uses an async-I/O core driven by realtime signals (of course, I had to hack the driver to do proper siginfo based notification ...) then layers a single-threaded server on top of that to talk to clients and queue and dequeue events and data. Single threaded servers are good, people! Don't believe the hype!

It's unfortunate that AsteriskPBX is so keen on using threads for everything (grr), because otherwise we'd just use it since it already has exactly the architecture and hardware support we need.

Looks like sourceforge were moving when I had issues with them. So maybe I should edit out the comments below.

Wow. So, I submit a support request to Sourceforge asking why I still can't log into their shell machine (or the IA-64 boxen I was supposedly given access to) after having my account for three months, and the support request disappears into thin air.

I really wish I could just ignore Sourceforge entirely (which I've done a reasonably good job of for most of its existence) but unfortunately the CVS tree for CMU Sphinx is there, and I theoretically have (limited) check-in priviledges.

Since Sourceforge is so incredibly broken I guess I'll just return to sending patches, which is probably a better way to do things anyway.

Woohoo, I finally clued into why my T21 crashes. Nothing to do with the sound driver, instead the problem is that the XFree86 driver for the S3 Savage is buggy, and I get the "fast text scrolling causes bus lockups" problem.

The sound driver still doesn't seem to do non-blocking reads correctly though, because recognition is astoundingly poor (even with an external mic). Either that or the gain is borked. Guess I'll debug this today...

Oh hey neat ... the ALSA library API document actually documents the PCM stuff now. Sorry :-)

12 Dec 2000 (updated 13 Dec 2000 at 14:41 UTC) »

Got a Thinkpad T21 for work. Very nice machine. I got 2.4.0-test12 working on it and discovered that it locks up randomly at least once a day. Unfortunately only 2.4 has a driver for the CS46xx sound chips that will do recording (I do not count vendor-hacked 2.2 kernels, grrrrrrrr).

I backported the cs46xx driver to 2.2.18 ... more lockups. However it has locked up when I'm not even playing sound at all so I don't really know if it's the sound driver or not.

We may give up on using the Quicknet Linejack card. It's just too broken. The Lucent Winmodems are at least modern devices that know how to do DMA and such, and the driver apparently actually does full-duplex and provides a friendlier more sound-card like interface (so we don't have to do Rx/Tx ring buffers and asynchronous I/O in userspace to make them work...)

I've split out some of the less useful parts of Sphinx-II into separate libraries and fixed the broken autoconf setup. Today I've been trying to make the ALSA audio input module compile again.

I really am wishing I could spent more time writing code that works and less time dealing with other people's code that doesn't work.

75 older entries...

New Advogato Features

New HTML Parser: The long-awaited libxml2 based HTML parser code is live. It needs further work but already handles most markup better than the original parser.

Keep up with the latest Advogato features by reading the Advogato status blog.

If you're a C programmer with some spare time, take a look at the mod_virgule project page and help us with one of the tasks on the ToDo list!