added sample input control to demos