sndtowav

mpc2000xl.jpg sndtowav is an open-source software tool for conversion of SND-(Akai™ MPC2000®) to wav- files. A GUI frontend is available.

Introduction

Most MPC users discover one day that they would like to use their MPC sounds with other instruments or software or simply listen to them on their workstation but the common audio players and -software do not support the Akai SND format. So here is a tool for batch-converting whole directories to the common wav format (or others – version 00.01 and higher, see options).

Technical Details

The Akai ® MPC2000 and other related models use DOS formatted disks. Samples are saved with a .SND extension and contain 16-bit signed data after a 42 byte header (see below). The sound data is not interleaved (contrary to wav-file data), the channels are saved consecutively and have to be interleaved when converting to wav.

sndtowav uses the libsndfile-library (http://www.mega-nerd.com/libsndfile/) as output file-writer and a proprietary (and currently dirty) SND-file parser. The commandline interface has been implemented using a proprietary option/argument parser class (from release 00.30 on), which could be nicely incorporated into other applications.

The sources of sndtowav have been released under the GNU general public license, what (in few words) allows other people to use it in any project except commercial ones, as long certain things are respected. For precise information please check http://www.gnu.org/copyleft/gpl.html.

Features

  • Supports wav, aiff, au, matlab as output formats (others on request).
  • Can batch convert whole directories.
  • OS independent (even though I have not recompiled it, volunteers?).
  • Open source. Feel free to contribute.
  • GUI frontend.

Installation

Win32

  1. Get the freshest release (highest relese number, see Releases below).
  2. Un-zip it into a directory of your choice (e.g. C:\Program files\sndtowav).
  3. Add this directory to your system search path (see FAQ for details) - then you will be able to run it from anywhere.

Usage

(Release 00.20)

sndtowav is a shell application and is controlled by options, option arguments and arguments:

sndtowav [options [optionargs]] [inputfiles]

General Options

-s
Silent mode. No console output and no warnings either.

-w
Silent mode but with warnings enabled.

-h
sndtowav help.

-p
Keeps the console paused when processing is completed.

-d dir
Redirects the output files to another directory specified by dir. This directory specification can be relative. The directory must exist.

Format Options

The input file endings have to be “.snd”, the case does not matter. You can use wildcards – the question mark (?) and asterisk (*) – to specify filename and path arguments on the command line. The default output is “.wav”

-aiff
.aiff output format (Apple/SGI™ AIFF format)

-au
.au output format (Sun/NeXT™ AU format)

-mat
.mat output format (Matlab™ V4.2 / GNU Octave 2.0)

Example

E:\projects\SndToWav\test\snd>sndtowav -aiff *.snd

     sndtowav 00.10
     MPC 2000 SND to wav file conversion.
     Copyright (c) 2005 nebadje.org
     This software has been released under the GNU General Public License (GPL)

converting "BEATCP1.SND" to "BEATCP1.aiff":
    #ch: 2, sf: 44100, len: 0.319025 s
converting "FE00.SND" to "FE00.aiff":
    #ch: 2, sf: 44100, len: 0.18356 s
converting "FE06.SND" to "FE06.aiff":
    #ch: 2, sf: 44100, len: 0.17195 s
converting "FE4.SND" to "FE4.aiff":
    #ch: 2, sf: 44100, len: 0.268844 s
converting "FILT.SND" to "FILT.aiff":
    #ch: 2, sf: 44100, len: 4.36195 s
converting "KLING.SND" to "KLING.aiff":
    #ch: 2, sf: 44100, len: 4.09324 s

Releases

Win32

For sources please see the sources section.

Version DateComment Binaries
00.00 2005-12-16Initial release. obsolete
00.01 2005-12-16aiff, au, mat output formats added. sndtowav-00-01-bin.zip
00.10 2005-12-17Statically linked to libsndfile (dll not required anymore) and speed improvements. sndtowav-00-10-bin.zip
00.20 2005-12-17Directory option and pause option added, option parser improved. sndtowav-00-20-bin.zip
00.30 2005-12-19Internal cosmetics and nice new commandline parser class added. sndtowav-00-30-bin.zip

GUI Frontend

General

The GUI has been programmed using wxWidgets, an open-source cross platform toolkit. It simply generates the commandline and stuffs it into sndtowav. The usage should be pretty selfexplanatory.

For comments, bug-reports, suggestions etc please use the email address at the bottom of this page.

Installation

Preliminary. Install sndtowav as descibed above and run frontend.exe. Make sure that the xrc directory and its contents is located in the same directory as the frontend executable.

Win32

Version DateComment Binaries
00.00 2005-12-18Initial release. frontend-w32-00-00-bin.zip

frontend-in-use.jpg

Sources

Version DateComment File
00.30 2005-12-21Contains sndtowav 00.30 and frontend 00.00 sources. sndtowav-src-00-30.zip

Contact/Discussion/Comments

Feel free to send emails to cls [at] nebadje [dot] org. It would be interesting to know how many and who is using sndtowav.

Thanx — cls – 2005/12/20 13:48

FAQ

Q: I have downloaded the two parts but when I run the frontend it says it cannot find sndtowav even though it is in the same directory, any ideas? Im using windows xp.

Ok. First try to run it from the command line (see syntax on the web page) directly in the directory where sndtowav is located (for example ask it to print the help).

C:\Directory\From\Hell\sndtowav -h

If that works, save it (for instance) at “C:\Program Files\sndtowav” and add this directory to your “system search path”. This can be accomplished as follows:

  1. From the desktop, right click My Computer and click properties (or go to the “Control Panel” and

then “System”).

  1. In the System Properties window, click on the Advanced tab.
  2. In the Advanced section, click the Environment Variables button.
  3. Finally, in the Environment Variables window, highlight the path variable in the Systems Variable

section and click edit. Add or modify the path lines with the paths you wish the computer to access. Each different directory is separated with a semicolon as shown below.

C:\Foo\Bar;"C:\Program Files\sndtowav";C:\whatever\else

Include the quotation marks in any case (this makes sure that white spaces in the path are interpreted correctly).

When running the frontend make sure the xrc directory is in the same directory as frontend.exe (or at least in the directory where it is executed, if execution should take place in a different directory.

 
neblab/sndtowav.txt · Last modified: 2006/08/03 00:14 by cls
 
Nebadje Controls You