From b7ddafec3b6e74ae99f8601403fcc7726437a563 Mon Sep 17 00:00:00 2001 From: clrnd Date: Tue, 5 Dec 2017 18:48:17 -0300 Subject: [PATCH] typo and name --- README.md | 4 ++-- src/main.cpp | 8 +++----- 2 files changed, 5 insertions(+), 7 deletions(-) diff --git a/README.md b/README.md index aaa8e45..9b77a22 100644 --- a/README.md +++ b/README.md @@ -48,7 +48,7 @@ Where: ``` For example, suppose you have a WAV file `wavetable3.wav` that has -8192 samples: +`64*128 = 8192` samples: ``` $ soxi wavetable3.wav @@ -66,7 +66,7 @@ Then, you would generate a SysEx file for transfering this wavetable into slot 82 with the name "Awful Sound" like this: ``` -wave2blofeld wavetable3.wav out.mid -n 3 -s "Awful Sound" +wave2blofeld wavetable3.wav out.mid -s 3 -n "Awful Sound" ``` Then it's just a matter of playing the midi file into the Blofeld with something diff --git a/src/main.cpp b/src/main.cpp index 325bfa3..8f2bb5c 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -35,7 +35,7 @@ Options parseOptions(int argc, char* argv[]){ half("d", "double", "Use only half of the samples for each wave. Useful for banks created with 256 samples per wave.", cmd, false); TCLAP::ValueArg - slot("s", "slot", "Wavetable to write to.", true, 0, "slot"); + slot("s", "slot", "Wavetable to write to. Between 80 and 118.", true, 0, "slot"); cmd.add(slot); TCLAP::ValueArg @@ -115,8 +115,6 @@ int main(int argc, char* argv[]){ MidiFile mf; mf.setTicksPerQuarterNote(100); - std::string name = "Example Whatev"; - std::cout << "Generating..." << std::endl; for (int wave = 0; wave < 64; ++wave){ @@ -127,7 +125,7 @@ int main(int argc, char* argv[]){ mm[2] = 0x13; // Blofeld ID mm[3] = 0x00; // Device ID mm[4] = 0x12; // Wavetable Dump - mm[5] = 0x50 + opts.slot - 1; // Wavetable Number + mm[5] = 0x50 + opts.slot - 80; // Wavetable Number mm[6] = wave & 0x7f; // Wave Number mm[7] = 0x00; // Format @@ -138,7 +136,7 @@ int main(int argc, char* argv[]){ } for (int i = 0; i < 14; ++i){ - mm[392+i] = name[i] & 0x7f; + mm[392+i] = opts.name[i] & 0x7f; } mm[406] = 0x0; // Reserved