Changes in readme.txt [3523847:8e1b163] in buchla-emu
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
readme.txt
r3523847 r8e1b163 26 26 https://libsdl.org/ 27 27 28 The SDL2 website also hosts the SDL2_net and SDL2_ttf projects, which 29 add support for networking and TrueType fonts to SDL2 30 31 SDL2_ttf, in turn, requires the FreeType library, which is available 32 from the FreeType website: 28 The SDL2 website also hosts the SDL2_ttf project, which adds support 29 for TrueType fonts to SDL2. SDL2_ttf, in turn, requires the FreeType 30 library, which is available from the FreeType website: 33 31 34 32 https://www.freetype.org/ … … 69 67 make install 70 68 71 # Build and install SDL2_ttf , now that we have FreeType and SDL269 # Build and install SDL2_ttf last 72 70 73 71 tar zxvf SDL2_ttf-2.0.14.tar.gz … … 78 76 ../configure --prefix=/opt/sdl2 \ 79 77 --with-sdl-prefix=/opt/sdl2 --with-freetype-prefix=/opt/sdl2 80 81 make82 make install83 84 # Build and install SDL2_net last85 86 tar zxvf SDL2_net-2.0.1.tar.gz87 cd SDL2_net-2.0.188 mkdir build89 cd build90 91 ../configure --prefix=/opt/sdl2 --with-sdl-prefix=/opt/sdl292 78 93 79 make … … 113 99 Then, to cross-build the emulator, invoke 114 100 115 make buchla .exeWIN=1101 make buchla WIN=1 116 102 117 103 from the top-level directory of this repository. Defining the "WIN" 118 104 variable selects the cross-toolchain and "/opt/sdl2-win" as the 119 105 library directory. 120 121 In addition to the emulator, we need to build the mkdisk utility,122 which we'll use to create a 720-KiB floppy disk image that can be read123 by the Buchla firmware.124 125 Building mkdisk works pretty much like building the emulator. On Linux126 and OS X, invoke127 128 make mkdisk129 130 from the top-level directory of this repository. To cross-build the131 Windows version, invoke132 133 make mkdisk.exe WIN=1134 135 instead.136 137 138 Running the emulator139 --------------------140 141 This is where this repository, buchla-emu, meets its companion142 repository, buchla-68k. We assume that you built the following files143 according to the instructions in the buchla-68k repository:144 145 bios.abs146 midas.abs147 148 Please copy (or symlink) them into the top-level directory of this149 repository, buchla-emu.150 151 bios.abs contains the Buchla 700's BIOS code. The file is loaded by152 the emulator directly to emulate the BIOS PROM.153 154 midas.abs is the MIDAS VII software. Unlike the BIOS, which resides in155 a PROM, it is loaded from a floppy disk. To create this floppy disk,156 we need the mkdisk utility.157 158 mkdisk expects to be run from inside the directory that contains159 midas.abs and produces a disk image file, buchla.disk in the same160 directory. For example, on Linux:161 162 ~/buchla-emu$ ls -l midas.abs163 lrwxrwxrwx 1 emu emu 23 Jul 30 18:07 midas.abs -> ../buchla-68k/midas.abs164 ~/buchla-emu$ ./mkdisk165 ~/buchla-emu$ ls -l buchla.disk166 -rw-r--r-- 1 emu emu 737280 Aug 6 09:44 buchla.disk167 168 Now we have everything in place to run the emulator. On Linux and OS X169 you can invoke it directly from the top-level directory of this170 repository:171 172 ~/buchla-emu$ ./buchla173 174 If you prefer to install the emulator elsewhere, be sure to copy the175 following files:176 177 buchla | buchla.exe emulator executable (.exe for Windows)178 ttf/vera-sans-mono.ttf emulator font179 bios.abs BIOS code180 buchla.disk disk image181 182 This also applies to copying the cross-compiled Windows emulator to a183 Windows machine.184 185 If you would like to keep the BIOS code, disk image, and font separate186 from the emulator executable, check out the emulator's -b, -d, and -f187 command line options. Use -h for an overview of all available options.188 189 190 Cross-debugging the firmware191 ----------------------------192 193 While the emulator is running, it listens on TCP port 12053 for194 incoming connections from a GDB cross-debugger. This allows for195 comfortable source-level debugging of the cross-compiled BIOS and196 MIDAS VII code, while it runs in the emulator.197 198 We assume that you have a GCC cross-toolchain in /opt/cross-m68k, as199 described in the buchla-68k repository. Based on that, we build a200 GDB cross-debugger:201 202 # If you haven't yet done so, add the cross-toolchain to your203 # PATH, so that the GDB build can find it.204 205 export PATH="/opt/cross-m68k/bin:${PATH}"206 207 tar zxvf gdb-7.12.tar.gz208 cd gdb-7.12209 210 mkdir build211 cd build212 213 ../configure --prefix=/opt/cross-m68k --target=m68k-none-elf214 215 make -j2216 make install217 218 The Buchla firmware uses its own (Atari-like) object and executable219 file format. However, the cross-toolchain and the cross-debugger220 support the ELF standard.221 222 When you built the BIOS and MIDAS VII software, you ended up with two223 files in the Buchla's executable file format, bios.abs and midas.abs.224 However, the cross-build process also produces matching ELF files,225 bios.elf and midas.elf, suitable for the cross-debugger.226 227 Depending on whether you would like to cross-debug the BIOS or MIDAS228 VII, you'd specify either bios.elf or midas.elf when invoking the229 cross-debugger.230 231 To follow along the following example, copy (or symlink) bios.elf and232 midas.elf from the buchla-68k repository into the top-level directory233 of this repository.234 235 In order to open a debug session for the BIOS, run the cross-debugger236 with bios.abs and connect it to the running emulator using GDB's237 238 target remote :12053239 240 command. 12053 is the port on which the emulator listens for incoming241 GDB connections.242 243 host:~/buchla-emu$ m68k-none-elf-gdb ./bios.elf244 GNU gdb (GDB) 7.12245 Copyright (C) 2016 Free Software Foundation, Inc.246 [...]247 (gdb) target remote :12053248 Remote debugging using :12053249 trwzsup () at rom/bios.s:832250 832 move.l 0(a0,d0),d0 | Get routine address251 (gdb)252 253 From here on, everything is pretty much standard GDB, for example:254 255 (gdb) break pscan256 Breakpoint 1 at 0x105a64: file rom/romp.c, line 3403.257 (gdb) cont258 [...]259 (gdb) bt260 #0 pscan () at rom/romp.c:3403261 #1 0x00105e96 in main () at rom/romp.c:3587262 #2 0x00105fd6 in Croot (cp=0x0) at prolog/croot.c:141263 #3 0x00105f52 in start1 () at prolog/fsmain.s:59264 (gdb)265 266 In order to debug MIDAS VII, run the cross-debugger with midas.elf,267 instead:268 269 host:~/buchla-emu$ m68k-none-elf-gdb ./midas.elf270 GNU gdb (GDB) 7.12271 Copyright (C) 2016 Free Software Foundation, Inc.272 [...]273 106 274 107 … … 285 118 * Motorola MC6840: Timers. 286 119 287 * Rockwell R65C52: Serial console and MIDI ports.120 * Motorola MC6850: Serial console and MIDI ports. 288 121 289 122 * Epson SED1335: LCD controller. … … 333 166 334 167 2. A second chip for the actual sound generation. This is likely 335 a DSP. 168 a DSP, possibly a Hitachi HD61810, which supports a 16-bit 169 floating-point format that's also found in the firmware 170 source code (12-bit mantissa, 4-bit exponent). 336 171 337 XXX - Details to be filled in. 172 This chip takes in the current levels of a voice's envelopes 173 and, based on them, performs the FM synthesis for this voice 174 by modulating the user-drawn carrier waves A and B according 175 to the selected FM configuration (algorithm). 338 176 339 177 We don't know how many of the envelopes not related to FM … … 352 190 would be great to be able to compare the emulation to real hardware. 353 191 354 If your Buchla is non-functional, this is also fine. We might be able355 to gain some insights from reading outthe FPU microcode PROMs.192 If it's non-functional, this is also fine. We might be able to gain 193 some insights from reading the FPU microcode PROMs.
Note:
See TracChangeset
for help on using the changeset viewer.