Precord0.9.5 audio recorder

Audio editors, music players, video players, burning software, etc.
Post Reply
Message
Author
mcewanw
Posts: 3169
Joined: Thu 16 Aug 2007, 10:48
Contact:

Precord0.9.5 audio recorder

#1 Post by mcewanw »

2018/06/05 (YMD): Precord now uses gtkwialog [-b] for its GUI and so can now be used on systems that use dash (e.g. Debian and Ubuntu), ash (e.g. Slitaz), or bash (e.g. Puppy Linux) as their underlying system shells'

DOWNLOAD: deb package suitable for Puppy or Dogs or these other systems is currently attached to this post.

Current version 9.0.5, depends on gtkwialog being installed. Note that gtkwialog is a drop-in replacement for gtkdialog in that it contains full current gtkdialog functionality but has additional functionality that allows it to be used when either dash, ash, or bash are used as the system shell.

You do not therefore need both gtkwialog and legacy gtkdialog on your system but can instead simply make gtkdialog a symbolic link to newer gtkwialog (USUAL DISCLAIMERS APPLY: AT YOUR OWN RISK, but gtkwialog has proved stable in all tests thus far).

You can currently find a 32bit and 64bit downloads for gtkwialog (compiled on XenialDog but fine also for Bionic) at foot of the following post:

http://www.murga-linux.com/puppy/viewto ... 434#993434

There is a older 9.0.3 version of Precord that uses legacy gtkdialog (but will not, for example, work on dash or ash systems) in Puppy's repositories.
------------------

Apparently, JMW menu is 'no longer' displaying the mini-record.xpm icon included with Precord version 9.0.3 (which was apparently actually a png) so the dotpet of Precord BarryK has placed at ibiblio etc repositories has that icon removed. Barry also didn't like a hidden file appearing inside /etc/precord (which was admittedly an old mistake I made), so changed a single line in the code to remove the leading dot. If anyone else having trouble with these issues you can find Barry's slightly modified Precord version via below link (using version number 9.0.3-1 with link to its ibiblio pet repo location). Aside from that one code line change (and icon removed from the dotpet) everything else is identical:

http://www.murga-linux.com/puppy/viewto ... 283#978283

NOTE WELL: Please remember to delete your old ~/.precord config directory before installing this latest version.

If precord ever fails to start, its config file is probably corrupted so simply delete your old /root/.precord config directory and precord will automatically rebuild it the next time it is re-started. Its config file is not known to become corrupted in normal use though.

Precord has the advantage over, for example, mhWaveEdit, in that it records straight to mp3, wav or ogg, so doesn't need to use the hard disc for temporary storage of huge intermediate files.

It depends on arecord and lame for recording, and ffmpeg and aplay for playback; these are all standard core apps in Puppy

For vorbis ogg Precord uses oggenc for recording if it is available, otherwise it uses ffmpeg.

As well as having a GUI interface, Precord can also be used from the commandline. It reads commandline args of the form:

[action][filename][duration] via stdin (e.g. pipe).

For example

Code: Select all

precord [with no args starts GUI version]

precord  rec  /mnt/home  anything.mp3 10 [records without GUI; assumes mp3 previously selected in precord config GUI]

or via pipe:

echo  rec  /mnt/somewhere  testrec.ogg  25 | precord -
[assumes ogg previously selected in precord config GUI]

precord  play  /root  out.mp3 [plays without GUI]

echo  play  /mnt/sdb1  out.mp3 5 | precord -
[also plays without GUI; here using duration of 5 seconds]

If no outfile or duration parameter is supplied, precord uses previous configuration as defaults.

precord quit
does what you'd expect...

precord --help
for commandline usage
mcewanw
Attachments
precord_9.0.5_all.deb.tar
Just remove the dummy tar before installing
(10.08 KiB) Downloaded 418 times
Last edited by mcewanw on Sat 09 Jun 2018, 04:28, edited 204 times in total.

mcewanw
Posts: 3169
Joined: Thu 16 Aug 2007, 10:48
Contact:

If Precord fails to start or your mic doesn't work

#2 Post by mcewanw »

EDIT: You can also record from 01micko's pupRadio app
http://www.murga-linux.com/puppy/viewto ... 420#371420
More details on setting up alsamixer for that use in the later post:

http://www.murga-linux.com/puppy/viewto ... 492#371492


EDIT: For something more definitive (which says how to use Mic control in alsamixer) see here:

http://alsa.opensrc.org/index.php/Record_from_mic

If you have a USB mic, the following link might help:

http://wiki.audacityteam.org/index.php? ... c_on_Linux

