Introduction: FMOD Running on Raspberry Pi
The instructions here seem to be outdated
Here’s what I had to do. Note that steps 4-6 may not be necessary
- Make sure audio works on your raspberry pi
- You may be asked to sign in. As long as you are not planning to sell the product, you can use FMOD for free. Just create a profile, sign in, then go back to the download page to download your package
- To build the executable we’ll use the provided makefile. Makefiles are effectively a set of instructions on how to build and link your files to create your executable.
- Run“Cd make” // to change directory into the make folder under /fmodstudioapi10813linux/api/lowlevel/examples/make
- “make --file play_sound.makefile CONFIG=Debug CPU=armhf”
- My raspberry pi uses armv7+ . If your pi is armv6, your CPU flag will be “arm”
- NOTE: when I originally did this I got the error: “error while loading shared libraries: libfmod.so.8: cannot open shared object file: No such file or directory” and it was because I originally thought my pi was armv6 so I ran “make --file play_sound.makefile CONFIG=Debug CPU=arm” which was incorrect for me. Once I changed the CPU flag to the correct one this error went away
- If this fails with the following error “ /usr/include/arm-linux-gnueabihf/gnu/stubs.h:7:29: fatal error: gnu/stubs-soft.h: No such file or directory # include ”, you may need to change your makefile such that “-mfloat-abi=softfp” becomes “-mfloat-abi=hard”.
- Then re-run the instructions provided in 7.a.
- num Drivers = 10 | mydriver = 0
- sound driver 0, driver name pulse
- sound driver 1, driver name sysdefault:CARD=ALSA
- sound driver 2, driver name dmix:CARD=ALSA,DEV=0
- sound driver 3, driver name dmix:CARD=ALSA,DEV=1
- sound driver 4, driver name dsnoop:CARD=ALSA,DEV=0
- sound driver 5, driver name dsnoop:CARD=ALSA,DEV=1
- sound driver 6, driver name hw:CARD=ALSA,DEV=0
- sound driver 7, driver name hw:CARD=ALSA,DEV=1
- sound driver 8, driver name plughw:CARD=ALSA,DEV=0
- sound driver 9, driver name plughw:CARD=ALSA,DEV=1
We have a be nice policy.
Please be positive and constructive.