I'm happy to share my code and the project is attached.
I don't plan to develop this project any further because even in its current unsophisticated form it achieves my objective.
To explain a little more, I am involved in livestreaming game video from our local basketball competition to YouTube, but music is played during breaks in play and with YouTube screening all content, they may block the video if copyrighted music content is detected. Therefore I sample the music output from the Court Commentator's PA mixer so that when music is played the B4J app sends an appropriate code to my streaming app (vMix) via UDP to mute the audio. When the music is not playing, the audio is unmuted so viewers of the streaming video can can hear the venue ambient sound via the video camera audio channel. Here's a link to an example on YouTube:
Incidentally the superimposed scoreboard on that video is also a B4J app which consumes data input via USB from an Arduino based scoreboard interface box I built and coded using B4R. I can update some elements of the B4J display remotely via WiFi using an Android app developed using B4A.
It sounds like your project is much more complex given you need to be frequency selective in determining levels. I'd not know where to start with concept for that projects . . .