If the config file for Precord (/root/.precordrc) gets corrupted somehow, Precord won't be able to start. EDIT: FIXED in version 1.0.1 upwards: the program now autocleans its config file on the next run if it found an error (i.e. if it doesn't start the first time because of a corrupted config file, it will start fine next time your try running it).
-------------------------

If using a microphone and it's not working, you can open up alsamixer from the Config GUI of precord by clicking on the MIX button. To adjust the alsamixer controls to get your sound basically going:

Move to the different volume controls (Master, Master M, and PCM) using the left/right cursor keys and use the up/down cursor keys turn up these volume controls to maximum.

Use "Mic Sel" to select the Microphone you are using (Mic1 internal; Mic2 external).

You might need "Mic Boost" (press M key to activate), which provides extra gain from your microphone.

(I suggest NOT USING the control marked simply "Mic"; on my system at least, that one just messes things up with lots of howling feedback...)

You should also try moving to the control marked Capture, press space bar to select, and turn it right up using the cursor up key.

Occasionally, alsa seems to get screwed up and I've had to reboot after playing with alsamixer controls (nothing to do with precord though, which works fine - just alsa generally), but usually things go fine (I've never taken time to discover the combination of settings that have worked best I'm afraid).

What I've found isn't good on my system is to use the control marked simply "Mic" whilst recording: that just creates horrible feedback whining noise in the background. i.e. I suggest therefore that you first leave that particular control de-activated; key M activates it (a toggle ON/OFF effect), so don't do that, or turn up its capture volume either...

i.e. As an initial attempt to get your mike working, just try sticking to Master, Master M, Mic select, Mic Boost (M to toggle activate), and plain "Capture" (space bar to toggle activate capture).

Sometimes entering the following two commands in a console gets your mic going if alsamixer isn't doing the job...:

Code: Select all

amixer set 'Mic Input',0 on
amixer set 'Mic',0 cap on
Last edited by mcewanw on Sun 13 Dec 2009, 14:07, edited 5 times in total.
github mcewanw

User avatar
Flash
Official Dog Handler
Posts: 13071
Joined: Wed 04 May 2005, 16:04
Location: Arizona USA

#3 Post by Flash »

I played around with Precord tonight for a bit. It's easy to use and seems well-behaved. That is, it did what I expected and didn't do anything I didn't expect. I tried running

Code: Select all

arecord -V mono
in rxvt for a VU meter (see here for details) while Precord was running. Arecord has the unfortunate habit of beeping the computer's beeper when the input level clips, and the beeps are picked up by the microphone. After a while, arecord seemed to cause Precord to not record at all. Ah, well, it's still useful for setting levels before you record.

mcewanw
Posts: 3169
Joined: Thu 16 Aug 2007, 10:48
Contact:

version 1.0.1 uploaded

#4 Post by mcewanw »

version 1.0.1 uploaded (attached to first post)

