It can’t really be put off any longer: I’ve been writing the parameter and patch management part of OSCar.
Most of the knobs that a musician can tweak are mapped somehow to software parameters that begin and end their lives in a small block of memory. Aside from responding to a tweaked knob, these parameters must do a lot of dull but essential work:
- They must be constrained to sensible minimum and maximum values.
- Whenever they are changed on the synthesiser, we must send unique MIDI control messages so that the player can record any changes they make during a performance.
- Those control messages must then be mapped back to the controls, so that MIDI replay also works. This makes movements like filter sweeps and small changes in timbre easier to time, control, and edit.
- Patch saving and loading functions need to move whole blocks of parameters between the current memory and some larger storage area.
- Changes to the parameters, by whatever means, need to be tracked and relayed to the sound-producing parts of the synth, so that any numbers we use internally that are mathematically derived from the parameters are recalculated only when necessary.
We end up essentially — in fact, literally — managing a spreadsheet row for every aspect of the synthesiser that the musician can control, and building something akin to a filing system in memory so that their values can be stored and recalled, one at a time or en masse.

There’s no escaping having to do all this, as almost the first piece of proper programming, or you have to go back and write all your control code again to wire such features in. Bringing control knobs into play last week made it inevitable that the time for this dull work is upon me, and it breaks one of my rules: none of these changes make the synth any more playable. Yet.
And here is where I heave my second sigh, as I need to diverge, considerably, from the original OSCar code and the work I’ve done there.
Diversion 1: Rethinking MIDI control
The first OSCar was sold towards the end of 1983, and the world first heard about MIDI in early 1984. It was clearly going to be transformative, so OSC quickly made a MIDI retrofit board and some new firmware (clever bodges, both) so OSCar would support its most fundamental features. It must quickly have been incorporated into the stock unit: every OSCar I’ve seen for sale has this kit fitted.

