make Writer a class, we need multiple instances
also rename fwriter.py to writer.py, revise docstrings