modified controller and UI - not complete