Hi guys,
This is a very interesting topic.
Does anyone has a sample code so we can try?
Regards
Rui
Hi guys,
This is a very interesting topic.
Does anyone has a sample code so we can try?
Regards
Rui
It’s really a matter of reading a pin for a period and outputting that frequency.
You could probably use PULSIN for a period after sorting out mic hardware to trigger the pic input.
I used an LM358 op-amp to drive a condenser mic.
I’m using DT’s timer, and most assembler now, but still a simple program.
On interrupt, a frequency value is written to hardware PWM one way or another (that I haven’t settled on),
then the frequency variable cleared before returning to main program.
The main program only counts audio transitions with the frequency variable in a loop.
Tonight I got desperate and connected a 64.5 MHz crystal to the pic 16F628A and it works fine!
I don’t know if it’s actually clocking at that frequency, but I have used 24/25 MHz crystals which have always gone fine,
and it’s now much faster than them.
Last edited by Art; - 10th April 2015 at 13:59.
The example where it’s the loudest in the video (quite an obvious one),
I think I would have 80’s style speech recognition down.
That variation of the code was very repeatable for words/phrases.
Bookmarks