fixes error with pause function and auto cleans its config file (if it ever doesn't start, just try running it again and it should have fixed its config file automatically back to the default).

@Flash:

I tried,

arecord -V mono

My 1024x768 screen does not allow the rxvt console to be stretched out wide enough, though I could see the percentage figures which also indicated the recording levels. I could add a button to the Config menu of precord I suppose to run arecord -V mono in its own rxvt, if you like.
Pity I don't know how to make the rxvt fonts tiny enough that it wouldn't need stretched so much - I know how to enlarge the fonts, but haven't tried making them tiny...
github mcewanw

mcewanw
Posts: 3169
Joined: Thu 16 Aug 2007, 10:48
Contact:

version 1.0.2 uploaded with VU for setting up sound

#5 Post by mcewanw »

version 1.0.2 uploaded with VU for setting up sound

I used

arecord -vvv

in preference to

arecord -V mono

because I wanted a dynamically changing VU graph.

@Flash: At the command line you might also like to try:

Code: Select all

arecord -V mono /dev/null 2>/dev/null

or 

arecord -vvv /dev/null 2>/dev/null
Note that you cannot record (as far as I am aware) whilst the VU meter is running (but you can playback!...).
You can also start up the alsamixer at the same time (MIX button) and, if you wish, activate the single bar MIN GUI of Precord (or switch back and forth between single bar GUI and config GUI, whilst one or both of these are running in their rxvt windows.
github mcewanw

User avatar
zigbert
Posts: 6621
Joined: Wed 29 Mar 2006, 18:13
Location: Valåmoen, Norway
Contact:

#6 Post by zigbert »

mcewanw
What I like about Precord is that it is built around ffmpeg/arecord and not libsnd.

User avatar
01micko
Posts: 8741
Joined: Sat 11 Oct 2008, 13:39
Location: qld
Contact:

#7 Post by 01micko »

Hi mcewanw

Thanks for this cool little app. It also does a decent job of recording stdin from whatever is going through the sound card.

I just wrote a little radio streaming app that includes a recording feature and I was having all sorts of problems trying to get it right but now I don't have to at all. My app can call 'precord' and the user can set up alsamixer (setting up alsamixer is the key) and save in whatever quality they want. Neat. Of course this makes recording optional in my radio app but that's fine. I will put a link in my app to this thread.

Thanks again.

Cheers
Puppy Linux Blog - contact me for access

User avatar
mikeb
Posts: 11297
Joined: Thu 23 Nov 2006, 13:56

#8 Post by mikeb »

Looks like you caught barry's eye...check his blog if you haven't already :)

regards

mike

mcewanw
Posts: 3169
Joined: Thu 16 Aug 2007, 10:48
Contact:

Version 1.0.3 uploaded

#9 Post by mcewanw »

precord-1.0.3.pet uploaded (see first post in thread)

# Version 1.0.3
# Added Record and Play file entry boxes, and date-stamped file handling.

Now you can easily play back one file, whilst recording another (headphones are best when doing that...).

Note that though precord is designed to record mp3 files, it will play back many formats.

I only have a very slow dialup connection, so haven't tried this, but I imagine precord could probably play back (some/a few) mp3 streams as well (try entering a URL of such a stream as the file to play - let me know if it works...).

EDIT: Oh well, I had no success with streaming mp3 playing in precord, but 01micko's wee app works well for that (looking forward to him creating a universal version for different players etc.

The date stamp record is pretty handy for making lots of quick recordings. The playback window makes a best effort to track the date-stamped file being recorded, but it occasionally gets fooled (that is inevitable, the date stamp is at second resolution...) - not that that matters - the recording goes fine.

The dotpet is much the same size (tiny: 3.8kB)
github mcewanw

mcewanw
Posts: 3169
Joined: Thu 16 Aug 2007, 10:48
Contact:

Using Precord with 01micko's pupRadio

#10 Post by mcewanw »

Just tried 01micko's pupRadio

http://www.murga-linux.com/puppy/viewto ... 420#371420

which includes the option to Record the played audio streams via Precord. I tested pupRadio in conjunction with my newly uploaded Precord version 1.0.3.

The combination works really well (if you are lucky! Alsa seems to be a temperamental beast...) You can use the VU meter of Precord when setting up Alsa mixer and pupRadio volume 'PRIOR' to recording - but, alas, you the VU meter can't be allowed to run whilst recording. I haven't been successful (as yet) getting any VU meter to work whilst recording - maybe one day! :-)

As 01micko says, the trick is to set up alsamixer correctly. You can do that from within Precord (in its config GUI press the MIX button). I found that selecting Capture device "Mix" (instead of "Mic") worked.

EDIT: On my admittedly slow system the recording of pupRadio seemed to loose lots of chunks of sound though - but its hard to tell when the dialup connection continually results in pauses due to buffering needs. RE-EDIT...! Worked great when I either reduced the bit rate with cbr, but best on my system was to use Variable Bit Rate mode, vbr (I used stereo and 320k vbr in my test, with great results, though I'm sure lower bit rate vbr would be fine)

Be careful not to leave Mic as the Capture device or you may think things are working when all you are then doing is recording your speaker output through your microphone!!! Not so good! :-)

But using "Mix" (rather than "Mic") for alsamixer Capture seemed to be the way to do it as far as I can see).

I included some tips on setting up alsamixer (albeit primarily for Microphone use) here
github mcewanw

mcewanw
Posts: 3169
Joined: Thu 16 Aug 2007, 10:48
Contact:

Version 1.0.4 uploaded to fix opening bug

#11 Post by mcewanw »

Version 1.0.4 uploaded.

FIxes the config file corruption bug caused by not closing app with the Quit button. Should never start up with a blank file panel now (so works better with pupRadio now too).
github mcewanw

mcewanw
Posts: 3169
Joined: Thu 16 Aug 2007, 10:48
Contact:

added the precord 1.0.4 bugfix to the older precord 1.0.2

#12 Post by mcewanw »

Though I recommend the new version 1.0.4 I have re-uploaded version 1.0.2 with the bugfix from 1.0.4 incorporated. I accordingly renamed that old version 1.0.2s

[the 1.0.4 and 1.0.2s bugfix ends the problem of precord sometimes starting up with a blank file window and then having to be restarted]
github mcewanw

User avatar
Flash
Official Dog Handler
Posts: 13071
Joined: Wed 04 May 2005, 16:04
Location: Arizona USA

#13 Post by Flash »

May I suggest that you add the version number to the name that is displayed in the upper left corner of the GUI? With your rapid improvements, I'm not sure which version I'm using. :lol:

