I am new to arduino world and therefore would like to know how to do DFT using analog read (real time). I know its slow compared to FFT, I checked sample rate to check how fast signalled can be sampled & was pretty fast i.e 1000ksps for 10 resolution.

I need pointers, code help for the implementation of DFT of a signal being read from analog read port and display result in com port or matlab.

  • Welcome to Arduino:SE. Please be aware that this is not a free design house or an on-demand online technical encyclopedia. It would help if you told us where you have already researched, and what you have found so far. You might find it helpful to review the site tour and Help Centre and, in particular, How to Ask. – sempaiscuba Feb 4 '18 at 14:23
  • I am well aware of SE, so far I have looked into Goertzel algorithm, DTMF and so on. I am in search of simple DFT implementation with analog read, any pointers are much appreciated, as I just started with ardiuno. Plenty of FFT examples are available. however, I am unable to get pointers on DFT. – Sushant VS Feb 4 '18 at 14:45
  • There are two parts to your question: 1. How to sample data at a steady frequency on a Teensy, and 2. How to perform a DFT on a sample set. Part 2 has plenty of examples on the net (google "DFT in C"). Part 1 we may be able to help with, but you may get better results from the Teensy forums where people know the underlying hardware better. – Majenko Feb 4 '18 at 14:53
  • @Majenko, Thank you for elaborating, I will ask in teensy forum too. Regarding part 1, If I am not wrong, we need to set adc resolution and averages, teensy clock speed to set the sampling speed, as provided in Github->ADC library for Teensy?? – Sushant VS Feb 4 '18 at 15:18

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.