Add logging and viewer