1

I'm making a project, a surveillance camera with audio. Live feed from my localhost webpage. the live camera part is now okay and working, my problem is the "intercom" part. I don't really have a sure idea if it will work, so I'm here to ask. Is it possible to put a speaker and mic with raspi so I can hear the audio from my camera. And for the speaker, so that I can speak through my mic in localhost and can hear from the raspberry pi. so it's like an Intercom. just think it's like the IP cctv that has audio. Please help me and guide me. Thank you.

PS. I'm using a raspi camera for my live footage so it doesn't include audio.

  • 1
    Welcome and nice to meet you. Ah, let me summarize you problem. You project is in two parts: (1) Rpi camera, but does not include audio, so a separate microphone is needed, and web server, completed OK, (2) Intercom part and you are not sure how to use Rpi (perhaps python) to interface with microphone (might need accompanying mini audio power amplifier) and loudspeaker. / to continue, ... – tlfong01 Aug 17 '20 at 06:01
  • 1
    I think the follow two references might help you getting started: (1) Rpi Intercom Microphone and Loudspeaker - rpi.org.forum 2018oct17: https://www.raspberrypi.org/forums/viewtopic.php?f=91&t=224976,

    (2) Rpi Python MAX4466/MAX9814 Microphone with Amplifier and MCP3008/PCM1802 Audio Analog to Digital Converter Module - RpiSE, 2012jan21: https://raspberrypi.stackexchange.com/questions/107778/how-to-use-rpi-python-to-control-pcm1802-24-bit-hifi-stereo-adc-and-max4466-micr. Please feel free to ask me newbie questions. Have a great project. Cheers.

    – tlfong01 Aug 17 '20 at 06:02
  • 1
    hello @tlfong01, thank you for your inputs but I have some clarrification. the connection of my speaker. I have read all the links. Can I use this instead? https://www.raspberrypi.org/forums/download/file.php?id=25665&sid=c16975bc550f2d23f5bcbf62a47a34a0 . – Johannes Remotigue Aug 17 '20 at 16:44
  • 1
    Hi #Johannes Remotigue, Thank you for your encouragement and feedback. About the the speaker connection: The link you mentioned is a USB sound card. You connect it to the Rpi USB connector, then it becomes a USB connected, external "sound card" to which you can connect (a) Microphone, (b) a speaker (system). This USB sound card is better than the Rpi's built in/internal limited function sound card, because Rpi built in/on board sound card has only the 3.5mm connector to connect a mono speaker, but no microphone. So you need the adapter to connect the mic and speaker(s). Also more HiFi. – tlfong01 Aug 18 '20 at 01:03
  • 1
    I'm sorry for asking too much. so If I'm going to use that USB external "sound card", like this https://shopee.ph/Vention-USB-Sound-Card-with-3.5mm-Stereo-and-Mic-Soundcard-Splitter-i.95237083.1581851159. Is there a need still to use the analog to digital converter module? – Johannes Remotigue Aug 18 '20 at 04:20
  • 1
    Ah, I am glad you asked. Actually I forgot to point out or remind other newbies reading my answer, that my second reference mentions two parts (a) Microphone with power amplifies (MAX4466/MAX9814), (b) ADC MCP3008, and PCM1802. The ADC recommendation is only for advanced hobbyists who wish to do real time processing. The mic with power amp is what you might like to try to learn something. Actually I am not too sure if you need to use the mic with power amp, which is useful in intercom setup which needs an amp at the front door side. / to continue, ... – tlfong01 Aug 18 '20 at 04:36
  • 1
    For your app, perhaps what you need is a cheap mic. Actually I recommend a cheap mic, the electrec type. Do not buy the many times more expensive HiFi dynamic/moving coil mic which is too weak power for the sound card. Ah I forgot to mention that your linked sound card is OK. PS, the MAX4466 mic with amp is flexible, because you can set the gain to low and high, to suit your app, like human voice too far away etc. – tlfong01 Aug 18 '20 at 04:39
  • 1
    Hello @tlfong01, thank you for your answers and helping me. I've got more questions please don't be angry :). So I have USB sound card with mic(I did not start yet and tried if it work or not). So I'm gonna ask, since the speaker and mic is not connected in GPiO pins, can I still be able to use them using python and run through the web? – Johannes Remotigue Aug 23 '20 at 15:53
  • Nice to meet you again. I am glad that you ask again. Your newbie questions actually help improving my answers. For example, your question of "My Rpi's build in sound card and 3.5mm connector can only connect to a speaker, what should I do if I want to use a microphone?" So you already read my answer. Of course you newbies get many questions but are too afraid to ask. Now you are the brave enough hero to ask newbie question so that those faint of heart newbies will no loner need to weep in the dark. Ah, thank you for reading my TLDR introduction. / to continue, ... – tlfong01 Aug 24 '20 at 01:08
  • Now let me come back to you question which I am summarizing below. "OK, so I bought the USB sound card and I am going to test it with my cheap mic and speakers. But now I begin to worry, my project will use a web server store surveillance camera data, and interact with the the guys in the security room or the officers in the police station. I also want to use python, but I know nothing about the scary GPIO pins and actually I don't want to learn or even touch any hardware, not to mention soldering ICs. / to continue, ... – tlfong01 Aug 24 '20 at 01:17
  • Sorry for my long windness. Now the short answer. Don't you worry. The USB sound card actually has nothing to do, or connected to the Rpi's internal sound card hardware. Long story short: as soon as you plug in the sound card to an USB port, Rpi should detect the sound card, and automatically start up the Rpi OS's sound card driver and you are ready to go (Sort of PC Win10's Plug and Play stuff). Thr nice thing is that the sound card driver gets you python commands,and process data in and out of the YSB sound card DIRECTLY, without any interaction with the GPIO guys. / to continue, ... – tlfong01 Aug 24 '20 at 01:24
  • In short, you are OK without any knowledge or skills in GPIO. Python with the help of all the free open source linux audio utilities should do all (well, almost all) what you want to do with your project. Have a great locking down project. Cheers. – tlfong01 Aug 24 '20 at 01:30
  • 1
    Thank you so much for your answers @tlfong01. Now I don't have anymore questions :D I am now ready to proceed :) – Johannes Remotigue Aug 26 '20 at 16:08
  • It is my pleasure. Best wishes and cheers. – tlfong01 Aug 27 '20 at 01:00

0 Answers0