add more ui and control code