Wednesday, September 28, 2005

A little more VoIP

Well I've done a bit of fiddling with my Asterisk setup. For those that haven't been following this saga: Asterisk server (2GHz Sempron, 512M RAM and 30G drive), a Grandstream BT100 IP Phone and a Sipura SPA-3000. I've finally fix the BT100 registration problem (needed host=dynamic & insecure=yes). I can also use the canreinvite=yes to get the BT100 to talk directly to the SPA-3000 after the call setup starts (the actual RTP portion of the call). This is important if you don't want to hear all sorts of oddities on the phone (clicks, drop outs, really bad echo). Unfortunately the SPA Line 1 and PSTN interfaces don't want to talk to each other directly (all the RTP goes through the Asterisk server, not good). The last problem is the volume level of the call. I set the SPA To PSTN Gain: -3 and the PSTN To SPA Gain: 3. This seems to boost the volume a little and avoids excessive echo that I've seen when I had the gains set to -6 & 0 respectively.

Here's my opinion of the BT100, it's an acceptable phone for experimenting with but I don't think I'll buy another. This phone will have a low SAF (Spouse Acceptance Factor). The buttons are large but feel a little cheap. The overall look is fine, but it would be nice if it had a little more weight so it didn't move around on the desk. I have to say it's features are not bad for the cost. Also Grandstream seems to be constantly updating the code with fixes and improvements. One major problem is the speaker phone. Listening to the speaker phone is difficult because it looses so much volume (even turned all the way up) and the micro phone won't properly pick up my voice at a distance of 2 ft (1 foot away and 1.5 feet below my head) on my desk. Since this phone is well out of warranty I may do some hardware hacking to boot the volume to the speaker and see if I can't improve the mic pickup. I'll have to be careful of feedback. BTW, the handset works fine, though I often have to lower the volume after using the speaker phone. For my next IP phone I'll take a look at the GXP-2000 and other IP phones.

One last thing, I've also been fiddling with the 'ring tones' for the BT100 (I expect that the GXP-2000 has a similar format for it's ring tones). I've been able to listen to the ring tone files from the BT100. I converted them from the G.711 format to wav using sox. The ring2.bin and ring3.bin files are just noise. The ring1.bin is a series of numbers and the final statement of ' You have a call from' nnn-nnn-nnnn, so I think I'm on the correct track. To listen to a ring tone run the command below and then run play ring1.wav:

sox -Ub -r 8000 -t .raw ring1.bin -t .wav ring1.wav

To convert a wav file to a ring tone run this command:

sox -t .wav ring1.wav -Ub -r 8000 -t .raw ring1.bin

Then you copy the ring1.bin to the tftp directory. Unfortunately I've not been able to copy the file to phone a second time (yes it worked previously).

Thursday, September 22, 2005

Oops, did it (yet) again ...

I'd like to apologize to Dan Lanciani, my iplcd (Insteon PLC daemon) contains portions of Dan's x10d and I tried to switch to the GPL. So not only is my program based on x10d it contains x10d code (that's bad). I've now switched it back to Dan's license. I'd like to thank Dan for very politely handling this and promise to be more diligent in reviewing the code before such changes occur again.

Bob Cusey from Insteon got me an USB PowerLinc V2 PLC to work with and I've managed to talk to it. Because it behaves differently I need to modify some code to get it to work. I'm currently working on which program to modify (the iplcd or the USB iplc driver). I'm also working with Bob about a way that the open source community can get the technical details of the protocol so we can create the necessary programs to support Insteon like we have for the X10 protocol (I don't know, X10 and support in the same sentence, weird! ;-).I'm sure we'll come up with something. Insteon is very interested in getting the HA community (commercial, open source, gadgeteers, early adopters and plain end users) involved with the Insteon product line.

