# Error in when trying to use minim BeatDetect

**URL:** https://discourse.processing.org/t/error-in-when-trying-to-use-minim-beatdetect/9317
**Category:** Libraries
**Created:** [March 15, 2019, 2:13am UTC](https://discourse.processing.org/t/error-in-when-trying-to-use-minim-beatdetect/9317 "2019-03-15T02:13:47Z")
**Posts on this page:** 5
**Page:** 1

<div class="post-metadata">

### Author: ![SoundGuy](https://avatars.discourse-cdn.com/v4/letter/s/54ee81/32.png) [@SoundGuy](https://discourse.processing.org/u/SoundGuy)
#### Post date: [March 15, 2019, 2:13am UTC](https://discourse.processing.org/t/error-in-when-trying-to-use-minim-beatdetect/9317/1 "2019-03-15T02:13:47Z")

</div>

I’m trying to use the code to detect beats in a song. I looked a Minim.BeatDetect class that i found in several examples:

> **[Processing 2.x and 3.x Forum](https://forum.processing.org/two/discussion/10748/how-to-make-a-music-visualization-using-beat-detect-and-random-lines)**
>
> Processing is an electronic sketchbook, a language and a worldwide community. This is its forum.

but when i try this sketch it gives me an error in the detect() function call:  
The function detect(AudioBuffer) does not exist.

I’m a little new to Processing, so i hope i’m not doing anything wrong with the way i added the library(i went to library manager and just looked for minim and adeed it)

what am i doing wrong and how can i solve this?

---

<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: [March 15, 2019, 2:59am UTC](https://discourse.processing.org/t/error-in-when-trying-to-use-minim-beatdetect/9317/2 "2019-03-15T02:59:38Z")

</div>

the example code  
[how to make a music visualization using beat detect and random lines - Processing 2.x and 3.x Forum](https://forum.processing.org/two/discussion/comment/41777/#Comment_41777) ,  
works ( on win7 64bit / processing 3.5.3. )

but i do see at console

> ==== JavaSound Minim Error ====  
> ==== Don’t know the ID3 code WXXX

but when you have doubts about install library,  
-a- need restart processing  
-b- you must start with a example from that library…

 ![SNAG-0010](https://canada1.discourse-cdn.com/flex036/uploads/processingfoundation1/original/2X/9/9ffc58b6033465567b2491c2acb9664807405056.jpeg)

++ as this verifies that the library is in the correct path  
++ and you start a example with good loading of file…

---

<div class="post-metadata">

### Author: ![jeremydouglass](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/jeremydouglass/32/20_2.png) [@jeremydouglass](https://discourse.processing.org/u/jeremydouglass)
#### Post date: [March 16, 2019, 11:59pm UTC](https://discourse.processing.org/t/error-in-when-trying-to-use-minim-beatdetect/9317/3 "2019-03-16T23:59:19Z")

</div>

Did @kll answer your question?

It looks to me like you loaded the latest library, but copied an old example from an old library off the forum. The latest beat detection examples (shown in the screenshot above) are:

- PDE \> File \> Examples \> Contributed Libraries \> minim \> Analysis
  - FrequencyEnergyBeatDetection
  - SoundEnergyBeatDetection

---

<div class="post-metadata">

### Author: ![SoundGuy](https://avatars.discourse-cdn.com/v4/letter/s/54ee81/32.png) [@SoundGuy](https://discourse.processing.org/u/SoundGuy)
#### Post date: [March 17, 2019, 7:51pm UTC](https://discourse.processing.org/t/error-in-when-trying-to-use-minim-beatdetect/9317/4 "2019-03-17T19:51:26Z")

</div>

this is so weird. the example works. I if copy entire code of the example to my file (beatDetect.pde) it gives me the same error on the same line.  
not sure I understand why.

I saved the example on another folder and then that one works.

---

<div class="post-metadata">

### Author: ![jeremydouglass](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/jeremydouglass/32/20_2.png) [@jeremydouglass](https://discourse.processing.org/u/jeremydouglass)
#### Post date: [March 17, 2019, 7:57pm UTC](https://discourse.processing.org/t/error-in-when-trying-to-use-minim-beatdetect/9317/5 "2019-03-17T19:57:50Z")

</div>

Strange. Maybe you have a tab or a subfolder in the broken sketch with a bad copy of the library jar, or with invalid code causing the error? Start from the clean copy – and good luck!
