Playing a Fixed Frequency Sound, Python 3




I’m having trouble playing a fixed frequency sound using Python 3.

I’ve been trying to install pyaudio 0.2.9 but I can’t figure out what is going on.
I tried using the following command, as suggested by another post.

sudo easy_install pyaudio

In the terminal, it gives me this message.

Searching for pyaudio
Best match: PyAudio       
Processing PyAudio-0.2.9.tar.gz
Writing /tmp/easy_install-H_iAbk/PyAudio-0.2.9/setup.cfg
Running PyAudio-0.2.9/ -q bdist_egg --dist-dir /tmp/easy_install-H_iAbk/PyAudio-0.2.9/egg-dist-tmp-XC7x10
warning: no files found matching '*.c' under directory 'test'
src/_portaudiomodule.c:29:23: fatal error: portaudio.h: No such file or directory
#include "portaudio.h"

Judging from this, it looks like it’s able to find pyaudio but something is going wrong when I try to install it.
I can’t figure out what I’m doing wrong.



Maybe you can try installing with pip?

sudo pip install PyAudio


That didn’t work either.