Here, in my opinion is some of the more important Insteon points:

  • They've got the price in the right range. Price better than high end X10 stuff and, in my opinion better quality too.
  • Closed loop control protocol (devices ACK/NAK commands). X10 is open loop.
  • Insteon controllers repeat Insteon commands (not X10 commands). I feel that this makes it work better in my enviroment (nasty black hole with no filters).
  • SignalLincs! Makes a nice phase bridge and boosts the signal as well. The PLC's don't have built in RF capability but there are no RF devices to control yet.
  • Power line and RF. One of the problems I see with an RF only solution is that the consumer RF spectrum is saturated. I live in a middle class neighborhood and my wireless network has problems with lots of wireless networks and phones.
  • The PLC signal is within acceptable levels for Europe. This means a lot more customers (more customers, more affordable).
  • Hardware Development Kit (HDK) are available (I want one of these to build an Insteon controlled and monitored Coffe pot).
  • RF Development kit (HDK) will be available soon.
  • Insteon chips will be available also so products don't need to continue to use the HDK's

If we can get the controllers to tell us the state has change (user intervention) the last problem with X10 will have been solved. There are probably a few more things that I've forgotten. Yes I'm impressed by Insteon! :-)

The last thing is I'm moving the Linux Home Automation pages to my site. I've had my web site at it's current home for the last 9 years (first as @Home then Comcast). I just received a bill from Comcast for $150 for TV and Internet access. It looks like Verizon may get a chance to provide TV and internet access. I'd like to think this will drop prices but Comcast has not dropped price in the past instead they've given us more. So by moving my web site early I can get the search engines and internet to point in the correct direction.

Friday, September 09, 2005

And so it begins ...

Well first let me get this out of the way (some good news). The other day I pulled my insteond package off the net because I believed that there were license incompatibilities between the Insteon License and my choice of the GPL. I've spoken to Bob Cusey, from Insteon, and he say they have no problem with what I posted except the name. So I changed it to iplcd and I've reposted the code on the internet for all to use. I've also created a man page, the readme, a little history file and I'm trying to learn how to use the auto tools and build RPMs (I still maintain the tar balls also). The last 2 items are driving me nuts. They're very flexible but also very confusing.

And not the reason for today's post. I've signed a contract with Wiley to write a book called "Linux Smart Homes for Dummies". I'm hoping all these links and my postings are enough to help me write a good book. I'm not much of a writer so this will be a difficult task. I will cover the basics such as X10 (still has too much of a market to ignore them), Asterisk, IP cameras, some security and other topics. All of it to fall under Open Source, of course.

Sunday, September 04, 2005

Oops, did it again ...

... 'cept this is the first time. In a recent comp.home.automation newsgroup thread, Dave Houston pointed out that the Insteon License was rather stiff. So I went back and re-read the license and I have to agree with Dave on this one. Of course, like a bone head, I released my insteond software under the GPL. The 2 licenses are incompatible so I need to remove my software package from the net. I really need to pay more attention. My excuse (a bad one) is that I've been rushing about, dealing with licenses and contracts ('cause I'm writing a book, more on that in a minute). Now really that's a bad excuse but that's what I did and the rectify this situation I've removed the software. I'll work with Insteon to see what we can work out, I've already sent an email to Bob Cusey and I have a few ideas. They've always been willing to work with the developers and I think they'll work with the Open Source community in the same good faith. Sorry to cause such trouble.

Now back to my comment about a book. I've signed a contract with Wiley to write: 'Linux Smart Homes for Dummies'. It's about home automation, under Linux (the ideas should work under and *nix & Cygwin for Windows) using Open Source software. It should cover using X10 (maybe Insteon if we can resolve the above and I have enough time to write software), Asterisk, IP camera's, weather software and a few other things. I'm excited and terrified at the same time. I'm excited because HA is my passion and terrified because I don't explain things that well (Yipes!). Anyways, the BLOG will be a little slow as I have a lot of work over the next few months. I will be hosting the book's web pages on my LinuxHA web site. The site is not really properly setup but I do have the HA Forums in place. Currently there is nothing there as I haven't written the book so it's hard to discuss the book without it being written. ;-)