Error while enabling scanner

Hi,

I am trying to enable scanner using the enable API but keep getting this error "Cannot enable scanner and is already in use".I am wondering if i am trying to enable scanner while it is in the wrong state.How do i check this?