This article is written by Heiko Plate. The structures of DSP and Harmony are found by Michael Bedesem.
Introduction

With the Yamaha-keyboard PSR-740 we can save parameters of the keyboard on a disk in order to get back these later if wanted. Using Disk Operations "Save" there are five file-types to be stored separately: "All", "Style + Reg.", "Style", "Multi Pad" and "Regist".

The aim of this article is a description of the structure of archives for registrations, which are stored an a floppy disk, if we have selected one of the the file-types "Style + Reg." or "Regist.". I have analyzed a little part only.

  Remarks:

The files in the data-blocks of archives are written without the delimiter "." between file-name and file-extension. All numbers in the textfiles of archives are decimal ones.

In this article I use the denotation of hexadecimal numbers with starting "0x": 0x2c = 44 for example.


The Structure of Registration Archives

We can save several registration archives on only one storage medium, hard or floppy disk, using a different archive-names. The PSR-740 uses the default-names UF_00001, UF_00002,..., but the user can change these by own names.

If there are stored n, n = 1,2,..., registration-archives UF_00001, UF_00002,..,UF_0000n on a disk, the PSR_740 has created the following files in the root-directory:

Disk.mng

On all floppy disks, which have got some data by the PSR-740, we find this file with the same text inside. disk.mng is used by the keyboard to identify a PSR-740 disk. With this examination the PSR-software will get some security before reading the other files.

UF_00001.usr, UF_00002.usr,...UF_0000n.usr

These text-files can be read by an text-editor. Don't save the files with the editor!. Each file delivers some informations for only one archive. We find filenames inside, pointing to other files of the archives of the disk. The files are used with all types of archives, but here we consider registration archives only.The files consist of blocks with the length of 16 bytes, that means that each line starts with a character at the byte-adress n*16. If we see less than 14 characters in a line, the line is filled with blanks. The lines end with the characters CR and LF (0x0d, 0x0a). There is one line with more than one 16-byte-block.

The files *.usr start with a file-header. At the beginning we read the actual filename (without delimiter ".") and it ends with the string "P,I". We find the keyboard-modelname PSR-740 and a version-string. I did not try to get more informations about the header.

 

After an empty line we find a decimal number of eight digits. This number is a measure of the volume of the archiv. Possibly it is only needed to show the process of loading the archive and it is not needed by any other function.

The content of the next line is the word SECTION08. Related with "08" we know, that there follow eight lines of same structure xxx,nn,mm,pppp . xxx is one of the abbreviations of the type of saved informations: MID, SET, REG, PAD, STY, VIC, TWK and EFF. nn, mm and pppp denote decimal numbers. If we only have saved registrations (file type = Regist), there is nn = 00 and mm = 00 for all xxx not equal REG: the numbers nn and mm in the line of REG are equal 01. If we have selected "Style + Reg.", the numbers nn and mm are 03 in the line of STY. The numbers 01 of REG are used by the software of the PSR-740 to identify the information in a later part of the file, which starts with the key REG. Here we find the filename RPKcccALREG. ccc is one of the numbers 001, 002, 003,...; with a constant value associated to a single archive.

The next line after "EFF,mm,nn,pppp" looks like

00000000,FFFFFFFF,00000007,00000000,00000000,030\

Example

In an archive with the user-defined name REG01 we have saved the registrations with the function "Regist". On the disk we find the file Reg01.usr. Behind the line SECTION08 there is the line REG,01,01,0368 . In the list, beginning with the line REG we find the only filename RPK001ALREG. xxx = 001 here is valid only, if the archive REG01 is the first one created on the floppy disk.


The File Reg.mng

The files RPKxxxAL.REG of all registration archives on a disk are stored in only one directory Reg with different numbers xxx. In Reg there is an additional file reg.mng with the following structure:

File-Header:

REG ;       MNG

FILEiii
FILE00000iii

iii is the number of all RPK-files of the directory Reg.

After this there follows for each RPK-File a block of same structure:

RPKxxxALREG
Regist01

PSR-740
VER1.00Rev0.00
A,I

00036864
  The last decimal number may be constant in all registration archives of the PSR-740.

The Structure of the files RPKxxxAL.REG

All these files have the fixed number of 0x9000 binary data-bytes. We find a header, followed by 128 data-blocks, each with a fixed length and a welldefined structure.

The data are stored at the following byte-positions:

Block Byte-Address Length
Header 0x0000 0x0080
Datablock 1 0x0080 0x011F
Datablock 2 0x019F 0x011F
... ... ...
... ... ...
Datablock 128 0x8EE1 0x011F
Summary   0x9000

The Header of RPKxxxAL.REG

The first block is a header with a length of 0x80 bytes. The content of the header are the same ASCII-characters as in the file reg.mng:

   

Example
00000000 5250 4B30 3031 414C 5245 4720 2020 0D0A RPK001ALREG   ..
00000010 5265 6769 7374 3031 2020 2020 2020 2020 Regist01
00000020 2020 2020 2020 2020 2020 2020 2020 0D0A               ..
00000030 5053 522D 3734 3020 2020 2020 2020 0D0A PSR-740       ..
00000040 5665 7231 2E30 3052 6576 302E 3030 0D0A Ver1.00Rev0.00..
00000050 412C 4920 2020 2020 2020 2020 2020 0D0A A,I           ..
00000060 2020 2020 2020 2020 2020 2020 2020 0D0A               ..
00000070 2020 2020 2020 2020 2020 2020 2020 0D0A               ..

