take configuration file as arg
fix docstrings, define write handler inline
typo
function name changed
split configuration for interface modes