I am creating a project which is a sort of “music dead-drop” or audio/grafitti if you will, meant to be placed out into the public space.
Mechanics is that you plug in your device and you push a button (will try to get rid of that later) to record and store 10sec. There is a second female jack-input that plays back stored files randomly when headphones are plugged in (being triggered by a switch in the jackplug, going to an Arduino).
Using the audio pack, I have the recording and playback of stored files figured out. What I am stuck on is to avoid recording if someone is randomly pushing the button with nothing plugged in, or if playback have not started on the device.
There is a crack peak when device is first plugged in, then audio playback is on a much lower level.
Using the meter I do get a level value to work with, but I am struggling to disable the button, unless a certain value-range is present.
There is also a problem of getting a latched value of peaks and lows, to see how to map it out.
If anyone has a suggestion, solution or thoughts I would be eternally grateful. This is very important to me, and also a little last minute.
I am kind of nevvvv, but not a complete noob…
you can use with a ‘>’ value or Hysteresis node to check whether the audio is over a certain level and then use AND boolean to disable the button functionality. also use the smoothing of the Meter node or a Decay node after the Meter to not get flickering of the boolean value.
you can do that as well with a Meter followed by a Decay node, leave the Attack at a low level and set decay to a high value to get a slow peak value.
for logic tasks always use the Level output wich is in the range 0-1, not the dBs out.
also make sure you know what all the frequently used nodes are doing:
Decay to get a better look --> Hystersis --> AND… Hystersis alright… Seems almost too simple now, when not fighting broken arduino clones as well… Thank you very much tonfilm!