| MAGIC VOICE | Sprachtabelle - Speechtable |
![]() |
Allgemeines General |
Einführung Introduction |
Anschluss Connection |
Anwenden des Moduls Using the Module |
Vokabular Vocabulary |
Tips & Tricks Tips & Tricks |
| Ergänzendes Additional stuff |
Demos Demos |
Spiele Games |
Zeitschriften Magazines |
Sprach Downloads Speech Downloads |
Lexikon Lexicon |
|
| Internes Internal |
Hardware Hardware |
Firmware Firmware |
Sprachdaten Speechdata |
Bit-Format Bit allocation |
De-/Codierung De-/Coding |
|
| Nützliches und mehr Utilities and more |
Speech Playtool | Magic Game Cart | Magic Talkie | Magic Voice NT | Ersatzteile & Reparatur Spares & Repair |
| Das Vokabular des Magic Voice Moduls kann erweitert werden. Das Vokabular kann in den RAM Speicher des C64 geladen werden oder sich auf einem Steckmodul befinden. | The vocabulary of the Magic Voice Module can be extended. The vocabulary can be loaded into the RAM memory of the C64 or be on a cartridge. |
| Sprachtabelle - Speechtable |
Der Speicher für die Sprachdaten ist in zwei Bereiche aufgeteilt. Einer Nachschlagtabelle (lookup table) und den eigentlichen Sprachdaten.
Die Nachschlagtabelle ist wiederum in 3 Bereiche aufgeteilt:
Die Startadresse der Tabelle für die im Magic Voice vorhandenen Sprachdaten ist in der Firmware fest hinterlegt. Für die Tabelle der benutzerspezifischen Sprachdaten wird die Startadresse durch den VOC-Befehl angegeben. Header Der Header hat eine Länge von 4 Bytes. Die ersten zwei Bytes geben den Offset zur VOC-Adresse an, ab der die Tokenliste beginnt. Das 3. Byte ... Das 4. Byte ... Lookup Tabelle Direkt nach dem Header folgt die Lookup Tabelle. Hier sind die Startadressen (Offsets) zu den Sprachdaten der einzelnen Worte gespeichert. Jeder Tabelleneintrag zeigt also auf die Startadresse eines bestimmten Segments der Sprachdaten. Zum Verständnis muss man wissen, dass hier die Byte-Reihenfolge bei der Speicherung der Adressen in Big Endian (“Motorola-Format”) erfolgt. Dies ist entgegen der beim C64 üblichen Speicherung in Little Endian (“Intel-Format”). Die Adresse wird aus der Addition der Basisadresse (VOC) und einem Offset gebildet. Die Magic Voice Software übergibt einer Serviceroutine die Startadresse. Diese Routine liest über einen NMI die Sprachdaten und gibt sie an den Sprachchip weiter, bis in den Sprachdaten ein END-Code vorkommt. Tokenliste ... Die Tokenliste endet immer mit $00 $00. Auch wenn zu den Sprachdaten keine Token hinterlegt sind, sind diese zwei 0-Bytes vorhanden. |
The memory for the speechdata is divided into two sections. The lookup table and the actual voice data.
The lookup table is further divided into 3 sections:
The starting address of the table in the Magic Voice existing voice data is permanently stored in the firmware. For the table of user-specific voice data, the start address is specified by the VOC command. Header The header has a length of 4 bytes. The first two bytes specify the offset from VOC-address, from which the token list starts from. The 3rd Byte ... The 4th Byte ... Lookup Table Immediately after the header follows the lookup table. Here are the starting addresses (offsets) stored to the voice data of the individual words. Each table entry points to the starting address of a particular segment of speech data. To understand, you should know that here the byte order for storing the addresses in Big Endian (“Motorola format”) takes place. This is contrary to the usual C64 storage in Little Endian (“Intel”) format. The address is formed by adding the base address (VOC) and an offset. The Magic Voice software passes the start address to a service routine. This routine reads the voice data over an NMI and passes it to the voice chip, until in the voice data an END code is found. Tokenlist ... The tokenlist always ends with $00 $00. Even if the voice data are stored without tokens, these two 0-bytes exist. |
| Beispiel 1: (Tabelle aus dem Magic Voice Modul) | Example 1: (Table from the Magic Voice Module) |
| MAGIC VOICE MODULE | ||||||||
| Sprachtabelle - Speechtable | Sprachdaten - Speechdata | |||||||
| Address | Data | Address | Bemerkung | |||||
| Eprom | Memory | Eprom | Memory | |||||
| Start (VOC) | 1240 | B240 | $01 $DA | Start of Token-Table (=Offset to VOC) $1240 + $01DA = $141A |
||||
| unknown | 1242 | B242 | $B8 $00 | Demo: $17 $00 | ||||
| Look-Up Table: | Speech Data: (Startaddress = VOC + Offset) | |||||||
| Word-No. | Address | Data (Offset) | Startaddress | Data (Speech) | Bemerkung | |||
| 0 | 1244 | B244 | $03 $B2 | 15F2 | B5F2 | $4A . . . | "ZERO" ($1240 + $03B2 = $15F2) | |
| 1 | 1246 | B246 | $03 $E7 | 1627 | B627 | $4A . . . | "ONE" ($1240 + $03E7 = $1627) | |
| 2 | 1248 | $04 $12 | "TWO" | |||||
| 3 | 124A | $04 $33 | "THREE" | |||||
| 61 | 12BE | $0D $8E | 1FCE | BFCE | "WHEN" ($1240 + $0D8E = $1FCE) | |||
| Note: The Addressline CA14 of the C64 is connected to A13 of the Eprom. | ||||||||
| 62 | 12C0 | $2D $C0 | 2000 | E000 | "HAS" ($1240 + $2DC0 - $2000 = $2000) | |||
| 114 | 1328 | $36 $AA | "WAIT" used for word no. 233 ("WEIGHT") | |||||
| 198 | 13D0 | $45 $C5 | "OUR" used for word no. 234 ("HOUR") | |||||
| 230 | 1410 | $4C $7B | "SYMBOL" | |||||
| 231 | 1412 | $4C $B4 | "TAPE" | |||||
| 232 | 1414 | $4C $D9 | 3F19 | FF19 | $4A $71 $FB ... | "UP" | ||
| 233 | 1416 | $36 $AA | "WEIGHT" same data as word no. 114 ("WAIT") | |||||
| 234 | 1418 | $45 $C5 | 3805 | F805 | "HOUR" same data as word no. 198 ("OUR") | |||
| Word Tokens: (optional) | ||||||||
| Word-No. | Address | Data (Token) | Bemerkung | |||||
| 0 | 141A | $AF $46 | "ZERO" | |||||
| 21 | 1444 | $41 $00 | "A" | |||||
| 22 | 1446 | $42 $00 | "B" | |||||
| 234 | 15EE | $3D $7A | "HOUR" | |||||
| - | 15F0 | $00 $00 | Always $00 $00 | |||||
| Start of Speech Data: | ||||||||
| 0 | 15F2 | . | ||||||
| Hinweis: Die Adressleitung CA14 des C64 ist mit A13 (Eprom) verbunden. Zeigt die Sprachdaten-Adresse also im Eprom auf einen Wert >= $4000, so ist das $2000. Daher erklärt sich auch der Sprung in der Sprachdatentabelle von $BFFF nach $E000 |
Note: The Addressline CA14 of the C64 is connected to A13 (Eprom). xxx |
| Beispiel 2: (Tabelle aus dem Commodore V364) | Example 2: (Table from the Commodore V364) |
| Commodore V364 | ||||||||
| Sprachtabelle - Speechtable | Sprachdaten - Speechdata | |||||||
| Address | Data | Address | Bemerkung | |||||
| Eprom $ | Memory $ | Eprom $ | Memory $ | |||||
| Start (VOC) | 12F6 | 92F6 | $02 $0E | - | Size of Look-Up-Table (=Offset) End = $12F6 + $020E = $1504 |
|||
| ? | 12F8 | 92F8 | $FF $FF | - | unknown | |||
| Look-Up Table: | Speech Data: (Startaddress = VOC + Offset) | |||||||
| Word-No. | Address | Data (Offset) | Startaddress | Data (Speech) | Bemerkung | |||
| 0 | 12FA | 92FA | $04 $1A | $1710 | $4A . . . | "ZERO" ($12F6 + $041A = $1710) | ||
| 1 | 12FC | 92FC | $04 $4D | "ONE" | ||||
| 2 | 12FE | 92FE | $04 $7D | "TWO" | ||||
| 3 | 1300 | 9300 | $04 $9D | "THREE" | ||||
| 260 | 1502 | 9502 | $2C $AC | "THINGS" | ||||
| Word Tokens: (optional) | ||||||||
| Word-No. | Address | Data (Token) | Bemerkung | |||||
| 0 | 1504 | $xx $xx | "ZERO" | |||||
| 1 | 1506 | $xx $xx | "ONE" | |||||
| 260 | XXXX | $xx $xx | "THINGS" | |||||
| - | XXXX | $00 $00 | Always $00 $00 | |||||
| Start of Speech Data: | ||||||||
| 0 | 1710 | . | ||||||
| Speicherung der Sprachdaten - Storage of the Speechdata |
|
Für jede Phrase (Wort) sind neben den eigentlichen Sprachdaten im ersten Byte auch die Parameter für die Synthesizer Einstellungen gespeichert. |
For each phrase (word) the parameters for the synthesizer settings are stored in the first byte, followed with the actual voice data. |
|
Das Low Nibble entspricht genau den Bits, die man beim 2-Nibble Befehl CNDT 2 ($7, Condition 2) des T6721A als 2tes Nibble angibt.
Beim lesen der Sprachdaten speichert die Firmware dieses Nibble zunächst an der Adresse $A3EB ab. |
The low nibble is equivalent to the bits, which are used as 2nd nibble for the 2-nibble command CNDT 2 ($7, Condition 2) for the T6721A.
When the speechdata are read, the firmware stores this nibble at first at address $A3EB. |
| Bit | Function | Set 0 | Set 1 |
| 0 | Filter stages | 10 | 8 |
| 1 | Repeat | available | not available |
| 2 | Frame length | 20 ms/frame | 10 ms/frame |
| 3 | Bits/Frame | 48 bits/frame | 96 bits/frame |
|
Das Bit 4 und 5 entspricht dem Bit D2 und D3, die man beim 2-Nibble Befehl CNDT 1 ($6, Condition 1) des T6721A als 2tes Nibble angibt.
D0 und D1 sind bei diesem Befehl immer 0. Beim lesen der Sprachdaten speichert die Firmware dieses Nibble zunächst in $A3E9 ab. Ist Bit 6 (oder Bit 7) gesetzt, werden die Sprachdaten dekomprimiert und dem T6721A zur Sprachausgabe übergeben. Bei gelöschtem Bit werden die Sprachdaten als unkomprimiert interpretiert und direkt dem T6721A weitergereicht. Diese Bits werden in $C3D7 an Bitposition 4 und 5 abgespeichert, alle anderen Bits werden gelöscht. |
Bit 4 and bit 5 corresponds to bit D2 and D3, which are used with the 2-nibble command CNDT 1 ($ 6, Condition 1) of the T6721A as 2nd nibble.
D0 and D1 are in this command always 0. When reading the speech data, the firmware stores this nibble at first in $A3E9. If bit 6 is set (or bit 7), the voice data is decompressed and delivered to the T6721A for speech output. When bit is cleared, the voice data is interpreted as uncompressed and directly passed to the T6721A. These bits are stored in $C3D7 at bit position 4 and 5, and all other bits will be cleared. |
| Bit | Function | Set 0 | Set 1 |
| 4 | Loss effect calculation | none | available |
| 5 | Sound source shape | Pitch | Triangle |
| 6 | Speech Data | Uncompressed | Compressed |
| 7 | ? not used, same as Bit 6 | - | - |