writing other message handling routines, and config stuff