Real logging, please incorporate into new and existing code.
Merge pull request #273 from xj9/logging

Real logging, please incorporate into new and existing code.