handle disconnects and refactor out execute_command function
tuning
fix interlacing issues
cleanup