Rue Mohr's "Self-Clocking ROM" Turns a Memory Chip Into Its Own Clock Source

Rather than use an external crystal oscillator, Mohr's clever display project uses an RC circuit to turn a ROM chip into its own clock.

Gareth Halfacree
6 days agoHW101

Maker Rue Mohr has decided to massage some hardware into doing something unusual, creating a "self-clocking ROM" capable of acting like a crystal oscillator — after a fashion, at least.

"There are a few projects that can be implemented with a ROM and need a clock source," Mohr explains. "So, I was in the shower and had an idea. The idea was to add an LC [inductor-capacitor] delay between a data output line and an address input line of a memory chip in order to create the inverter needed for building an oscillator. Normally I would reject this idea, writing off that that system would find a voltage between logical 1 and 0 that it would stabilize on, but I'd recently been reading RAM datasheets that mentioned they had Schmitt triggers on all the inputs…"

This digital display circuit provides its own clock, with no crystal in sight. (📹: Rue Mohr)

In theory, then, it should be possible to turn the ROM chip itself into an oscillator — making it its own clock source and doing away with the need for an external crystal. To prove the concept, Mohr set about building a seven-segment display device — but first there would need to be some experimentation to see if it was even possible.

"I built a ROM image for a simple inversion. D0 would be the opposite of A0. I wrote a 2816 (16k EEPROM) to do the test," Mohr explains. "I tend to assemble circuits with the power on. To my surprise, this started oscillating before I was even finish building it! [But] just because something works, doesn't mean it works well. It can be important to play with it and understand the limits to operation."

Further investigation revealed that switching from the LC delay circuit to an RC, resistor-capacitor, delay circuit not only continued to work but offered improved performance — allowing the clock to hit 3MHz. Once it came to actually using the clock source, though, things became trickier: "Loading the 'oscillator' like this caused a large error in the duty," Mohr explains. "Duty error in something like this causes one display to be brighter than the other, so I added a few bias parts to bring it closer to 50 per cent.

"At 50 per cent (if you adjust it such) the operation of the oscillator is not stable, it may stall or not start up with power. [It] serves me [right] for not adding another chip (74xx541) to drive the LEDs — its not good form to make a chip like this EEPROM try to drive LEDs. But it was all OK, and kinda just worked!"

More details, including source code and binary ROM images, are available on Mohr's project page.

Gareth Halfacree
Freelance journalist, technical author, hacker, tinkerer, erstwhile sysadmin. For hire:
Latest articles
Sponsored articles
Related articles
Latest articles
Read more
Related articles