Relays switched and loaded from same power source?

I have a 24V battery and 24V relays (voltage needed to flip relay on and off). The loads connected to the relays are also 24V (and 0.5 amp). I am controlling the relays by arduino via transistors.

See attached schematic.

I've made a board with 16 of these relay circuits in it, and it's highly erratic. Seems to be feedback that causes the switching of one relay to affect the state of others.

Is this because I am switching the relays and powering the loads from the same battery? Perhaps the addition of some capacitors could help?

Is there anything wrong with the schematic?

Note: the loads are solenoid valves.

Do you have a GND connection between the 24v battery and the Arduino?

There isn't one in the schematic.


Rob

What are the loads, resistive or inductive ?

What is the AH capacity of the battery ?

Why are you feeding the transistor collectors with a bleed resistor/diode arrangement across the relay coils ?

Where does the Arduino get its power from ?

So many questions, so little upfront information

Your base current may be too low to fully turn on the transistors - you do not specify type of transistor. What voltage do you have on relay coils when turned on. Suggest you lower the 33k to 10k.
jack

Thank you for your detailed reply Richard.

First, some additional info:
Transistors: 2N3904
Battery: Two 12V, 7.5 Ah batteries in series.
Ground: Yes, arduino and battery grounds are connected.
Solenoid Valves: 320mA, 7.6 W, 24VDC (16 of them in project).

(1)
I'll begin by acknowledging that I probably shouldn't be using relays at all, so I'm going to redo my circuit to resemble the schematic below.

(2) The Ic for the 2N3904 transistor is 200mA, so I think that means I need to change transistors as the I of the solenoid valves is 320mA. I will look for a TIP120, as those have been suggested in tutorials. Perhaps someone can recommend a different one?

(3) I calculated the value for the resistor (R1) between the arduino and the transistor using a procedure I found online. From what I understand I need to calculate the "saturation voltage". Most of the explanations of how to do this have been beyond my comprehension. Perhaps someone can recommend a good tutorial?

(4) How do I calculate the capacitor (C1) value?

(5) I will need to turn on between 1 and 16 of the valves simultaneously (for a period of between 20-100 ms). I imagine this causes a voltage drop across the whole circuit. Do I need an even bigger capacitor over the whole circuit to prevent this from happening?

(6) Should I connect the solenoid valves in parallel or series to the battery?

I'm sure these questions are pretty fundamental, but I'm quite new to these things and trying to figure them out from books and the internet. Your help is much appreciated.


I got a TIP120 at RadioShack and it works great.

With the feedback I received here, and with further research, I've designed a new circuit. I still need feedback to get things right, but I've started a new thread because the content has drifted from the topic of this thread.

The new thread is at:

http://www.arduino.cc/cgi-bin/yabb2/YaBB.pl?num=1291477271/0

I would appreciate the continued input of any of the posters above to help me perfect the design.

Thanks!