Skip to content

Commit

Permalink
Documentation update
Browse files Browse the repository at this point in the history
  • Loading branch information
ZILtoid1991 committed Aug 5, 2023
1 parent a86fce5 commit 231442f
Show file tree
Hide file tree
Showing 2 changed files with 63 additions and 12 deletions.
48 changes: 36 additions & 12 deletions docs/design/delaylines.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,19 +8,43 @@
└─[FBOut A/B]────[To feedback]
```

## Effects layout

```
[Input A]──╔═══════╗ [LFO ×4] ╔═════╗
║Routing║───────────[DelayLineA/B]──────────║Mixer║─────[Output A/B]
[Input B]──╚═══════╝ FBOut└(Taps ×4) ╚═════╝
(IIR ×4)
```

## Effects properties

* 2 inputs and outputs
* 4 LFOs assignable to position and level
* 2 Delay lines, with each having 4 taps with a 16 element FIR line
* A mixer with 4×2 IIR filters for equalization
* A mixer with 4×2 IIR filters for equalization

## MIDI control change layout

Control change is mainly done on channels

### Taps

MSB 0 through 7 in the unregistered namespace represent each taps.

* LSB 0 through 15 set the FIR levels.
* LSB 16 through 19 are output Levels, including feedback (LRAB).
* LSB 20 sets the position of the tap.
* LSB 21 disables the tap. (Might result in performance gain).
* LSB 22 disables the FIR. (Might result in performance gain).

MSB 9 has all the EQ. Upper 3 bits of the LSB select the EQ, lower two bits set the given parameters:

* 0 sets the level between -0.5 and 1.0.
* 1 sets the mid frequency between 0 and 20 000 Hz.
* 2 sets the Q value (filter bandwidth).

MSB 10 contain the master values:

* LSB 0 through 3 set the input levels from various inputs of the module into the delay lines.
* LSB 4 through 5 set the master output levels.

# Module config parameters

DelayLines needs to be set up with two extra parameters in the audio config file, something like this:

```s
module "delaylines" "audiofx" 4096 4096
```

The 3rd and the 4th parameters set the length of the delay lines, and must be powers of two.
27 changes: 27 additions & 0 deletions docs/design/fm_synth.md
Original file line number Diff line number Diff line change
Expand Up @@ -349,6 +349,33 @@ The synth shares two LFOs (tremolo and vibrato) and four filters between channel
* `HPFBFreq` [15]: Sets the high-pass filter frequency for the Aux B channel (0-20 000Hz)
* `Ringmod` [16]: Enables ring modulation, by setting the tremolo frequency into audible territory and bypassing the aliasing filter.

# Special SysEx commands

## 7 Bit command 0x20

Layout:

`20 WF TY [...]`

`WF` choses the waveform to be set, `TY` sets the type of the waveform.

* 0x50 creates a pulse wave. It is followed by two bytes, which set the pulse-width of the wave.
* 0x54 creates a triangular wave. It is followed by two bytes, which set the sigma of the wave.
* 0x74 creates an integrated triangular wave. It is followed by two bytes, which set the sigma of the wave.
* 0x53 creates a sine wave. It is followed by four bytes, each which set a quadrant of the sine wave.

Sine wave quadrants can be defined with the following bits:

* bit 0 = If set, then the sine fragment is present. If not, this portion will be replaced with all zeros instead.
* bit 1-2 = Doubling mode:
* * 0 = No doubling.
* * 1 = Same cycle twice.
* * 2 = Same cycle mirrored, effectively putting a half-sine into a quarter with the right settings.
* * 3 = The second half is all zeros, the sine fragment is effectively "stuffed" into an eight of the waveform.
* bit 3 = Horizontal mirroring of the cycle.
* bit 4 = Vertical mirroring of the cycle.
* bit 5 = Modifies the curve of the sinewave for a bit more square-ish shape.

# Setting guidelines

* Small amounts of release times can function as a pop filter.
Expand Down

0 comments on commit 231442f

Please sign in to comment.