# Detect audio of computer and send info to Arduino

**URL:** <https://discourse.processing.org/t/detect-audio-of-computer-and-send-info-to-arduino/14330>\
**Category:** Electronics (Arduino, etc.)\
**Created:** [September 30, 2019, 6:58pm UTC](https://discourse.processing.org/t/detect-audio-of-computer-and-send-info-to-arduino/14330 "2019-09-30T18:58:51Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![niconico](https://avatars.discourse-cdn.com/v4/letter/n/c4cdca/32.png) [@niconico](https://discourse.processing.org/u/niconico)\
**Post date:** [September 30, 2019, 6:58pm UTC](https://discourse.processing.org/t/detect-audio-of-computer-and-send-info-to-arduino/14330/1 "2019-09-30T18:58:51Z")

</div>

Hello,

I´m new with processing, I work with arduino 8 years and now I need processing for a Project

The project are very simple…

I need detect the audio of the computer and when the computer have sound activate a relay at the arduino

I read about the minim library, but I was lost…

Any idea? When the computer are playing audio the relay activate.

Thanks so much

---

<div class="post-metadata">

**Author:** ![glv](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/glv/32/18785_2.png) [@glv](https://discourse.processing.org/u/glv)\
**Post date:** [September 30, 2019, 10:39pm UTC](https://discourse.processing.org/t/detect-audio-of-computer-and-send-info-to-arduino/14330/2 "2019-09-30T22:39:57Z")

</div>

Lost is a good place to start finding your way.

Check out some of the tutorials:  
[https://processing.org/tutorials/](https://processing.org/tutorials/)

Processing can talk to Arduino with serial communication:  
[https://processing.org/reference/libraries/serial/index.html](https://processing.org/reference/libraries/serial/index.html)

Check out the examples that come with Processing.

When you add a library to processing there are also examples added.

🙂

---

<div class="post-metadata">

**Author:** ![kll](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/kll/32/964_2.png) [@kll](https://discourse.processing.org/u/kll)\
**Post date:** [October 1, 2019, 5:11am UTC](https://discourse.processing.org/t/detect-audio-of-computer-and-send-info-to-arduino/14330/3 "2019-10-01T05:11:45Z")

</div>

> [@niconico](#):
>
> detect the audio of the computer and when the computer have sound

actually i think that is the difficult part,

as long you use processing and its libraries ( sound / minim / beads … )  
to produce “noise” you can know that it is active / or louder as a limit … )

but your question could be  
how can processing know if " the computer " plays sound,  
for that you would need to be able to read back the system-sound amplitude??

[Doing an FFT on system audio currently playing with Minim - Processing Forum](https://forum.processing.org/one/topic/doing-an-fft-on-system-audio-currently-playing-with-minim.html) like here?

---

<div class="post-metadata">

**Author:** ![niconico](https://avatars.discourse-cdn.com/v4/letter/n/c4cdca/32.png) [@niconico](https://discourse.processing.org/u/niconico)\
**Post date:** [October 8, 2019, 6:19am UTC](https://discourse.processing.org/t/detect-audio-of-computer-and-send-info-to-arduino/14330/4 "2019-10-08T06:19:00Z")

</div>

Thanks so much for the info, I´ll work it, and when I have results…reply

Sorry for the delay but I´m out, holidays 😛
