logging and screen setup