Support logger. Fixes #1. Input validation. Simple version of stop. Support subscribe/unsubscribe. Verified working. Needs tests.