eisental/BasicCircuits — pull request #19 by jpfx1342 (2012-09-26 05:04:13+00:00)
Title: Repeater and Ram Improvements

This is series of updates I created while working on a RedstoneChips project on my server. It addresses a few shortcomings and issues I found while working with your plugin. (Note that I love your plugin, it's just that there were a few things I couldn't get it to do.)

This pull request encompasses four main features:

- A bug I discovered in the display chip, which causes it to not unregister a ram listener.
- The repeater chip can now repeat entire sets of bits, instead of just one. I'll describe this a little more below.
- The dregister chip can now be backed by ram. This is useful for making "hardware" controlled by locations in your virtual ram.
- The watcher chip generates a clock signal whenever a watched ram address changes, which is useful in conjuction with the ram-backed dregister.

The repeater chip has new features which I think greatly increase it's usability. While before it could only repeat/split 1 bit, now it can do so with as many bits as you choose. This allows it to function as a 16-bit repeater, or a 16 to 32-bit splitter. Note also that my modifications do not change it's old behavior at all, assuming the old chips only had one input. A 1 input repeater will still repeat to all outputs.

One issue on which I was a little confused was as to whether or not my watcher should output a 0-tick or 1-tick clock signal. I ended up going with the 1-tick variant, but this could easily be changed.

There are more details about the modifications I made in the relevant commits.