Thank you for your reply!
I tried your sketch, but sometimes I would have errors recording data, then I can't plot FFT. I think the reason might be "delayMicroseconds(50)", so what is the purpose for using this here? But those errors only occurred occasionally, sometimes I could plot the FFT...