2
\$\begingroup\$

I'm trying to setup a low cost current injector for testing certain I/O modules. I found a rather simple design for a current source using 7805.

schematic

simulate this circuit – Schematic created using CircuitLab

So I tried making that and changed the resistances to match my requirement. I have a 24 Volt source on the test rack, which powers the I/O modules as well. Since this is a low cost project, I used the same power supply and ended up with this. -->

schematic

simulate this circuit

This circuit worked perfectly when I tested it with a multimeter. It gave 3.6mA to 20.1 mA.

However, while testing with the I/O module, the current through the load (I/O module's internal resistance) never went above 15.6 mA. The I/O module has a floating ground and therefore an isolated current measuring setup. But when I touch the heat sink, the current rose to 20.7mA Thinking this might be due to the capacitance effect from my body, I added a capacitor between the input and GND(what I could find lying around in the workshop was a 35v 100uF). Now I see that the output is in the range of 3.6mA to 20.8mA.

I am not literate enough to calculate the correct capacitance required or evaluate whether this setup is reliable.Please advise.

\$\endgroup\$
4
  • \$\begingroup\$ Try reading the data sheet for a 7805 - it will tell you that you need two capacitors to generally stabilize it. \$\endgroup\$
    – Andy aka
    Sep 29, 2015 at 13:03
  • 1
    \$\begingroup\$ The capacitor helped, probably (though not definitively) because the I/O modules picked up noise on the output differently than your multimeter. Other than that, see @i-chodera 's answer. \$\endgroup\$
    – Asmyldof
    Sep 29, 2015 at 13:46
  • 3
    \$\begingroup\$ An 7805 has a rather large (and varying!) quiecent current. An LM317 is designed to be used in this configuration, and has a much lower (and much more stable!) quiecent current. \$\endgroup\$ Sep 29, 2015 at 14:51
  • 1
    \$\begingroup\$ Most likely it's not happy with the source impedance of your power supply- it is typically stable with just an input capacitor. Try a 100nF capacitor from 7805 'in' to GND within 10-20mm of the 7805. As Wouter says, this is not ideal- the GND current (typically at least several mA) will change at least several percent just from warming up. \$\endgroup\$ Sep 29, 2015 at 14:57

1 Answer 1

3
\$\begingroup\$

The 7805 is a generic part, variants are made by lots of manufacturers, you should check the datasheet for the exact part and make you have used. Typically they recommend a 0.1uF capacitor between Out and GND and a 0.33uF capacitor between In and GND. These are required for stability. In practice, you will probably find that any values greater than these will work fine.

\$\endgroup\$
1
  • \$\begingroup\$ Indeed, at least Fairchild recommends caps, even when used as a constant current source fairchildsemi.com/datasheets/LM/LM7805.pdf (fig 10, p. 19). The LM317 datasheet omits caps when configured as current source. So overall probably even cheaper, never mind better performing in this role as @Wouter van Ooijen noted. \$\endgroup\$ Oct 2, 2015 at 10:49

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.