comparison core/RTAudioCommandLine.cpp @ 31:06fd2ffee605 matrix_gpio

Fixed command line bug same as per commit 30, just on a different branch
author Giulio Moro <giuliomoro@yahoo.it>
date Mon, 11 May 2015 11:45:03 +0100
parents 182ae9367104
children 46d87f680da5
comparison
equal deleted inserted replaced
26:6d64ee8c0754 31:06fd2ffee605
9 #include <cstdlib> 9 #include <cstdlib>
10 #include <cstring> 10 #include <cstring>
11 #include <getopt.h> 11 #include <getopt.h>
12 #include "../include/RTAudio.h" 12 #include "../include/RTAudio.h"
13 #ifndef OPT_PRU_FILE 13 #ifndef OPT_PRU_FILE
14 #define OPT_PRU_FILE -1 14 #define OPT_PRU_FILE 176
15 #endif 15 #endif
16 16
17 // Default command-line options for RTAudio 17 // Default command-line options for RTAudio
18 struct option gDefaultLongOptions[] = 18 struct option gDefaultLongOptions[] =
19 { 19 {
20 {"period", 1, NULL, 'p'}, 20 {"period", 1, NULL, 'p'},
21 {"verbose", 0, NULL, 'v'}, 21 {"verbose", 0, NULL, 'v'},
22 {"use-analog", 1, NULL, 'm'}, 22 {"use-analog", 1, NULL, 'm'},
23 {"use-digital-gpio", 1, NULL, 'g'}, 23 {"use-digital-gpio", 1, NULL, 'g'},
24 {"analog-channels", 1, NULL, 'C'}, 24 {"analog-channels", 1, NULL, 'C'},
25 {"digital-gpio-channels", 1, NULL, 'G'}, 25 {"digital-channels", 1, NULL, 'G'},
26 {"mute-speaker", 1, NULL, 'M'}, 26 {"mute-speaker", 1, NULL, 'M'},
27 {"dac-level", 1, NULL, 'D'}, 27 {"dac-level", 1, NULL, 'D'},
28 {"adc-level", 1, NULL, 'A'}, 28 {"adc-level", 1, NULL, 'A'},
29 {"hp-level", 1, NULL, 'H'}, 29 {"hp-level", 1, NULL, 'H'},
30 {"pru-file",1,NULL,OPT_PRU_FILE}, 30 {"pru-file",1,NULL,OPT_PRU_FILE},
190 std::cerr << " --hp-level [-H] dBs: Set the headphone output level (0dB max; -63.5dB min)\n"; 190 std::cerr << " --hp-level [-H] dBs: Set the headphone output level (0dB max; -63.5dB min)\n";
191 std::cerr << " --mute-speaker [-M] val: Set whether to mute the speaker initially (default: no)\n"; 191 std::cerr << " --mute-speaker [-M] val: Set whether to mute the speaker initially (default: no)\n";
192 std::cerr << " --use-analog [-m] val: Set whether to use ADC/DAC analog (default: yes)\n"; 192 std::cerr << " --use-analog [-m] val: Set whether to use ADC/DAC analog (default: yes)\n";
193 std::cerr << " --use-gpio-analog [-g] val: Set whether to use GPIO analog (default: yes)\n"; 193 std::cerr << " --use-gpio-analog [-g] val: Set whether to use GPIO analog (default: yes)\n";
194 std::cerr << " --analog-channels [-C] val: Set the number of ADC/DAC channels (default: 8)\n"; 194 std::cerr << " --analog-channels [-C] val: Set the number of ADC/DAC channels (default: 8)\n";
195 std::cerr << " --analog-gpio-channels [-G] val: Set the number of GPIO channels (default: 16)\n"; 195 std::cerr << " --digital-channels [-G] val: Set the number of GPIO channels (default: 16)\n";
196 std::cerr << " --pru-file val: Set an optional external file to use for the PRU binary code\n"; 196 std::cerr << " --pru-file val: Set an optional external file to use for the PRU binary code\n";
197 std::cerr << " --verbose [-v]: Enable verbose logging information\n"; 197 std::cerr << " --verbose [-v]: Enable verbose logging information\n";
198 } 198 }
199 199