Subject: Re: I want Mockingboard info From: Rubywand Date: Mon, Nov 16, 1998 1Ç21 Message-id: <364FE09E.CF628D15@swbell.net> Kimio Itoh writes ... > > I saw Mockingboard info on this ng about 1-2 years ago,and I downloaded it. > BUT now I found I was lost that log..... > > Can you post Mockingboard info? > > Kimio Itoh > kitoh@nn.iij4u.or.jp Below is a snip from the current Csa2 FAQs Sound Q&A: >> 009- Does anyone know where I can get some details on MockingBoard hardware and programming? MockingBoard Mini-Manual 11/97 version From: Rubywand Part 1: Kinds of MockingBoards The original MockingBoards come in four basic 'flavors': Sound I-- produces music tones and a variety of sound effects (3 voices to 1 Audio Output) Speech I-- produces speech or limited sound effects (1 voice output to 1 Audio Output) Sound II-- 2 x Sound I on a single board (3+3 voices to 2 Audio Outputs) Sound/Speech I-- Sound I + Speech I on a single board (3+1 voices to 2 Audio Outputs) Note ... Audio Output: This goes to a speaker or hi-fi amplifier Voice: a musical note, sound effect, speech sound, etc. Quite a few of the original MockingBoards were sold. Later MB's use model names like "MockingBoard A", etc.. The main difference between the original series and letter-named boards is wider availability of Speech. Edhel Iaur and Mike Mahon supplied details on models A-D. Prices are from a Sweet Micro Systems ad in the December, 1985 issue of _A+_ magazine: MockingBoard A is a stereo music and sound synthesizer with six voices. Suggested retail price is $99.00. This model has two sockets for adding speech synthesis IC's so that a user could add speech to one or both Audio Outputs. Except for the speech upgrade options, MB-A is very similar to the earlier Sound II. "MockingBoard B" is just the name of the Speech Upgrade; it is not a separate MB board. The kit consists of one speech synthesizer chip. Earlier MB's used the 16-pin SC-01 speech IC, while later board runs provided 24-pin sockets for the newer (but somewhat flawed) SSI-263 speech synthesizer chip. Suggested kit retail price is $89.00. MockingBoard C is simply a MB-A that has been upgraded by plugging in one speech chip. Suggested retail price is $179.00. (There was an 'undocumented' upgrade, obtainable by plugging in the other speech chip, which allowed the board to "sing harmony" with itself!) MockingBoard D is a stereo music, sound and speech synthesizer for the Apple IIc. It connects to a IIc through a serial port and is, of course, external (unlike the Slot board models for other Apple II's). Its drivers are very different from the slot I/O of the other MockingBoards. Suggested retail price is $195.00. Phasor is a MockingBoard-compatible sound card produced by Applied Engineering. Looking at the software that comes with the Phasor may be helpful to MB users. MockingBoards work on Apple II's with at least 48K RAM. MB can go into any Slot (except for MB-D, which must plug into a IIc). Most programs expect it to be in Slot 4; however, it is fairly common for a program which supports MB to ask you to enter the Slot #. Most for-MB products will work with Sound I, Sound II, Sound/Speech I, A, and C. (Some work with D.) Products that use MB include Ultima III, IV, V Sky Fox, Wiley Byte', Thunder Bombs, Lancaster, Under Fire, Music Construction Set, GuitarMaster, and Music Star. MB's 0.5 Watt Audio Output(s) can directly drive an 8 Ohm speaker. You can also run the Output(s) to a hi-fi amplifier. Except for speech-only models, MB uses the General Instruments AY-3-8910 Programmable Sound Generator IC. The PSG has 3 on-chip tone oscillators (via channels A, B ,C) and a Noise Generator (NG). So, for example, the Sound II can play up to 6 notes or effects at once. The NG on each PSG can be mixed with any, all, or none of the three tones. Many MB "Speech" version boards use the Votrax SC-01 Speech Synthesizer IC. The SC-01 uses 64 phoneme sounds to produce speech. MB software lets you adjust duration of each phoneme in 4 steps, create "rules" for custom sounds, and speak sentences from text in BASIC programs. The SSI-263 speech synthesizer appeared on later model MB's. (At present, more info on the SSI-263 is not included here.) All MB versions use the 6522 Versatile Interface IC to handle board I/O. Except for the Sound I board, early models have circuit board points to which you can add cables to utilize I/O ports not needed for Sound or Speech. Part 2: Sound Programming Each Programmable Sound Generator (PSG) has 3 output Channels: A, B, and C. There are also 3 Tone oscillators, one committed to each Channel, and one Noise Generator (NG) which can send its output to any Channel(s). Amplitude (output Level or Volume) and Envelope Control ON/OFF is set for each Channel. The PSG's Enable/Disable register has 8 bits. Three bits let you decide whether or not to send a Tone oscillator''s output to its Channel. For example, you can enable Tone outputs for the oscillators going through Channels A and B while disabling Tone output for the oscillator connected to Channel C. The Enable/Disable register also lets you decide whether or not to send the Noise Generator's output through a Channel. Three bits let you decide which Channel(s) the NG's output will go through. For example, you can enable NG output through Channels A and C but not through B; or, disable NG output through all three Channels, etc.. If, for example, Channel A's Tone oscillator output is enabled and NG output is enabled for Channel A, then, a mixed Tone + NG signal will go through Channel A. Setting Channel A's Amplitude controls the Level for the mixed signal. Often, a programmer will want to individually control the Levels of Tone outputs (for music) and Noise outputs (for sound effects). This is accomplished by using one PSG Channel only for Noise and two Channels only for Tones. Since the MB Sound II has 2 PSG's, a typical game application using the board will have 4 music tones and 2 effects sounds-- each individually controlled for Level. More specifically, the user can set Tone Frequency (12 bits, 4 coarse & 8 fine) and Amplitude (4 bits) for each channel individually. A fifth Amplitude bit lets you decide if a channel's Level will be "fixed" (use the Level value) or "variable" (i.e. follow the current Envelope pattern). You have 4 bits to set Noise Generator Frequency. Tone Freq = A2 Clock Freq/ [ (4096 x Coarse) + (16 x Fine) ] Noise Freq = A2 Clock Freq/ (16 x NG value) The Envelope of the combined outputs of enabled sources can be controlled for Period (16 bits, 8 coarse & 8 fine)** and, roughly, for Shape (4 bits). Env Freq = A2 Clock Freq/ [ (65536 x Coarse) + (256 x Fine) ] The registers of the PSG are described briefly below: Reg. Function and Bit(s) used 00 A Freq. fine (bits 0-7) 01 A Freq. coarse (bits 0-3) 02 B Freq. fine (bits 0-7) 03 B Freq. coarse (bits 0-3) 04 C Freq. fine (bits 0-7) 05 C Freq. coarse (bits 0-3) 06 NG Freq. (bits 0-4) 07 Enable/Disable note: Enable =0/ Disable =1 bit 5: NG sent to A bit 4: NG sent to B bit 3: NG sent to C bit 2: A Tone bit 1: B Tone bit 0: C Tone Ex: Writing $F0 to Reg 07 plays tones A, B, C plus noise on C Ex: Writing $F8 to Reg 07 plays tones A, B, C and no noise 08 A Level (bits 0-3) and Envelope Control (bit 4): 1 = Use Env; 0 = Use Level value 09 B Level (0-3) and Envelope Control (bit 4): 1 = Use Env; 0 = Use Level value 0A C Level (0-3) and Envelope Control (bit 4): 1 = Use Env; 0 = Use Level value 0B Envelope Period Fine (bits 0-7) 0C Envelope Period Coarse (bits 0-7) 0D Envelope Shape (four bits): Continue (bit 3) 0= do 1 cycle and set Level to zero Attack (bit 2) 1= count up 0= count down Alternate (bit 1) 1= reverse count direction each cycle Hold (bit 0) 1= do 1 cycle and hold count To program the MB you write to the board's 6522 I/O chip(s). All address references here are for a MB Sound II (2 Audio Outputs) in Slot 4. $C400 ORB1 function to perform, Output 1 $C480 ORB2 function to perform, Output 2 $C401 ORA1 data, Output 1 $C481 ORA2 data, Output 2 $C402 DDRB1 data direction, Output 1 $C482 DDRB2 data direction, Output 2 $C403 DDRA1 data direction, Output 1 $C483 DDRA2 data direction, Output 2 Before sending music, etc. data to the MB you must Initialize the board's I/O. To Initialize the 6522's: Store $FF at $C402 and the other three DDRxx addresses. This needs to be done by your program just once. Your program gets access to a PSG via the 6522 by using a few basic Function codes which set the PSG's I/O control lines: Set Inactive = $04 Set PSG Reg# = $07 Write Data = $06 Reset = $00 To Write to a PSG register: Tell the PSG which Register you wish to access (i.e. Set the "current register" #) and Write the data. This is easiest to do with subroutines to handle the basic Functions. Example Subroutines (for Output Channel 1): Set Reg # 1000: A9 07 8D 00 C4 A9 04 8D 00 C4 60 Write Data 100B: A9 06 8D 00 C4 A9 04 8D 00 C4 60 Notice that each Function sub ends by setting the PSG control lines to Inactive. Similarly, to do a Reset (set all PSG regs to zero) ... Reset 1016: A9 00 8D 00 C4 A9 04 8D 00 C4 60 To put the value $55 in PSG Register 02 (Channel B Freq. fine) .... 1080: A9 02 put Reg# in A (6502 accumulator register) 1082: 8D 01 C4 store A at the Data address ORA1 1085: 20 00 10 JSR to Set Reg# (sets "current register" to Reg 2) 1088: A9 55 put the value $55 in A 108A: 8D 01 C4 store A at the Data address ORA1 108D: 20 0B 10 JSR to Write Data ($55 goes into PSG Register 2) 1090: 60 Exit from subroutine ---------------------------- 010- How do I get my MockingBoard to work on my GS? You need to go to the GS Control Panel and change the Slots setting for the Slot your MB card is in to "Your Card". The 'standard' place for a MockingBoard is Slot 4. A few early programs require that the board be there in order to work; but, most programs which use MB will let you specify the Slot. A few games and other wares require modifications or interface software to work with MB on a GS. --------------------------- 011- I have a Mockingboard Sound II board installed in my GS but cannot get it to work with Ultima IV and Ultima V. How can I play these games with MockingBoard music and sound effects? U4MOCKV2.SHK is a collection of programs which will let you play Ultima IV on your GS with MockingBoard sound. You can also set game speed and border color. For playing Ultima V with MB sound, check out U5MBONGS.SHK. Both of these wares take care of activating the MockingBoard Slot without changing Control Panel settings. You can find them on Ground in the AOL area: ground.ecn.uiowa.edu/2/apple2/Collections/AOL/Games/Adv./Roleplay ____________________________ From: Tom Mage 012- How can I get 'regular Apple sound' (like BEEPs, etc.) to play through my Mockingboard's outputs? I recently got a Mockingboard C, which, it turns out, has a plug and cable specifically for connecting in sound from the Speaker! (Most likely, the MB A has a similar connection.) ---------------------------- From: Rubywand Evidently, older Mockingboards (like our Sound II) do not include the built-in Speaker connection; so, users with these boards will need to do a simple mod. The Apple II speaker is in the Collector circuit of the sound output transistor-- one end of the spkr goes to a resistor and capacitor connected to the output transistor Collector and the other goes to +5V (not ground). To get an audio output signal, the spkr must be in place; or, you can substitute a 1 watt resistor-- something in the 22-39 Ohm range. The output should come from the side of the spkr (or 1 watt resistor) going to the resistor & capacitor connected to the transistor-- i.e. the side which is _not_ the +5V side. The output goes through a coupling capacitor to the center lead of your RCA plug. The Ground side of the RCA plug goes to ground. "Ground" is DC ground = any motherboard trace area which is connected to the ground side of the power supply. For example, the outside "shell" of the composite video output is soldered to ground. Here is a rough picture ... +5V side | | []< Speaker or 27 Ohm resistor | |---------------------|(--)|------------------------ Output | 10uF 10uF to Amplifier | 2 caps connected as bi-polar capacitor | Transistor _________________ Ground side | DC Ground You can get a bi-polar coupling capacitor at Radio Shack (2uF-5uF is fine) or make one by connecting two 10uF caps neg end to neg end. (The value is not critical, two 5uF caps connected back to back is fine.) ---------------------------- From: Michael Mahon For the vast majority of connections to external amplifiers, a non-polarized capacitor is not required in this circuit, precisely _because_ the transistor side of the capacitor never goes below ground. A 4.7 uF capacitor, with the (+) side toward the transistor collector and the (-) side toward the amplifier will do the job nicely. ____________________________ << Ribywand