Sound Input Level meter
Sound Input Level meter
A simple visualisation for the sound input level (e.g. microphone input, etc). Good to check whether your input is working or in the correct range.
Note: please close this before you start the actual application (recording, voip, or whatever) as the script uses arecord, and arecord blocks other applications from doing their work.
EDIT: two packages now provided, one for 32-bit puppies and one for 64-bit puppies (fatdog).
EDIT: updated to version 1.1, remove the stereo files - thanks for OscarTalks for reporting the bug.
Note: please close this before you start the actual application (recording, voip, or whatever) as the script uses arecord, and arecord blocks other applications from doing their work.
EDIT: two packages now provided, one for 32-bit puppies and one for 64-bit puppies (fatdog).
EDIT: updated to version 1.1, remove the stereo files - thanks for OscarTalks for reporting the bug.
- Attachments
-
- alsa-input-level-1.1-x86_64.pet
- package for 64-bit puppies
- (27.15 KiB) Downloaded 683 times
-
- alsa-input-level-1.1.pet
- Updated package for 32-bit puppies
- (25.16 KiB) Downloaded 846 times
Last edited by jamesbond on Tue 17 Apr 2012, 00:35, edited 3 times in total.
Fatdog64 forum links: [url=http://murga-linux.com/puppy/viewtopic.php?t=117546]Latest version[/url] | [url=https://cutt.ly/ke8sn5H]Contributed packages[/url] | [url=https://cutt.ly/se8scrb]ISO builder[/url]
If you can't be bothered with stdbuf and GUI, just open terminal and do this:
There is your input level meter. Of course, as above, you need to stop this before starting your actual application.
Code: Select all
arecord -vv /dev/null
Fatdog64 forum links: [url=http://murga-linux.com/puppy/viewtopic.php?t=117546]Latest version[/url] | [url=https://cutt.ly/ke8sn5H]Contributed packages[/url] | [url=https://cutt.ly/se8scrb]ISO builder[/url]
-
- Posts: 452
- Joined: Thu 20 Mar 2008, 01:48
thanks... I do realize that during recording video using tv-tuner i have to use :
even with my script, it is "just ok" quality. do you have any suggestion ?
thanks
other wise the sound would be terrible.amixer set Capture 2%
v4lctl volume mute off
ffmpeg -y -f oss -i /dev/dsp -itsoffset 1 -acodec pcm_s16le -f video4linux2 -s 640x480 -r 15 -qscale 5 -vc 1 -tvstd PAL-DK -i /dev/video0 -sws_flags bicubic -ss 00:00:03 -t 00:00:15 -f avi test.avi
even with my script, it is "just ok" quality. do you have any suggestion ?
thanks
Cluster-Pup v.2-Puppy Beowulf Cluster
[url]http://www.murga-linux.com/puppy/viewtopic.php?p=499199#499199[/url]
[url]http://www.murga-linux.com/puppy/viewtopic.php?p=499199#499199[/url]
- OscarTalks
- Posts: 2196
- Joined: Mon 06 Feb 2012, 00:58
- Location: London, England
Hello JamesBond,
Thanks for that. A useful little tool. A lot of people seem to report problems with sound input and this is a nice way of providing an indication of what (if anything) is happening.
By the way, is there any chance that you might be able to offer help and advice regarding PSIP at some stage please? Cheers!
Thanks for that. A useful little tool. A lot of people seem to report problems with sound input and this is a nice way of providing an indication of what (if anything) is happening.
By the way, is there any chance that you might be able to offer help and advice regarding PSIP at some stage please? Cheers!
Oscar in England
@Master_Wrong, I can't help with that, I don't have tvtuner myself. But I suggest you try to capture from alsa (-f alsa) instead of from OSS (-f oss) if your tvtuner supports it.
@OscarTalks, yes, I'd like to help but I'm a bit busy right now. I will see what I can do. Haven't been in the PSIP forum for a few months
@OscarTalks, yes, I'd like to help but I'm a bit busy right now. I will see what I can do. Haven't been in the PSIP forum for a few months
Fatdog64 forum links: [url=http://murga-linux.com/puppy/viewtopic.php?t=117546]Latest version[/url] | [url=https://cutt.ly/ke8sn5H]Contributed packages[/url] | [url=https://cutt.ly/se8scrb]ISO builder[/url]
- OscarTalks
- Posts: 2196
- Joined: Mon 06 Feb 2012, 00:58
- Location: London, England
Installed your sound input meter in Saluki 019. Is it supposed to be saving the audio as a .wav file called "stereo" in root? Mine did. Deleted it of course.
My PSIP disappeared completely from the menu as well which was strange. Had to uninstall and re-install PSIP in PPM. Just wondering if my installing this tool had anything to do with it as I hadn't done much else. EDIT, just noticed, looks like my Precord may have gone for a burton as well. Uninstalled and re-installed to get it back.
My PSIP disappeared completely from the menu as well which was strange. Had to uninstall and re-install PSIP in PPM. Just wondering if my installing this tool had anything to do with it as I hadn't done much else. EDIT, just noticed, looks like my Precord may have gone for a burton as well. Uninstalled and re-installed to get it back.
Oscar in England
No, it's not supposed to do that. My stupidity of course. FixedOscarTalks wrote:Installed your sound input meter in Saluki 019. Is it supposed to be saving the audio as a .wav file called "stereo" in root? Mine did. Deleted it of course.
I haven't tried it on Saluki yet, but it isn't supposed to do that. It's just a simple one-line script file. I used Fatdog64 to package the pet, perhaps it's a bit too old and the PET format no longer works for newer puppies. Anyway, you can just get the PET, extract it manually (tar -xvf alsa-input-level.pet) and copy the files to /usr/bin/ (and the desktop files to /usr/share/applications).My PSIP disappeared completely from the menu as well which was strange. Had to uninstall and re-install PSIP in PPM. Just wondering if my installing this tool had anything to do with it as I hadn't done much else. EDIT, just noticed, looks like my Precord may have gone for a burton as well. Uninstalled and re-installed to get it back.
cheers!
Fatdog64 forum links: [url=http://murga-linux.com/puppy/viewtopic.php?t=117546]Latest version[/url] | [url=https://cutt.ly/ke8sn5H]Contributed packages[/url] | [url=https://cutt.ly/se8scrb]ISO builder[/url]
rien, rien de rien. niet audio
Sound Input Level Meter, alsamixer, retrovol, precord, i give up.
NO, succes with Sound Input Level Meter.
But my voice is weak, very weak (up to 5% only...)
NO, succes with Sound Input Level Meter.
But my voice is weak, very weak (up to 5% only...)
Last edited by Pelo on Fri 29 Aug 2014, 17:27, edited 1 time in total.
Re: rien, rien de rien. niet audio
Pelo - can you try a different machine? Surely there must be something funny with your hardware???Pelo wrote:Sound Input Level Meter, alsamixer, retrovol, precord, i give up.
Can you plug in a usb soundcard ($4 on ebay) and see if you have different results?
@jamesbond - I see "Alsa input level" in my Multimedia menu but if I click it my system hangs (except the mouse which still moves). I have to use CtrlAltBkspace then xwin to get going again. Have you seen such a symptom?? (This is on Slacko 5.3)
I found the best way to run this was to create a script as follows:
Code: Select all
#!/bin/bash
urxvt -e arecord -vv /dev/null &
Thank you!
.
Re: rien, rien de rien. niet audio
As forum member SFR discovered, you should avoid using that command because it causes the special file /dev/null to be overwritten with a text file of the same name, which can cause serious system errors for some other apps. A workable way of using arecord VU meter is described in the following link:greengeek wrote:
I found the best way to run this was to create a script as follows:When I click that it works well.Code: Select all
#!/bin/bash urxvt -e arecord -vv /dev/null &
Thank you!
.
http://www.murga-linux.com/puppy/viewto ... 738#784147
Note that Bacon Recorder VU meter code has the same error overwriting /dev/null, the VU meter code used in both Precord and pAVrecord, however, already contains the above fix.
William
github mcewanw
Haha, a revival of 2 year old thread - finally the original poster is still around
@mcewann - thank you, you're right. I found a simpler fix, though, at least for the version of arecord that I have:
@greengeek - make sure you have "stdbuf". Here's the fixed version of alsa-input-level GUI:
If you don't have stdbuf then this won't work.
@Pelo - make sure your remove $HOME/.asoundrc (that would be removing /root/.asoundrc, /root/spot/.asoundrc) and also /etc/asoundrc. If you can post the content of your "/proc/asound/cards" - that would help too.
@mcewann - thank you, you're right. I found a simpler fix, though, at least for the version of arecord that I have:
Code: Select all
arecord -vv > /dev/null
Code: Select all
#!/bin/sh
exec arecord -vvv 2>&1 > /dev/null | stdbuf -o0 sed '/%$/ !d' | Xdialog --title "Sound Input Level" --progress "Close this when done, before starting recording." 0 0
@Pelo - make sure your remove $HOME/.asoundrc (that would be removing /root/.asoundrc, /root/spot/.asoundrc) and also /etc/asoundrc. If you can post the content of your "/proc/asound/cards" - that would help too.
Fatdog64 forum links: [url=http://murga-linux.com/puppy/viewtopic.php?t=117546]Latest version[/url] | [url=https://cutt.ly/ke8sn5H]Contributed packages[/url] | [url=https://cutt.ly/se8scrb]ISO builder[/url]
Yes, we tried that too, but that only works for some versions of arecord. As far as I recall that code worked in recent Slacko but not in Precise. I'll try it again sometime to double check though. The solution adopted at present at least, whilst a bit complicated is a workaround that works everywhere so far.jamesbond wrote: @mcewann - thank you, you're right. I found a simpler fix, though, at least for the version of arecord that I have:Code: Select all
arecord -vv > /dev/null
William
EDIT: This is the note I took from previous conversations about this. The additional issue is that vu-meter output gets mixed with general data in alsa version < 1.0.26 so gets discarded altogether when construct >/dev/null is used:
However in Slacko it's perfectly fine.
1.0.25 (Precise/DDog) vs. 1.0.26 (Slacko) would make such a difference..?
Perhaps the relevant change (though it says only 'aplay') was:
Quote:
aplay: print vu-meter to stderr, not stdout
Src.: http://www.alsa-project.org/main/index. ... 25_v1.0.26
If that's the case, then in Alsa < 1.0.26 vu-meter gets mixed with actual data (at least if there's no output file specified) and that's how it looks like in terminal, and most likely that's why >/dev/null discards both elements.
Last edited by mcewanw on Fri 29 Aug 2014, 10:49, edited 1 time in total.
github mcewanw
Whilst not the same thread, its actually a revival of an over six year old topic ;-)jamesbond wrote:Haha, a revival of 2 year old thread - finally the original poster is still around :lol:
http://murga-linux.com/puppy/viewtopic. ... 193#373193
github mcewanw
Shouldn't this be a simple part of WOOFCE?
@Jamesbond made this several years ago when several of us were struggling with identifying sound in our desktop use. This has been a great tool and is practical.
Every PUP should come with this built into its Menu as many/most in the community have progressed to a point where we need this as a tool insuring the system can see audio/mic input. I think we all understand the value of this, hence it was presented to us by @Jamesbond.
Couple of things:
Users/developers shouldn't have to hunt for this thread for something that is so simple and widespread.
Questions
Cheers!
Every PUP should come with this built into its Menu as many/most in the community have progressed to a point where we need this as a tool insuring the system can see audio/mic input. I think we all understand the value of this, hence it was presented to us by @Jamesbond.
Couple of things:
- Its a Puppy exclusive script
- It has excellent value in its presence
- It carries so few instructions that it ISO weight is too small to measure
- It has NO system performance impact as it is simple a test tool
- Every PC/Laptop/Netbook/etc comes with Microphone ports
Users/developers shouldn't have to hunt for this thread for something that is so simple and widespread.
Questions
- How does something like this get presented and included in WOOFCE such that it results in all PUPs?
- Does this tool need amending for ALSA or Retrovol or ... version level(s).
Cheers!
eh men, i was searching solutions !
Sound input Level meter : i check it on an audio working system, in My Virtual machine,
When i had seen a working system, perhaps i will see what is wrong in the non-working one. English is not easy to explain things.
Ah OK, it's a vu-metre mesurant le volume of sound... OK.
The vocabulary is so complicated for audio, everything is code, and furthermore english . i understand pcm means computer microphone
Don't Mind, Sound Input Level Meter works. but this tool will be mine only when I get sound.
The fact : my Puppy has audio in Virtual machine, not in normal use. That means that the few drivers OF VM succeed where alsa tools failed.
Only an icon size can stop all the process.
When i had seen a working system, perhaps i will see what is wrong in the non-working one. English is not easy to explain things.
Ah OK, it's a vu-metre mesurant le volume of sound... OK.
The vocabulary is so complicated for audio, everything is code, and furthermore english . i understand pcm means computer microphone
Don't Mind, Sound Input Level Meter works. but this tool will be mine only when I get sound.
The fact : my Puppy has audio in Virtual machine, not in normal use. That means that the few drivers OF VM succeed where alsa tools failed.
Only an icon size can stop all the process.
I appear to not have stdbuf (testing at the moment on a slacko 5.6 derivative). Is this something that I really should have? If so can you recommend the best way to get it?jamesbond wrote: make sure you have "stdbuf". Here's the fixed version of alsa-input-level GUI:If you don't have stdbuf then this won't work.Code: Select all
#!/bin/sh exec arecord -vvv 2>&1 > /dev/null | stdbuf -o0 sed '/%$/ !d' | Xdialog --title "Sound Input Level" --progress "Close this when done, before starting recording." 0 0
I'm currently testing using williams updated vu_tmp method from the other thread he referenced and it seems to be working fine using the following script:
Code: Select all
#!/bin/bash
urxvt -e arecord -vv /tmp/vu_tmp & { sleep 1; rm -f /tmp/vu_tmp; }
stdbuf is part of GNU coreutils package. (I think) I also package it in the pet package on first post. William method works, and may work better if you need compatibility with older version of arecord.
Fatdog64 forum links: [url=http://murga-linux.com/puppy/viewtopic.php?t=117546]Latest version[/url] | [url=https://cutt.ly/ke8sn5H]Contributed packages[/url] | [url=https://cutt.ly/se8scrb]ISO builder[/url]
Credit where credit is due. It is actually SFR's method, which I then implemented in Precord.jamesbond wrote:stdbuf is part of GNU coreutils package. (I think) I also package it in the pet package on first post. William method works, and may work better if you need compatibility with older version of arecord.
William
github mcewanw