A detection device comprising: an oscillator configured to output an oscillation signal (So); a controller configured to output a control signal for controlling a frequency of the oscillation signal to the oscillator ; a transmitter configured to transmit an electromagnetic wave or a sound wave as a transmission signal having the same frequency as the oscillation signal (So); a receiver configured to receive a signal obtained by reflecting the transmission signal from an object, as a reception signal; a mixer configured to mix the oscillation signal and the reception signal and output a mixed signal as an intermediate signal; and a detector configured to detect a motion of the object and a distance to the object from the intermediate signal; characterized in that when a request (Rq) for distance measurement is not inputted from an external device , the controller controls the oscillator so as to set the frequency (fo) of the oscillation signal (So) to a constant frequency (fo0), and the detector performs first sampling of the intermediate signal at first sampling times (Sp1) according to a first sampling frequency defined by a first time interval (T1) in a first sampling period to detect the motion of the object, when the request (Rq) for distance measurement is input from the external device, the controller controls the oscillator so as to sweep the frequency (fo) of the oscillation signal (So), and the detector performs second sampling of the intermediate signal, at second sampling times (Sp2) according to a second sampling frequency defined by a second time interval (T2) smaller than the first time interval (T1) in a second sampling period shorter than the first sampling period to detect the distance to the object, the second sampling period being between adjacent first sampling periods , and the second sampling period is shorter than the first time interval (T1). an oscillator configured to output an oscillation signal (So); a controller configured to output a control signal for controlling a frequency of the oscillation signal to the oscillator ; a transmitter configured to transmit an electromagnetic wave or a sound wave as a transmission signal having the same frequency as the oscillation signal (So); a receiver configured to receive a signal obtained by reflecting the transmission signal from an object, as a reception signal; a mixer configured to mix the oscillation signal and the reception signal and output a mixed signal as an intermediate signal; and a detector configured to detect a motion of the object and a distance to the object from the intermediate signal; characterized in that when a request (Rq) for distance measurement is not inputted from an external device , the controller controls the oscillator so as to set the frequency (fo) of the oscillation signal (So) to a constant frequency (fo0), and the detector performs first sampling of the intermediate signal at first sampling times (Sp1) according to a first sampling frequency defined by a first time interval (T1) in a first sampling period to detect the motion of the object, when the request (Rq) for distance measurement is input from the external device, the controller controls the oscillator so as to sweep the frequency (fo) of the oscillation signal (So), and the detector performs second sampling of the intermediate signal, at second sampling times (Sp2) according to a second sampling frequency defined by a second time interval (T2) smaller than the first time interval (T1) in a second sampling period shorter than the first sampling period to detect the distance to the object, the second sampling period being between adjacent first sampling periods , and the second sampling period is shorter than the first time interval (T1). <EOS>