1
\$\begingroup\$

This question already has an answer here:

I have an electronic system waiting to be triggered (no microcontroller for now). My laptop only has USB ports.

I want to trigger it using voice recognition (this part is ok).

For now the only think I can think of is :

Once the right keyword is detected, send a 19 KHz sine on the audio output, because it's inaudible, for 0.1 seconds and uses a microcontroller analog port to detect it.

I only have microcontroller with no USB support available and I've never used a USB connection.

I'm not looking for something perfect, a dirty solution would be all right, this is just to do a prank tomorrow.

Thanks.

\$\endgroup\$

marked as duplicate by Tom Carpenter, ThreePhaseEel, Dmitry Grigoryev, laptop2d, Dave Tweed Dec 20 '16 at 1:37

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

migrated from stackoverflow.com Dec 18 '16 at 0:26

This question came from our site for professional and enthusiast programmers.

  • \$\begingroup\$ Why don't you use Serial? Arduino has great support for it \$\endgroup\$ – martianwars Dec 17 '16 at 20:24
  • \$\begingroup\$ no serial port on the laptop or usb to serial converter at home, I have 20h to finish now. I'm already building the 19Khz version but if anyone has a better idea I'm all ears. \$\endgroup\$ – sliders_alpha Dec 17 '16 at 20:33
  • \$\begingroup\$ Which uC do you have? \$\endgroup\$ – martianwars Dec 17 '16 at 20:33
  • \$\begingroup\$ mostly 16F628A from microchip, edit : and I just found a 16F877A \$\endgroup\$ – sliders_alpha Dec 17 '16 at 20:35
  • \$\begingroup\$ Oh I'm stupid, The audio line in't used, I just have to unplug the speakers, send audio, put a low pass filter to get an average and use a comparator to know when it needs to be triggered, that will do it for now. \$\endgroup\$ – sliders_alpha Dec 17 '16 at 20:42
3
\$\begingroup\$

Use a USB to Serial Port adapter with your microcontroller.

\$\endgroup\$
0
\$\begingroup\$

You might use a tone decoder (LM567 is typical) to detect that and only that frequency, and give a logic output. TI LM567 These devices can be driven from a microphone, and are insensitive to other sounds they might pick up, so your laptop could switch the target circuit wirelessly.

\$\endgroup\$

Not the answer you're looking for? Browse other questions tagged or ask your own question.