getting the scan activity to work