Professional Documents
Culture Documents
Right, at long last, I have been able to get a reply out of CASIO UK
about the MIDI standards of the CZ series of synthesizers. For those of
you who know how to play your keyboard by remote control from a
computer, this will be of some interest, since it covers transmission
of programming information ( both to and from the CZ ), setting of the
controllers you previously couldn't access like tone mix level, and
other bits besides.
First off, let's recap on the simple stuff. The MIDI is a digital
interface to musical instruments, and relies on serial transmission of
data. These data are usually talked of in terms of bytes, and I shall
be using hexadecimal numbers in this posting.
There are basically two types of bytes sent over MIDI - control bytes
and data bytes. Control bytes are distinguished by having values over
0x80 ( 80 hex, 128 decimal ), and these have valious meanings:
1) NOTE ON
----------
92 20 40
NOTE ON, channel 2 Note #32 Velocity 64
If you wish to turn two or more notes on at the same time, the control
byte need not be retransmitted. Eg to turn note 35 on as well, you
could send
92 20 40 23 40
NOTE ON, ch2 ---32 on-- ---35 on--
2) NOTE OFF
-----------
92 23 00
NOTE ON,Ch 2 --35 off--
B0 05 10
CONTROL, ch 0 --ctrl 5=16--
CZ101/1000
CZ5000
4) PROGRAM CHANGE
-----------------
This allows you to change between the preset sounds ( and your internal
sounds and cartridges ). Just send C0 plus the channel number, then the
program number. Eg to set CZ101 on channel 1 to Synth Bass:
C1 07
PROGRAM ch 1 Program 7
CZ101/1000
CZ5000
This is acheived by sending E0 plus the channel number, then two bytes
denoting the new value of pitch bend. The first byte is the most
significant, and the second the least significant. Note also that the
lower 6 bits of the lower byte are not used, and that the central
position of the wheel corres- ponds to the byte sequence 40 00.
HIGHEST 7F 40
HIGHER
CENTER 40 00
LOWER
LOWEST 00 00
So, to bend the instrument on channel two UP by about half its maximum
amount, send
E2 60 00
BEND channel two ---1/2 up--
6) AFTER TOUCH
--------------
Is not supported on the CZ101/1000/5000. Sorry!
7) MODE CHANGE
--------------
This is very similar to the CONTROL CHANGE message, and can be regarded
as a special case.
OMNI mode plays any MIDI data received at the MIDI IN plug on the back
of the machine, regardless of channel. POLY mode is equivalent to the
SOLO button on the front panel. With the CZ101, for instance, POLY OFF
( =SOLO ) allows the synth to be used as four monophonic synthesizers
under remote control.
SEQUENCER MESSAGES
------------------
The CZ5000 has its own internal sequencer, which can be controlled
by:
F8 Clock byte: transmitted 24 times per quarter note ( crotchet
)
FA Start: same as pressing the PLAY button on the front panel
FB Continue: continue song where last stopped
FC Stop: stops song play at current position
FD Active sense: basically, a cry of "Is there anybody out
there". If no reply is received within about 1/3 second, it shuts
the voice off.
Since these are usually controlled by computer, I have set them out as
a computer/synthesizer dialogue. Note that the computer MUST wait for
replies before proceding, or all will fail !
2) KEY TRANSPOSE
----------------
Data is as follows:
Key: G A A# B B# C C# D E E# F F#
Data: 45 44 43 41 41 00 01 02 03 04 05 06
3) TONE MIX
-----------
The data is 00 to turn tone mix off, or 41..49 for mix level 1..9
Computer: F0 44 00 00 70+channel 19 00
CZ101/1000: F0 44 00 00 70+channel 30
Computer: 70+channel 31
CZ101/1000: data1 data2 F7
Computer: F7
data2 00 10 20 30
Vibrato OFF OFF ON ON
Port'o OFF ON OFF ON
Eg an exchange such as
Computer: F0 44 00 00 70 19 00 "Want data on channel 0"
CZ101: F0 44 00 00 70 30 "Gotcha.. data ready"
Computer: 70 31 "Ok, give it to me"
CZ101: 27 30 F7 "Internal 8, v on, p on"
Computer: F7
REMOTE PROGRAMMING
------------------
The send request 1 and receive request 1 messages.
These dump a lot of data across the MIDI, which is the same for both
messages, except that the data go the other way. The exchanges are:
Send request
Computer: F0 44 00 00 70+channel 10 program
CZ101/1000: F0 44 00 00 70+channel 30
Computer: 70+channel 31
CZ101/1000: <tone data> F7
Computer: F7
Receive request
Computer: F0 44 00 00 70+channel 20 program
CZ101/1000: F0 44 00 00 70+channel 30
Computer: <tone data> F7
Cz101/1000: F7
The program byte is the same as that set by the PROGRAM CHANGE
function, with the addition that you can request the temporary sound
area as well ( number is 60 ). This is the area that is used if you
have altered a preset and not saved it into internal memory.
To keep everything this side of infinite length, I shall adopt the same
strategy as the manual, which is to write data in bytes, although they
are transmitted in half- bytes. For example, me writing a byte as 5F
requires you to transmit or receive as 0F 05 ( wierd, huh ? ). This
will obvoiusly save a lot of space.
So, here goes again :-)
1) PFLAG
Looking at bits,
0000 00 00
Not used^ OCTV LS
2)PDS
For detune +, PDS is 0, for detune - it is 01
3)PDETL,PDETH
OCT: 0 1 2 3
NOTE: 0..11 0..11 0..11 0..11
Byte: 00..0B 0C..17 18..23 24..2F
4) PVK
WAVE NUMBER: 1 2 3 4
Byte: 08 04 20 02
5) PVDLD,PVDLV
For delays in the range 0..31, just transmit 00..1F, 00, 00..1F eg for
delay of 12, send 0C 00 0C. This is convenient since it saves me typing
in another column of boring numbers ;-)
6) PVSD,PVSV
Again, here comes another table for conversions. The first column
(0..24) is omitted since the only difficult thing needed is to add 01
00 20 to each entry ( The first few go 00 00 20, 01 00 40, 02 00 60,
... 06 00 E0, 07 01 00, ..)
7) PVDD,PVDV
These are again encoded as three bytes in a most obscure way. Below 32,
the encoding is 00..1F, 00, 01..20 eg for depth 13, send 0D 00 0E.
8) MFW
These two bytes transmit the waveform for DCO1, and also the modulation
ie ring, noise or none.
9) MAMD,MAMV
Key follow: 0 1 2 3 4 5 6 7 8 9
1st byte: 00 01 02 03 04 05 06 07 08 09
2nd byte: 00 08 11 1A 24 2F 3A 45 52 5F
Key follow: 0 1 2 3 4 5 6 7 8 9
1st byte: 00 01 02 03 04 05 06 07 08 09
2nd byte: 00 1F 2C 39 46 53 60 6E 92 FF
11) PMAL
This sets the position of the end step on DCA1. Step 1..8 gives bytes
00..07.
12) PMA
Given that you wish to set rate r, the data you need to send is
Byte= 119 x r
-------
99
Conversely, if byte=0, rate=0, if byte=7F, rate=99, otherwise
r=99 x byte
--------- + 1
119
13) PMWL
14) PMW
15) PMPL
Another end step setting, this time for DCO1. Same as PMAL and PMWL
16) PMP
Another envelope setting, this time for the DCO1 rates and levels.
Again Casio uses a completely different encoding scheme.
For the level, level data 0..63 translate as bytes 00..3F, and level
data 64..99 translate as bytes 44..67.
17) SFW
These two bytes set the waveform for DCO2. They use the same format as
MFW does for DCO1, except that the modulation bits are ignored ( it is
best to set these bits to zero , just in case ).
18) SAMD,SAMV
19) SWMD,SWMV
20) PSAL
21) PSA
22) PSWL
23) PSW
24) PSPL
25) PSP
All the above use the same formats as their counterparts for the first
set of DCO,DCW,DCA, and perform exactly the same functions on the
DCA2,DCW2,and DCO2.
-- "Thong" Ellis