Adding a ROM switcher to the HR-16
2023-12-22
A fun little hack to the HR-16 drum machine I did a while back.
The Alesis HR-16 and HR-16B
The Alesis HR-16 is a low-cost drum computer from 1987. Two years later Alesis released a new model called the HR-16B with different sounds. The HR-16B looks different because it's made of black plastic instead of grey, but the hardware on the inside was identical to the first model.
Image source: Vintage Synth Explorer
Fancier drum machines of the time had individual output sockets for each of their drum sounds. The idea was that producers were used to recording a drum kit with many microphones going through various processing gear and into a mixer. The individual outputs of fancy drum machines are meant like virtual microphones, allowing you to tailor the drum sounds. For example, the raw sounds of the Yamaha RX5 sound disappointingly plain when compared to how they are used in Cameo's Word Up. Because the RX5 has individual outputs, Cameo were able to make the drum machine sound bigger and more interesting.
Not so with the HR-16, because it's a low cost machine. The drum sounds in the machine have their sound effects baked in. This saves costs (the hardware is simpler) and it makes sense for the intended market: bedroom producers probably don't have a wall of studio rack gear at their proposal to beef up their drum sounds.
I love these baked in effects because it makes the machine sound extra dated. Here is an example snippet of music I made which proudly uses the HR-16. Note how "huge" the snare drum is right out of the gate. The orchestra hits are from the JV-1010, not the HR-16.
When I got my own HR-16 and found out how much I liked the sound I wanted to use the HR-16B sounds too.
ROM chips
Asides from the color of the plastic, to my knowledge the only difference between the HR-16 and HR-16B is the software and sample data. These are stored in socketed ROM IC's which means that you can swap them without having to do any soldering.
These ROMs are designed to be used on an 8-bit parallel data bus. To access one byte (8 bits) of data you must write an address to its address pins and enable the chip for reading. The number of address pins depends on the storage capacity.
The operating system of the HR-16, for example, is stored on a 27C256 IC. Its address pins are numbered A0 to A14, meaning it has 15 of them, which tells us that its capacity is 2^15 = 32768
bytes. If the CPU wants to read the byte at address 0x10 in the ROM, it would write 000000000010000
(0x10 in binary) to the address bus and then read the corresponding 8 bits of data from the data bus.
The sample data is stored across two 27C040, each of which hold 512 kB of data. The 27C040 works the same as the 27C256 but with more address pins.
ROM switching
One size up from the 27C256 is the 27C512 (64 kB). You can see the pinout below. Note how both chips have 28 pins. There is one extra address pin on the 27C512, A15. On the 27C256 that pin is called VPP and it's used when programming the memory contents. In the HR-16 that pin is not connected to anything ("floating") because the chip is only used for reading, not writing.
This means that the 27C512 is almost compatible with circuits designed to read from a 27C256. The only thing to take care of is that A15 is tied either high (5V) or low (0V).
What is more, because the 27C512 is twice the size of the 27C256, one 27C512 chip could hold the OS of both the HR-16 and the HR-16B. If we tie A15 to 0V then the HR-16 "sees" one half of the chip. If we tie A15 to 5V then the HR-16 sees the other half.
Using our example from before, if the CPU wants to read the byte at 0x10, and we control the MSB, then what the CPU sees is either the byte at 0000000000010000
(MSB set to 0 by us) or 1000000000010000
(MSB set to 1 by us).
The same pattern applies to the 27C040 sample data ROMs. Those chips have 32 pins, and so does the next size up 27C080. The MSB address pin of the 27C080 is unused on the 27C040.
This then leads to how I implemented the switching mechanism: I bent the most significant bit (MSB) address pin of each ROM out of its socket so that I can control what voltage it sees.
I then joined all these MSB address wires together and tied them to the middle leg of a single pole double throw switch. I connected the outer legs to 0V and 5V which signify 0 and 1 on the address bus respectively. Here you can see the bigger picture.
I drilled a small hole in the plastic of the HR-16 enclosure. I put it out of sight on the bottom half of the case.
And it works! I can flip the switch while the machine is off and it will start up as either an HR-16 or an HR-16B. Fortunately, the OS is similar enough between the two that they can read eachother's battery-backed RAM data. I don't have to wipe the RAM every time I switch the OS + sample ROMS.
I used a TL866 with the open source minipro control software to burn the data onto the chips.
Other possibilities
It is possible to mess up old drum machines beyond recognition through techniques called "circuit bending". I think it sounds lovely but I would have to buy a second HR-16 for that because I'm not sure the process is reversible.
Conclusion
This was a very simple hack made possible by the compatible pin layouts on both the OS and the sample ROMs. It was fun to figure out this was possible and now I have two Alesis drum machines in one!