The MIDI support was very rudimentary, though — control data could not be automated except for pitch bend and modulation. And there was a weird anomaly in the use of the ‘All Notes Off’ message whenever the last note on the synth was released: presumably, that’s a useful remedy for stuck notes, but it’s considered bad practice today because it doesn’t merge well.
The new firmware did let you turn data on or off in a granular way that modern synthesisers don’t tend to support: note on/off messages could be suppressed while program change messages were sent and received, for example. This makes a kind of sense when you’re connecting two synths together, but when (as now) everything tends to be mediated through a digital audio workstation, those features are no longer needed.
OSCar also lets you send and receive all presets, waveforms, and sequences from memory: a handy feature which entirely replaced the need for the cassette interface (in fact, the M2 firmware release appears accidentally to have broken the ability to reload waveforms from a cassette). It didn’t let you save or alter one preset at a time, though: it was an everything-or-nothing feature.
(To send arbitrary data of this kind requires a company to embed its manufacturer number into the message. Until recently, developing new MIDI products therefore required payment of a small annual subscription to the MIDI Manufacturers Association. It was important enough to do this for Supperware and PWG independently to register their own numbers and pay separate subscriptions. The Oxford Synthesiser Company, though, squatted in Solid State Logic‘s manufacturer code. Pre-Internet and in the very early days of MIDI, it’s quite charming to see a little Socialist collective of Oxford-based companies registering and occupying a single manufacturer number.)
There’s an aftermarket firmware upgrade by Tauntek that rethought OSCar’s MIDI support. Bob Grieb, who wrote this new ROM, did a remarkable amount of work, disassembling and emulating the OSCar code to reverse-engineer what he needed to.
(Bob and I spoke about this over email: he was very forthcoming about the techniques he used. Of course I asked, very early on, if he’d let me look at any of the work he’d done, but he was understandably reluctant to give this away for free, and was so done with it that he didn’t want to know what I was up to.) Bob’s work involves a more extensive set of modifications than the original MIDI kit to accommodate a bigger EPROM and more RAM.
Tauntek picked MIDI control values to make the software implementation as simple as possible (rather than making interoperability the main priority), so it features slightly peculiar choices of controller numbers. Reportedly it doesn’t take much automation before it starts to choke: you cannot escape the limitations of the Z80 unless you escape the Z80. I’m pleased to have a much faster processor in the new OSCar to manage this stuff.
Diversion 2: Recollection varies
OSCar uses static RAM, and a backup NiCad battery. Chris could write anything anywhere in RAM and trust that it’d still be there after the synth was turned off, put in a box for a month, and then switched on again. (Until the battery ran out or failed, that is, but that was the user’s problem.)
Modern microcontrollers use FLASH memory for everything of a semi-permanent nature, including the firmware. Unlike RAM, it will preserve its state in the absence of power, so we can get rid of the battery. But the first big difference versus RAM is that you have to erase FLASH in pages of a few kilobytes at once. A save, then, is a lot more involved. It takes some data shuffling beforehand, and freezes up the processor for a few tens of milliseconds while the system memory is juggled.
The second problem is that FLASH does wear out after a few thousand erase cycles, as its tiny logic gates become subject to irreversible physical changes. It’s up to the programmer to level the wear of FLASH, avoiding the case where (for example) a customer making a series of modifications to the same preset might hammer one small area of memory with erase-program cycles, and cause it to fail prematurely.
We need to introduce something akin to a filing system: a largish block of memory reserved for presets that minimises the number of erase cycles applied to each page. We no longer save a certain preset in a certain allocated place in memory, but in the next available slot within a memory pool reserved for general use. We need to build a table of contents whenever the synth is powered on.
Diversion 3: Mod cons
OSCar lets you store 36 voice presets, along with a handful of waveforms and sequences. In fact, the first OSCar firmware let you store only 12 presets, which occupied about 20% of its 2K of RAM. We’ve got blasé about huge quantities of memory, so such small numbers feel very limiting today.
Mantis, for example, sells with 100 factory presets and 100 other slots free, although it does a lot more so presets can sound more different. To break the barrier of 36 presets requires changes to the user interface as well as the underlying code. The balance to strike is not to make the changes to the load/save workflow so intrusive that they appear sacrilegious to people who love the original OSCar, but also not to be ashamed by them so they get lost in obscurity.
The second thing that’s nice about synths like Mantis is compare and undo features. Compare mode allows you, for example, to listen to the preset you’re about to overwrite before you commit to saving your new one. I am not sure if there’s space for a similar feature in OSCar without changing too much about the way it works. OSCar uses the keybed to choose presets in load and save modes: being able to turn it back into a keyboard so you can play the preset you’re about to overwrite feels like it may involve too much interference with the original workflow, and we won’t know until we try it and argue about it. I carry Paul’s avatar in my head when I consider such decisions, and he tends to be a lot more conservative than I am.
Undo is easier, though. This allows you a chance to retrieve your work in progress if you were careless enough to load a preset while you were deep into editing a sound. The principle here is that you shouldn’t ever be able to lose an hour’s work by pressing the wrong button (unless it’s the power button). It’d be courteous to find a place for this.
Diversion 4: Tidying up, just because
The memory map in OSCar, as you can glean from the section of manual above, is a bit of a mess. (They usually are.) Parameters were added as Chris designed the synth. They’re not arranged in logical sections, and the naming conventions aren’t that clear to a modern programmer’s eyes. Mod Wheel Pitch Amount versus Direct Pitch Mod Amount, for example? We can improve that. Backwards compatibility can be maintained by making the import program a little more complicated, so it recognises and remaps data from an original OSCar (complete with its Solid State Logic manufacturer ID).
We end up with a spreadsheet a bit like this:

It’s in Python because it feeds into C code generation routines, and it’s unfinished. All the refresh fields are zero, because I haven’t written anything that uses them yet. OSCar, without its MIDI controller support, didn’t need them. And, while OSCar’s parameter map was 8 bits all the way, the actual precision was limited by a series of operations before those numbers hit the synth engine. Not all bits are meaningful in practice, and 7-bit parameters are far simpler to control over MIDI, so I will probably revise most of these.
But it’s a start. The comment numbers at the end are the Tauntek MIDI control numbers: I thought it’d be nice to preserve compatibility wherever it looked like it wouldn’t compromise other things. In the end, though, I went my own way for all but a few parameters. It’s not going to inconvenience many people: perhaps a handful of reviewers trying to do A-B comparisons between the old and new OSCars. I might also have looked at the impOSCar MIDI map for inspiration, but that’s now very different from the original synth.
Finally, a look at the progress-o-gram. I’ve done very little code conversion this week, but realised I’ve done more than I thought. The hardware abstraction layer actually counts as quite a lot of the original firmware.





