merge with my devel version + latest updates from svn (rev.802)
remove some verbose debugs
add error checking to sql queries
Merge pull request #1 from apietila/master

Fathom updates and fixes for home network project. Thanks Anna!