If you want to use "by" before "using", you have to put this phrase in the sentences like the following:
A physician can detect fetal heartbeats by using a Doppler ultrasound device by the twelfth week of pregnancy.
The phrase "using a Doppler ultrasound device" is a prepositinoal phrase that functions as modifier. You cannot put "by" there, otherwise you cannot use comma and you have to put it to the end of sentences.
I think the error of this sentence is dangling modifier.