change read_data_and_reflevel functions to read_data_and_context
move MainPanel.update_screen to BlockingMainPanel