midiclick - generates a metronome click-track on MIDI channel 9
midiclick -t 108 # tempo is (starts at) 108 beats/min midiclick -t 108 -b 4 # Four beats in a bar midiclick -Q -t 108 -b 4 # Quiet mode; no User-Interface midiclick -o 14:1 -t 108 # Output to ALSA-port 14:1 midiclick -p # Starts up in Paused mode xterm -g 80x7-1+1 -exec 'midiclick -t 165 -b 5' & perldoc midiclick ~> midiclick -o 128:0 -t 144 -b 5 ALSA client 129 midiclick pid=2157 Output port 129:1 is connected to 128:0 Tempo 144 beats/min BarLength 5 beats Playing Volume 100 _ t=Tempo b=Barlength <spacebar>=PAUSE v=Volume q=Quit
The MIDI::ALSA module is used to create an ALSA client.
The keyboard interface, allows real-time adjustment of the delay parameters. If you don't want the interface (e.g. in a Makefile), the -Q option sets Quiet-mode.
This is midiclick version 1.2
The tempo will be set; to 72 beats per minute in this example. The default is 120.
The bar-length will be set; the bell will sound every 3 beats in this example. The default is 0, which means every beat clicks and there are no bells.
This option sets the volume (or velocity) of the MIDI output. The default is 100.
This option starts midiclick in the paused state; you can then start it Playing with spacebar. This option is ignored in -Q Quiet mode.
This option sets the ouput-port to which the midi output will be sent. You can check out the available ports with the command aplaymidi -l or aconnect -ol. The default ouput-port is the environment variable $ALSA_OUTPUT_PORTS
Since Version 1.3, you may supply a comma-separated list of ports, e.g. -o 20,128:1
This option runs midiclick in Quiet mode; there is no user-interface, and the metronome just runs with its Tempo and BarLength as given on the command-line, until it is interrupted. It can be useful in scripts.
Shows helpful usage information
Displays the Version number.
The current version of midiclick is available by http at
www.pjb.com.au/midi/free/midiclick
To install it, save it to disc,
move it into your $PATH, make it executable, and if necessary
edit the first line to reflect where perl is installed on your system.
You will also need to install the
MIDI::ALSA and
Term::ReadKey
CPAN modules
1.4, 20111103, uses
the new MIDI-ALSA 1.11
to handle ALSA-ports by their names
1.3, 20111028, OutputPort
can be a comma-separated list
1.2, 20110911, -b defaults to 0 beats
1.1, 20110608,
-t
and
-b
work;
-v
and
-p
introduced
1.0, 20110606, first working version, edited down from
midiecho
Peter J Billam www.pjb.com.au/comp/contact.html
search.cpan.org/perldoc?MIDI::ALSA
search.cpan.org/perldoc?Term::ReadKey
www.pjb.com.au/midi
www.pjb.com.au/muscript/gm.html#perc