I notice that now the speakers are not connected to the microphone when Precord is recording. Good job!

mcewanw
Posts: 3169
Joined: Thu 16 Aug 2007, 10:48
Contact:

1.0.5 uploaded

#14 Post by mcewanw »

1.0.5 uploaded

I haven't tested this one so thoroughly. I'm too busy working on 1.0.6, which is still about file entry handling - so consider this one temporary but close.
github mcewanw

User avatar
Flash
Official Dog Handler
Posts: 13071
Joined: Wed 04 May 2005, 16:04
Location: Arizona USA

#15 Post by Flash »

I don't know if this is a bug or just a peculiarity of my system:
When I click to expand the "Config" menu, Precord 1.0.5 disappears. I restart it from the Multimedia menu, click "Config" again, and it works like it's supposed to. (This also happened in 1.0.4 but I forgot to mention it. :oops: )

I tried vbr. It works fine. I didn't do a real comparison yet (recording the same audio track with both vbr and cbr) but vbr's file size for 30 seconds of me talking seemed about the same as with cbr. Is that what you found?
[url=http://www.murga-linux.com/puppy/viewtopic.php?t=69321][color=blue]Puppy Help 101 - an interactive tutorial for Lupu 5.25[/color][/url]

mcewanw
Posts: 3169
Joined: Thu 16 Aug 2007, 10:48
Contact:

#16 Post by mcewanw »

Flash wrote: When I click to expand the "Config" menu, Precord 1.0.5 disappears. I restart it from the Multimedia menu, click "Config" again, and it works like it's supposed to
Just means the precord config file was corrupted somehow. Used to happen if you clicked the GUI window X rather than exit with the Quit button, but I thought I'd fixed that in 1.0.4
Anyway, it self-heals as you described and hopefully rarely occurs. I've hardly had time to test version 1.0.5 unfortunately, since things have come up here that prevent me doing more on it for a day or two at least. But do let me know if any other problems come up or if the vanishing problem occurs again or often.
Flash wrote: I tried vbr. It works fine. I didn't do a real comparison yet (recording the same audio track with both vbr and cbr) but vbr's file size for 30 seconds of me talking seemed about the same as with cbr. Is that what you found?


Depends on the bitrate you set it at. If both are at 32kbits/sec then the size will probably be much the same, but at hight bit rates vbr should provide much smaller files (compared to cbr at the same selected bit rate). vbr certainly seemed to be the best for me when recording streaming radio with 01micko's pupRadio.
Last edited by mcewanw on Mon 14 Dec 2009, 14:59, edited 1 time in total.
github mcewanw

mcewanw
Posts: 3169
Joined: Thu 16 Aug 2007, 10:48
Contact:

drag and drop files

#17 Post by mcewanw »

In case anyone doesn't realise this, you can drag and drop files from Rox file manager into the entry boxes
github mcewanw

User avatar
BarryK
Puppy Master
Posts: 9392
Joined: Mon 09 May 2005, 09:23
Location: Perth, Western Australia
Contact:

#18 Post by BarryK »

If you want a nice VU meter for Precord, there is "gtkvumeter", however it is only a gtk widget and will require some wrapper application to drive it.

http://mumblelina.com/gtk/gtkVUMeter-gtk2.0-0.2.tar.gz
[url]https://bkhome.org/news/[/url]

User avatar
Flash
Official Dog Handler
Posts: 13071
Joined: Wed 04 May 2005, 16:04
Location: Arizona USA

#19 Post by Flash »

How does mhWaveEdit manage to include built-in VU meters that look like old-school galvanometers, with a dial and a needle that moves? If you're recording stereo there are two VU meters.

I think I found mhWaveEdit's executable file in usr/bin/ but I can't open it to see what's inside. Even if I could, I'm sure I wouldn't have a clue what I was looking at. I assume it's a compiled program, and the source code is somewhere else.

mcewanw
Posts: 3169
Joined: Thu 16 Aug 2007, 10:48
Contact:

#20 Post by mcewanw »

BarryK wrote:If you want a nice VU meter for Precord, there is "gtkvumeter", however it is only a gtk widget and will require some wrapper application to drive it.
Actually, I compiled and tried that one on the 12 Dec. It just comes with a test front end which shows its general look and feel. The executable is only about 15kB - but alas I have no idea how to make it work with alsa; maybe I'll eventually look at the source code for ameter or even aplay to see if I can figure out how they actually pick up the sound data but I've no idea how trivial or otherwise that is likely to be. If it is easy, I would have thought there was an app already out there using gtkvumeter rather that ameter (which needs SDL) but I couldn't find any. However, if anyone knows how such things work, please do let me know - a VU working on record would be just great!
github mcewanw

Post Reply