Last modified on 17 December 2010, at 16:06

MEA8000 Voice Generator


Overview

Voiced (Sawtooth)           <-------- Digital Filters --------->
 ________     ______
|        |   |      |
| PITCH  |---| AMPL |--o    _____     _____     _____     _____     _____
|________|   |______|   \  | FM1 |   | FM2 |   | FM3 |   | FM4 |   |     |
 ________     ______     o-| BW1 |---| BW2 |---| BW3 |---| BW4 |---| DAC |--->
|        |   |      |      |_____|   |_____|   |_____|   |_____|   |_____|
| RANDOM |---| AMPL |--o
|________|   |______|

Unvoiced (Noise) (when PI=-16)

Digital Filters (processed on each 8kHz sample)

Each of the four filter stages works like so:

 fm_cos = cos(+2*pi * fm_Hz/8096Hz)*2
 bw_exp = exp(-1*pi * bw_Hz/8096Hz)
                             _____                            _____
 ---sample----------------->|     |------------------------->|     |---+--->
         _______________    | ADD |        ______________    | ADD |   |
    +-->|*-bw_exp*bw_exp|-->|_____|   +-->|*fm_cos*bw_exp|-->|_____|   |
    |   |_______________|    _____    |   |______________|    _____    |
    +-----------------------|OLDER|<--+----------------------| OLD |<--+
                            |_____|                          |_____|

Pitch Generator (Sawtooth) (active when PI<>-16)

Based on 3 registers: SAW_LEVEL is probably signed 13bit, P is probably unsigned 9bit, PI is signed 5bit. The following is processed every 125us (8kHz):

 SAW_LEVEL=(SAW_LEVEL+P) AND 1FFFh   ;sawtooth (-1000h..+0FFFh)
 sample = SAW_LEVEL * AMPLITUDE      ;volume

And, additionally, every 8ms (125Hz):

 P=(P+PI) AND 1FFh    ;the "AND 1FFh" is assuming that P is only 9bit wide

Noise Generator (Random) (active when PI=-16)

The following is processed every 125us (8kHz):

 NOISE_LEVEL=random(-1000h..+0FFFh)  ;random
 sample = SAW_LEVEL * AMPLITUDE      ;volume

The exact random algorithm is unknown (one information fragment implies that it is done by some ADD/MULTIPLY logic) (not sure if that is true, it may also be simple SHIFT/XOR or so).

Linear Interpolations (AMPL/FM/BW)

Changes to AMPL,FM,BW are applied by interpolation (ie. not abruptly) (ie. it takes whatever time until the new setting is reached... the interpolation speed is unknown; it is merely described to depend on FD... Probably it's meant to be the whole FD period, ie. the new Target value isn't reached until the END of the frame).

DAC Output

The 8kHz samples (coming from the filters) are resampled to 64kHz samples using linear interpolation, for example, if each "_" is a 8kHz sample:

         _     ______                                  _____
 8kHz  __ _____      _____    --->      64kHz __/\____/     \____

The 64kHz samples are then passed to an 8bit D/A converter. According to the french datasheet, the 8bit DAC internally consists of two 4bit DACs (one for LSBs, one for MSBs) whose outputs are merged together via 1:16 resistors or so.

Oscillator

The device can be driven by a 3.84MHz crystal, or external TTL clock of max 4MHz). The 8kHz sample rate, timings, and pitch/filter frequencies in this doc apply for the recommended 3.84MHz.