Monday, March 20, 2017

Fun with Sea Moss: 4051 Octave Sequencer



The ideas in this post largely come from Nicolas Collins' excellent book 'Handmade Electronic Music', which I would highly recommend.


The 4051 eight channel multiplexer has eight individual channels, and one common channel. At any point in time, one and only one individual channel can be connected to the common channel. The result is a structure that resembles an eight input gate or eight output switch - i.e. one common point being connected to one of eight individual points.

Three pins labelled A1, A2 and A3 form an address, whereby one of the eight individual channels are selected. The LOW or HIGH state of A1, A2 and A3 determine the channel that is currently connected to the common channel.


So, for example, if A1 is LOW, A2 is HIGH and A3 is LOW, then channel 3 is connected to the common pin. If A1 is HIGH, A2 is HIGH and A3 is LOW, then channel 7 is connected to the common pin.

The connection between the common pin and an individual channel can be an analog signal - i.e. audio, complex waveforms, DC values etc, or logic state signals. This makes the 4051 very versatile.

By combining a 40106 with a 4040, the 4051 can be used to make an octave sequencer. A 40106 oscillator is used as a clock source, which is feed into pin 10 of the 4040 binary counter. The first eight outputs of the 4040 outputs are connected to the eight individual channel inputs of the 4051.



The last three outputs of the 4040 are connected to the three address pins of the 4051. Thus, the 4040 is used to generate a set of signals all one octave apart. Each octave is fed into an input on the 4051. By changing the address lines of the 4051, only one octave is heard at a time. The order of A1, A2 and A3 as well as the frequency can be adjusted for a more interesting sequence.







































Fun with Sea Moss: 4017 Frequency Division



The ideas in this post largely come from Nicolas Collins' excellent book 'Handmade Electronic Music', which I would highly recommend.



The 4017 decade counter takes a clock input, and has 10 outputs labelled O0 - O9. Each output will, in turn, output a pulse in time with the clock pulse. If the reset (RES) pin is briefly held high, and then brought back low, the count is restarted and the process can begin again. The chip also has a carry count (CR) pin, which outputs a pulse if the clock is counted beyond the tenth output with being reset.



A 40106 oscillator is used as a clock source, which is feed into pin14 of the 4017 decade counter. The 10 counting outputs of the 4017 will begin to pulse in turn with the clock input. By connecting the signal from one of the outputs of the 4017 to the reset pin of the 4017, the 4017 will reset at a clock pulse count below 10. For example, if clock output number 2 of the 4017 is connected back to the reset, then when the second pulse of the input clock is mirrored to output 2, the 4017 is reset.


By monitoring from the very first output, an audio signal that is a direct division of the original is created. The practical result is that a clock input can be divided by various ratios, where each successive ration results in a waveform where the duty cycle is comparatively lower, too.

For example, consider that output 3 of the 4017 is fed to the reset. Now, the clock frequency - which had a frequency of, say, 440 Hz - now has a frequency of 146.67 Hz (which is 1/3 of the original) and a duty cycle that is only 16.67 %. This is because only every third clock pulse actually becomes part of the final signal.