source: buchla-emu/readme.txt@ 4f3fe48

Last change on this file since 4f3fe48 was 4f3fe48, checked in by Thomas Lopatic <thomas@…>, 7 years ago

Support cross-build for Windows.

  • Property mode set to 100644
File size: 5.6 KB
RevLine 
[0efe297]1Buchla 700 Hardware Emulator
2----------------------------
3
4This repository, buchla-emu.git, contains a software emulation of the
5Buchla 700's hardware.
6
7It is minimalistic; it emulates just enough of the hardware to be able
8to run the firmware from the companion repository, buchla-68k.git.
9
10We don't have access to original hardware, so this is our best guess
11based on the firmware source code published by Lynx Crowe - the
12firmware's developer - via Aaron Lanterman:
13
14 http://lanterman.ece.gatech.edu/buchla700/
15
16See the buchla-68k.git repository for the firmware source code.
17
18
19Building the emulator
20---------------------
21
22The emulator uses SDL2, an abstraction layer for low-level machine
23access on Linux, OS X, and Windows. It can be obtained from the
24project's website:
25
26 https://libsdl.org/
27
[2f9f352]28The SDL2 website also hosts the SDL2_ttf project, which adds support
29for TrueType fonts to SDL2. SDL2_ttf, in turn, requires the FreeType
30library, which is available from the FreeType website:
31
32 https://www.freetype.org/
33
[4f3fe48]34Currently, we build the emulator code natively on Linux and OS X. The
35Windows version is cross-compiled on Linux using a x86_64-w64-mingw32
36toolchain.
[0efe297]37
[4f3fe48]38For Linux and OS X, our Makefile expects all of the above libraries to
39reside in /opt/sdl2. This is how we typically install them:
[2f9f352]40
41 # Build and install FreeType first
42
43 tar zxvf freetype-2.7.1.tar.gz
44 cd freetype-2.7.1
45 mkdir build
46 cd build
47
48 # Skip the optional features (compressed fonts, etc.) that would
49 # create more dependencies
50
51 ../configure --prefix=/opt/sdl2 \
52 --without-zlib --without-bzip2 --without-png --without-harfbuzz
53
54 make
55 make install
56
57 # Then build and install SDL2
[0efe297]58
59 tar zxvf SDL2-2.0.5.tar.gz
60 cd SDL2-2.0.5
[2f9f352]61 mkdir build
62 cd build
63
64 ../configure --prefix=/opt/sdl2
[0efe297]65
[2f9f352]66 make
67 make install
68
69 # Build and install SDL2_ttf last
70
71 tar zxvf SDL2_ttf-2.0.14.tar.gz
72 cd SDL2_ttf-2.0.14
[0efe297]73 mkdir build
74 cd build
75
[d94a7be]76 ../configure --prefix=/opt/sdl2 \
77 --with-sdl-prefix=/opt/sdl2 --with-freetype-prefix=/opt/sdl2
[2f9f352]78
[0efe297]79 make
80 make install
81
[2f9f352]82Now that we have everything in place, invoke
[0efe297]83
84 make buchla
85
86from the top-level directory of this repository to build the emulator.
87
[4f3fe48]88The cross-build for Windows is done similarly, with the following
89differences when configuring the libraries:
90
91 * We use "--prefix=/opt/sdl2-win" instead of "--prefix=/opt/sdl2",
92 so that the Windows versions of the libraries go to a different
93 directory.
94
95 * We additionally specify "--host=x86_64-w64-mingw32" to enable
96 cross-compilation.
97
98Then, to cross-build the emulator, invoke
99
100 make buchla WIN=1
101
102from the top-level directory of this repository.
103
[0efe297]104
105Emulated hardware
106-----------------
107
108Here's what we emulate:
109
110 * Motorola 68000 CPU. This is actually the Musashi CPU emulator by
111 Karl Stenerud:
112
113 https://github.com/kstenerud/Musashi
114
115 * Motorola MC6840: Timers.
116
117 * Motorola MC6850: Serial console and MIDI ports.
118
119 * Epson SED1335: LCD controller.
120
121 * Intel 82716: Video chip.
122
123 * National Semiconductor LMC835: Equalizer.
124
125 * General Instrument AY-3-8910: A sound chip, which is not used for
126 sound generation, but only for its I/O ports. It connects the CPU
127 to the above equalizer chip.
128
129 * Western Digital WD1772: Floppy disk controller.
130
131 * A few LEDs.
132
133 * Item X: A program running on a microcontroller. It converts the
134 analog signals from the Buchla's controller pads to digital
135 values.
136
137 Neither the program, nor the microcontroller are known, but the
138 protocol (known from the firmware source code) is pretty simple
139 and self-explanatory.
140
141 * Item Y: The actual sound generator, referred to by the firmware
142 source code as "the FPU." This could actually be two chips:
143
144 1. One chip, maybe a DSP, for generating the 15 different
145 parameter envelopes for each of the 12 voices:
146
147 - 4x FM modulator (oscillator) frequency.
148
149 - 6x FM modulator (oscillator) envelope.
150
151 - 1x Output signal amplitude envelope.
152
153 - 1x Output signal filter envelope.
154
155 - 1x Output signal filter resonance envelope.
156
157 - 1x Output signal stereo location.
158
159 - 1x "Dynamics." (TBD - currently not emulated.)
160
161 Over time, the chip interpolates between the points of the
162 envelopes drawn in the MIDAS VII instrument editor.
163
164 2. A second chip for the actual sound generation. This is likely
165 a DSP, possibly a Hitachi HD61810, which supports a 16-bit
166 floating-point format that's also found in the firmware
167 source code (12-bit mantissa, 4-bit exponent).
168
169 This chip takes in the current levels of a voice's envelopes
170 and, based on them, performs the FM synthesis for this voice
171 by modulating the user-drawn carrier waves A and B according
172 to the selected FM configuration (algorithm).
173
174 We don't know how many of the envelopes not related to FM
175 (e.g., the filter) are actually used digitally. At least some
176 of the envelopes probably control analog circuits.
177
178 Obviously, the emulator does everything digitally.
179
180 This "two chip" hypothesis would be in line with the "four
181 computers" marketing claim from the Buchla 700 marketing copy. The
182 four "computers" would be the Motorola 68000, the microcontroller
183 that does the A/D conversion of the pad inputs, plus the two CPUs
184 that constitute "the FPU."
185
186If you have access to an actual Buchla 700, please do contact us. It
187would be great to be able to compare the emulation to real hardware.
[ed545d5]188
189If it's non-functional, this is also fine. We might be able to gain
190some insights from reading the FPU microcode PROMs.
Note: See TracBrowser for help on using the repository browser.