project pages http://www.projects.cappels.org
Return to HOME
A 7 Bit Barker Code Generator Circuit
This a simple circuit using CMOS logic that
continuously produces the 7 bit Barker Code.
Figure 1: The scope displays two repetitions of the 7 bit
code in yellow
and sync pulses in that coincides with the generation
of bit 1.
Figure 2. A regulator was included so the generator could be
independently of other circuits.The connector on the right
side of the
board makes +5V, ground, the code and sync outputs
to the circuit that requires the code.
I need a fast, adjustable, and not necessarily
very stable or frequency-accurate Barker code generator
for an investigation. I had been using AVR controllers to
generate the codes, but merely changing the chip rate meant
modifying the assembly language source and programming the
chip, what's more as the chip rate increases, the firmware
approach gets more difficult until finally, the controller
can't quite keep up. That is the reason for this simple
circuit. Its easy to adjust the frequency by soldering in a
different oscillator component, and externally clocking the
generator is also possible.
The inputs of a three input NOR gate are driven high by three
pulses in a repetitive seven pulse sequence that correspond to
the time during which the Barker code waveform is low.
Figure 3. All of the
gates are contained in the TC4000B package,
making this a two-chip solution for a
seven-chip generator :-)
The chip rate is determined by an
RC oscillator. At the moment, with the 10k resistor shown and
the "Select" capacitor being 47 pf the chip rate is 609 kHz.
Pin 5 of the Toshiba TC4000B, which is similar to the CD4000,
is grounded through a 10k resistor. The allows a future option
of using pin 5 as an input to switch the code generation on
and off or by removing the 10k feedback resistor and the
timing capacitor, external clocking is possible. The resistor
on pin 5 may be replaced with a connection directly to ground.
It should be noted that with a 5 volt power supply and the 10k
feedback resistor, the output on pin 9 is being asked to
supply nearly 500 microamps, and that the TC4000B data sheet
shows the maximum output low current to be 400 nanoamps. It
would be proper to use a chip with a heftier output capability
or a slightly larger value feedback resistsor.
The counter chip is a HCF4017B, set up so that when output "7"
goes high, the counter is reset. The period that output "7" is
high is approximately 100 ns, which has the effect of
stretching the one chip period that the output is low by
approximately that amount of time. I think that for my
purposes, this won't be an issue until past 1 megachip/second
and with a faster counter, that limitation can be pushed to
A sync output that is to be used to trigger an oscilloscope is
taken from the counter's "1" output. This output was chosen so
that loading on the sync output would have little or more likely
no effect on the code output.
A 78M05 is used for the voltage regulator because I have a lot
of them, not because I need much current.
A green LED and a 470 ohm resistor were added as a power
indicator after the schematic was drawn.