| Mozzi version v1.1.0 sound synthesis library for Arduino |

Functions
char2mozzi.py File Reference
Util

    A script for converting raw 8 bit sound data files to wavetables for Mozzi.

More...

Go to the source code of this file.

## Functions
def | char2mozzi.char2mozzi (infile, outfile, tablename, samplerate)

## Detailed Description

    A script for converting raw 8 bit sound data files to wavetables for Mozzi.

Usage: >>>char2mozzi.py <infile outfile="" tablename="" samplerate>="">

Parameters

  infile | The file to convert, RAW(headerless) Signed 8 bit PCM.
  outfile | The file to save as output, a .h file containing a table for Mozzi.
  tablename | The name to give the table of converted data in the new file.
  samplerate | The samplerate the sound was recorded at. Choose what make sense for you, if it's not a normal recorded sample.
      @note Using Audacity to prepare raw sound files for converting:

      For generated waveforms like sine or sawtooth, set the project
      rate to the size of the wavetable you wish to create, which must
      be a power of two (eg. 8192), and set the selection format
      (beneath the editing window) to samples. Then you can generate
      and save 1 second of a waveform and it will fit your table
      length.

      For a recorded audio sample, set the project rate to the
      Mozzi AUDIO_RATE (16384 in the current version).
      Samples can be any length, as long as they fit in your Arduino.

      Save by exporting with the format set to "Other uncompressed formats",
      "Header: RAW(headerless)" and "Encoding: Signed 8 bit PCM".

      Now use the file you just exported, as the "infile" to convert.

      @author Tim Barrass 2010-12

Definition in file char2mozzi.py.