Yet another relay attenuator

Status
This old topic is closed. If you want to reopen this topic, contact a moderator using the "Report Post" button.
Inspired by the ftorres' nice balanced preamp, and slightly turned off by the design decisions made by the Dip Chip folks, I decided to make my own relay attenuator. Using the ftorres' schematic as a starting point, I created a balanced stereo attenuator with 20K input impedance and 64 levels, in 1.25dB steps. The attenuator is controlled by an AVR micro and a 32-step-per-revolution rotary encoder.

Schematic
Layout
Bill of Materials

I hope the drawings make sense. Total cost is about $150 for parts and varying PCB price.
 
:att'n: Assuming that the latches are ordinary TTL (I haven't been able to figure out what the D at the end of 74LS595D stands for), then please verify that they can actually supply the current needed for the relay coils... Normal TTL are inheretly poor at delivering current compared to what they can sink. And I suspect even the sinking capabilities of the latches might not be enough ?

Are you sure there is any need for the zeners btw ? The anti-parallel diodes should be enough, shouldn't they ?
 
The datasheet from Fairchild for MM74HC595 (which is the part used, nevermind what it says on the schematic) claims current drive of ±35mA per pin. The Omron G6K-2P-Y-5V relay requires 21mA drive current when on. I think it will work.

As for the zeners, I simply did not want to blow up the outputs of the '595. Perhaps I was too conservative, but whomever builds this could optionally use a diode rather than a zener, if desired.
 
I'm only just coming to realize that this attenuator is tiny enough to use in my planned 6-channel amp. If you view this on a 96-dpi computer monitor (most of you), this image is the actual size of 5.4" x 3.9"
 

Attachments

  • atten-actual.png
    atten-actual.png
    93.7 KB · Views: 4,072
AX tech editor
Joined 2002
Paid Member
jwb said:
The datasheet from Fairchild for MM74HC595 (which is the part used, nevermind what it says on the schematic) claims current drive of ±35mA per pin. The Omron G6K-2P-Y-5V relay requires 21mA drive current when on. I think it will work.

As for the zeners, I simply did not want to blow up the outputs of the '595. Perhaps I was too conservative, but whomever builds this could optionally use a diode rather than a zener, if desired.

What you should check is when you pull these 21mA, what the output voltage of the mux is, certainly no longer 5V. It should be enough to pull in the relay.

I used them in a similar project and needed to go to Pickering low-current relays for this reason.

Jan Didden
 
JasonL said:
that does look awesome.. What kinda control is used to use this pcb and Schematic.. How much it is from start to finnish.. ? is this balanced or just Line.. This looks something that i want to tackle. How much for a pcb ? Will you charge.? do you need 2 boards one for left and one for right.?

Hey, one question at a time! Not sure what you mean about the controls. It uses a rotary encoder for input. Anything that runs on +5V and has a quadrature output would work. The software runs on an Atmel AVR. The design is two balanced channels per board, so only one board needed. Depending on how many boards i get made, it could be as much as $150 per board or much less. I was planning to build two and sell one of them. Later if I build 6 channels I might build 10 and sell the surplus.

Jan, thanks for the tip I'll see how the output holds up under load. I've tested with Coto relays and 74HC595 with no troubles. Note that only one output on each 595 is powered at once.
 
I am now finishing up a MEGA163 controlled preamp using just an encoder with a push-in switch for an interface - well... also an RF remote (small five button fob) and mute switch but thats just icing. I see you wired the encoder to the interrupts - good, using these will assure no missed turns when the processor is outputing to the relays. I would also recommend wiring a few of the unused I/O to a header so that you can update later - a display of some sort. a mute switch/LED, etc.

Some other ideas FWIW: I wired in a programming jack so that I can update the program in-circuit. I wired a brown-out detector so that I can save the current settings to the MEGA's internal EEPROM in order to restart with the last settings. I programmed a volume fade-in on start-up, unmute, and large knob turns. And lastly, I supplied a switch to turn off power to just the processor and display (in case they added any noise to the system. I also have a programmable mute level which you could easily impliment using a DIP style switch on the PCB to set the mute volume on some unused I/O.
 
Very interesting ideas. I wired the push-in switch of the encoder to the reset on the micro for mute: when the micro resets it loads the least volume setting. There is no unmute with this method :)

I like the idea of bringing out headers for the other IO pins, but I've never looked at the pinout for programming. For some reason I always skip that section in the datasheet. It just seems easier to pop the micro into the STK.

Do you find it necessary to power down the micro for noise reasons? I put the micro to sleep with only the watchdog clock running after servicing the interrupt. Also, I'm using the internal oscillator (no crystal).

Would you care to share the schematic or software for your preamp? It sounds like something we could learn from. I'd like to see how you did the remote control.

Cheers,
jwb
 
I will include the schematic soon for those interested but it was mostly done off-the-cuff as I was wiring the board. I am using a 2-line VFD display and so the power down idea was mainly to kill power to the display (I also have the processor controlling the display power and have provided a programmable time-out to dim or disable the display only). I doubt that you will find any noise with the processor in Sleep mode as long as power supply and shielding are done properly (I use a different power supply for the processor and display than for the preamp). I can certainly provide the source code to anyone interested but it is written in 'C' and is getting quite large due to the amount of options - the display runs as follows:

When powered up, the unit ramps from mute to the last volume and Volume is displayed along with the input source. Any turn on the encoder adjust volume up to a presettable max (adjustable for each input source). Pressing the encoder cycles through VOLUME-INPUT SOURCE-BALANCE-SETUP. The display reverts to VOLUME after no activity for a user-settable delay.

In setup, the user can configure the following:
- Number of Input Sources (so I can use this on different boards)
- Name of Each Source
- If Balance control is enabled (if not, it does not appear on the main menu)
- Display Brightness
- Mute Volume
- Maximum Volume
- Fade-in from Mute (Yes/No option)
- Menu Time-out
- Display Time-out
And probably a few more I can't remember.

The remote control is a Linx transmitter and receiver from Digikey. I use the small five button fob remote to provide Source Select up and down, Volume up and down, and the center button is used for Mute. The receiver provides five digital inputs directly into the Atmel processor and comes supplied with an antenna which is adjustable and fits nicely through a hole in the case. I'll see if I can post a few pictures when I get home.
 
janneman said:
What you should check is when you pull these 21mA, what the output voltage of the mux is, certainly no longer 5V. It should be enough to pull in the relay.

Thanks again for the tip, Jan. I checked the MM74HC595 and the output is 4.527V at 20.4mA driving a 221Ω resistor. The coil resistance on the relay is 237Ω and the pick-up voltage is 4.0V. I think it will work.

Note that there are two problems with the board. I neglected to pull down the G pin and pull up the SCLR pin on the shift registers.

:wrench:
 
Updates

The schematic and layout -- linked at the top of this thread -- have been updated to include an on-board voltage regulator and properly connect the '595s. This will be much more convenient as power input can range from 6.5-24V. I normally have 12V rails in my equipment and this will allow me to add these attenuators into existing designs. Of course you could adjust R65, Z65, and Q1 to suit your application, or just jumper them if you have a 5V source handy.
 
Status
This old topic is closed. If you want to reopen this topic, contact a moderator using the "Report Post" button.