Add image to MP3

You can add album art images to your mp3 files. Use EasyTAG (GUI) or eyed3 (CLI) ID3 tag editors to accomplish that.

Example. Use eyed3 to remove any embedded images, then list options for embedded image file, then embed an image for an icon:

  • eyeD3 --remove-images test.mp3
  • eyeD3 --list-image-types
  • eyeD3 --add-image=test.jpg:ICON test.mp3


Add an image, various text info and a longer comment from a text file:

  • comment=`cat test.txt`;
  • eyeD3 --set-encoding="utf8" --year="2018" --artist="test" --album="test" --publisher="test" --title="test" --comment=:"test":"$comment" --add-image=test.jpg:ICON test.mp3

Brown noise generator

Simple brown noise generation script using sox on Linux.

Installing Boodler on Mint 17

Install prerequisites:

  • sudo apt-get install python-dev libpulse-dev

Make temporary directory, download Boolder, compile and install it:

  • mkdir -p boodler
  • cd boodler
  • wget
  • tar zxvf Boodler-2.0.4.tar.gz
  • cd Boodler-2.0.4
  • python build
  • sudo python install

Test the install. If you hear the sound, everything is all right and you may proceed. (Remember to use -o pulse switch on Ubuntu based distributions)

  • boodler -o pulse --testsound

Save the list below into a file packages.txt : Read the rest of this entry »

Record from webcam

You can use guvcview to record from webcam.

Bash script to play .m4v video and .ul audio together

So you have a lot of .m4v video files and a lot of .ul audio files with the same names. That, for example, might be a collection of  CCTV records, where the name of the file is the date and time of when the record was made. Now you would like to play them.

Create a bash script file in ~/bin, /usr/bin or similar directory. Paste the code inside. Add execution rights. Then run the script with .m4v video  file name as the only argument. The script will figure out name of the audio file on its own and afterwards it will play it all with a bunch of various parameters.

Let’s call it playit:

 mplayer -fps 25 -vf denoise3d=0:0:100:0 -cache 16000 -framedrop $videoFile -audiofile $audioFile -audio-demuxer rawaudio -rawaudio format=0x0007:channels=1:rate=8000

Later you can play all video files in the current directory with their accompanying audio files by means of another script, let’s call this one playall:

 for i in *.m4v; do
    playit $i

And another improvement. A script to look into all subdirectories of the current directory and play media found there. Useful if you have your packs of audio &  video files stored in timestamped directories. Let’s call this one playdirs:

for subDir in */; do
cd $subDir
cd $rootDir

And then yet another one. Play only files only in a single directory. That will be playdir:

 cd $subDir
 cd $rootDir

Losslessly convert MP4 to MKV

  • avconv -i test.mp4 -c:v copy -c:a copy test.mkv

Merge WAV files

Merge all WAV files in directory into a single big WAV file using sox:

  • myvar=`ls *.wav | awk ‘{ ORS=” “; print; }’`; echo $myvar; sox $myvar all.wav


If the copy+pasted example script does not work, try to retype the tick marks, as they can be “spoiled” by HTML formatting of the web page.