The Datablocks of RPKxxxAL.REG

The next data following the header are 128 blocks, each of these with a length of 0x11F bytes. The block with the number "n" consists all saved informations of the "n"th registration.

   

Example of an datablock of the first registration:
00000000 5245 4730 3030 0000 0115 0000 0000 0000 REG000..........
00000010 5265 6769 7374 3031 2020 2020 2020 2020 Regist01
00000020 007F 0802 3600 6807 0F31 FF00 6247 3E24 ....6.h..1..bG>$
00000030 2C4F 2674 0040 4040 285F 3B52 4800 2C27 ,O&t.@@@(_;RH.,'
00000040 0037 3A5A 3718 0000 0014 1645 0056 0000 .7:Z7......E.V..
00000050 0000 0000 0000 0000 007F 0000 7F00 0000 ................
00000060 0021 0071 1900 001B 0070 5E00 7004 0070 .!.q.....p^.p..p
00000070 1500 0003 000A 7F00 7030 0064 5540 1600 ........p0.dU@..
00000080 0002 4040 0000 7F00 7230 0064 3C40 4300 ..@@....r0.d<@C.
00000090 0002 4040 00FF 0000 7034 005F 4B40 1800 ..@@....p4._K@..
000000A0 0002 4040 0000 045E 0000 0000 0100 0707 ..@@...^........
000000B0 0700 0000 0000 0111 190A 1C0A 3300 0000 ............3...
000000C0 0028 1003 4A07 4000 4040 4208 081D 4000 .(..J.@.@@B...@.
000000D0 001C 4033 427F 2844 0A00 0100 4000 4000 ..@3B.(D....@.@.
000000E0 0001 0001 7F40 0300 0111 0030 0001 1101 .....@.....0....
000000F0 2D00 0111 7F28 7F46 403C 0054 007F 2A5A -....(.F@<.T..*Z
00000100 1B40 0000 4000 0400 7F40 4040 4040 4040 .@..@....@@@@@@@
00000110 4040 4040 4000 1400 1A00 647F 005A 00   @@@@@.....d..Z.


The Structure of RPKxxxAL.REG Datablocks

The next list is a little part of all informations, which are stored in registrations.

 
Byte-adress No. of bytes Content
0x0000 0x0010 Registration-Name
0x0010 0x0010 Bank-Name
0x0020 0x0001 Style-Code
0x0025 0x0002 Tempo
0x0077 0x0003 Voice R1
0x0087 0x0003 Voice R2
0x0097 0x0003 Voice L

Registration-and Bank-Name

Each block starts with a 16-bytes-line with one of the names REG000, REG001,...REG127. The number denotes the number of the block. The following line of 16 bytes length contains the name of the registration-bank. Because each bank consists of the four registrations which can be selected by the four OTS-buttons, we find in each group of four registrations the same bank-name. The default bank-names are REGIST01, REGIST02,...REGIST32.

The names REG000 upto REG127 are not visible on the PSR-740. The bank-names are displayed only; these can be changed with the PSR-740. Renaming a bank, all the RPK-blocks of the bank will get the same new name then.

Datablock Reg.-Name Bank-Name
1 REG000 REGIST01
2 REG001 REGIST01
3 REG002 REGIST01
4 REG003 REGIST01
5 REG004 REGIST02
6 REG005 REGIST02
... ... ...
128 REG127 REGIST32
  Style-Code

The PSR-740 has got 160 internal styles with codes 0,1,...159 and 3 custom styles; codes 160, 161, 162. The codes are equal "Stylenumber-1" of the manual's Style List.

Tempo

The tempo is stored into the two bytes with the addresses 0x25 and 0x26 :

tempo = 256*<0x25>+<0x26>.

Voices

The PSR-740 has got 280 panel-voices and all the 480 XG-voices.

The voices are coded in the Data-Block by the three bytes MSB, LSB und Voice#: We find these values in the Voice List of the manual - the voice# used here is equal "Voicenumber-1" of the manual.


DSP Effects

DSP1:
Type MSB/LSB with the addresses 0xe8/0xe9;
On/Off with address 0xea (0 = On, 0x7f = Off).

DSP2:
Type MSB/LSB with the addresses 0xec/0xed;
On/Off with address 0xef (1 = On, 0x7f = Off).

DSP3:
Type MSB/LSB with the addresses 0xf2/0xf3;
On/Off with address 0xf4 (2 = On, 0x7f = Off).

Harmony
Type with the address 0x11c.
On/Off with the address 0x11b (On = 0x7f).

  List of Harmony types:
Harm. Type Code
Duet 0x00
1+5 0x01
Country 0x02
Trio 0x03
Block 0x04
4WayCls1 0x05
4WayCls2 0x06
4WayOpn 0x07
Octave 0x08
Strum 0x09
Echo 1/4 0x0b
Echo 1/6 0x0e
Echo 1/8 0x11
Echo 1/12 0x14
Tremolo 1/8 0x0c
Tremolo 1/12 0x0f
Tremolo 1/16 0x12
Tremolo 1/32 0x15
Trill 1/12 0x0d
Trill 1/16 0x10
Trill 1/24 0x13
Trill 1/32 0x16

Last remarks

With the informations here you now can try to find out the style, tempo and voices used with the registration's datablock above.

  The findings have been used to program the registration editor PSRREG. If you find a bug here or with PSRREG, send me a mail please.The program is freeware and can be downloaded from my website at http://heikoplate.home.pages.de. Look at Downloads > PSRREG.