Added some more sanity checks for input parameters, and correct type coercions (string->number).
Merge branch 'master' of github.com:fingon/hnet-core
Merge branch 'master' into owrt-trunk