cmd_play 2.5 – Reproduces the PC88 CMD PLAY command

当サイトではアフィリエイト広告を利用しております。

Windowsソフト

Overview

This is a program that reproduces the CMD PLAY command of the old 8-bit PC-8801 computer on the command line of a modern Windows computer. It can reproduce the sound of the nostalgic CMD PLAY command quite well.

Usage

Basically, you enter commands into the black command prompt screen.

Usage: cmd_play [Options] [#n] [string1] [string2] [string3] [string4] [string5] [string6]

Options:
  -DVAR=VALUE                Assign to a variable.
  -save-wav output.wav       Save as WAV file (except MIDI sound).
  -save-mid output.mid       Save as MID file (MIDI sound only).
  -reset                     Stop music and reset settings.
  -stopm                     Same as -reset except that the tone is not changed.
  -stereo                    Make sound stereo (default).
  -mono                      Make sound mono.
  -voice CH FILE.voi         Load a tone from a file to channel CH (FM sound).
  -voice CH "CSV"            Load a tone from an array to channel CH (FM sound).
  -voice-copy TONE FILE.voi  Copy the tone to a file (FM sound).
  -bgm 0                     Wait until the performance is over.
  -bgm 1                     Don't wait until the performance is over (default).
  -help                      Display this message.
  -version                   Display version info.

Numeric variables can be specified by enclosing them between an equal sign and a semicolon: "L=variable name;".
String variables can be expanded by enclosing them in [ ].

Downloads

CMD PLAY statement (8801 only) (CMD extension)

  • [Function] Plays music.
  • [Etymology] Command play
  • [Format] CMD PLAY [#sound source mode,] [ string 1 ][, string 2 ][, string 3 ][, string 4 ][, string 5 ][, string 6 ]
  • [Example] CMD PLAY "CDE" ⇒ Plays Do-Re-Mi
  • [Explanation] Can play up to 6 chords. string 1, string 2, string 3 correspond to channels 1, 2, 3, string 4, string 5, string 6 correspond to channels 4, 5, 6.

sound source mode is a value between 0 and 5, and has the following meanings.

  • #0 … Uses an external SSG sound source. Channels 1 to 6 use the SSG sound source.
  • #1 … Uses an external MIDI sound source. Channels 1 to 6 use the MIDI sound source.
  • #2 … Channels 1 to 3 use the FM sound source, and channels 4 to 6 use the SSG sound source.
  • #3 … Switches OPN to sound effect mode. Sound is produced by the Y statement of CMD PLAY.
  • #4 … Switches OPN to CSM (sine wave) mode. Sound is produced by the Y statement of CMD PLAY.
  • #5 … Uses FM sound source. Channels 1 to 6 use the FM sound source.

If sound source mode is omitted, #2 is selected. #5 can only be selected on sound board 2.
Normally, use sound source mode at #0, #1, #2, or #5. Rhythm sound sources are not yet supported.

The character strings for each channel are called MML (Music Macro Language), and have the following meanings:

StringMeaningDefault
Mx (SSG only)Sets the envelope period (1≦x≦65535). x is optional.M255
Sx (SSG only)Sets the envelope shape (0≦x≦15). x is optional.S1
VxSets the volume (0≦x≦15). x is optional.V8
LxSets the default length of notes and rests (1≦x≦64). x is optional.L4
QxSets the length ratio of notes (1≦x≦8). x is optional.Q8
OxSets the octave (1≦x≦8). x is optional.O4
>Raises the octave by one.
<Lowers the octave by one.
NxPlays the note of the height specified by x (0≦x≦96). x is not optional.
TxSets the tempo (32≦x≦255). x is optional.T120
RxPlays a rest (1≦x≦64). x is the length of the rest. x is optional.R4
CB[+/-][x][.]Plays a note (1≦x≦64). x is the length of the note. x is optional.
+ (#)Raises the previous note by a semitone.
-Lowers the previous note by a semitone.
.Adds a dot to the previous note or rest, lengthening it by 1.5 times.
&Connects the preceding and following notes.
{}xPlays a tuple of notes equally divided by x in the specified length. x is optional.
@x (FM/MIDI only)Switches to the tone specified by the tone number x. x is not optional.@0
Yr,d (OPN only)Sets the content of OPN register r to d (0≦r≦178 and 0≦d≦255).
Zd (MIDI only)Sends 1-byte data d to MIDI (0≦d≦255).
@M (Soundboard 2, FM/MIDI only)Sets the output to both left and right channels.
@L (Soundboard 2, FM/MIDI only)Sets the output to the left channel.
@R (Soundboard 2, FM/MIDI only)Sets the output to the right channel.
@Vx (FM/MIDI only)Fine-tunes the volume (0≦x≦127). x is not optional.@V106
@WxMaintains the state for the length specified by x (1≦x≦64). x is optional and defaults to the value of L.
  • The musical notes CDEFGAB correspond to “Do Re Mi Fa So La Si”.
  • For tone numbers, see the tone list.
  • @x cannot be specified in MIDI on the actual machine. Instead, use Zd multiple times to change the program.
  • @M, @L, and @R cannot be specified in MIDI on the actual machine. Instead, use Zd multiple times to set the pan.
  • For more information about MIDI, see the Wikipedia MIDI page.
  • On some models, after you set @V, @V takes precedence over the V setting.
  • The CMD PLAY statement is an extended CMD command and can only be used on the 8801. Before using CMD PLAY, you must execute NEW CMD (except in unlimited mode). If you specify a string longer than 255 characters, a String too long error will occur (except in unlimited mode).

Supported platforms

  • Windows XP and later

Notice

  • BASIC’s CMD PLAY statement is comma-separated, but cmd_play is space-separated for command line convenience.
  • If you want to enjoy modern digital music production, try looking for free DTM software. That said, inputting notes in DTM is a pain, and it’s a legacy of the past… (omitted)

Change Log

License Agreement

Contact

タイトルとURLをコピーしました
inserted by FC2 system