Why are these resistors present in these schematics?

In summary: BTW what book is it? I hope I don't know the author...hmm...actually I hope I DO so I can razz them -- On the right is my view of how things should work, which indicates that you are on the right track with your work.
  • #1
sherrellbc
83
0
The images represents circuits interfaced with an Arduino microcontroller.

yN135CD.png


e8ofXU2.png


The first image is a controller circuit for running a piezo buzzer. I understand the application of the transistor here, but am not sure why the resistor is present in parallel with the speaker.

The second schematic is a circuit that lights LEDs based on the voltage read at the analog pin A0. I thought that arduino's input impedance was very high? What is the application of this resistor?

And finally, the second image is a controlling circuit that I do not understand. The device on the left is suppose to represent a 12V relay. The diode is present to prevent voltage spikes from the relay after it has been switched off. My concern is that, given the transistor is an an NPN (BC548), the current would flow from collector to emitter (i.e. to ground in this schematic). The data sheet, and the article, write that the pin orientation is collector, base, emitter. With the diode reverse biased (the cathode is at the relays positive terminal), how does this circuit work?
 
Engineering news on Phys.org
  • #2
In #1 it may be that the parallel resistor allows some constant current to flow when the transistor is on, since the piezo is basically a capacitor. Without actually trying it I won't assert that it's unnecessary, but an experiment should show.

For #2 my opinion is that the resistor is superflous. It may be an attempt to limit "static shock" if the lead is open and roaming around, as it might be for an actual voltmeter application. Again, IMHO, this is the wrong way to go about it, but arduinistos seem to use this for static protection on touch plates and the like. I think it should be a high value resistor to ground which would also pull the "reading" down when the lead is open. I'd like to hear argument pro-con this from the knowledgeable though.

For #3 I wish you'd post a schematic because I can't follow the breadboard very well. It should look basically like the #1 piezo circuit with a reversed diode in place of the mystery parallel resistor, however on your breadboard it appears that both ends of the relay will be connected to the same power buss when/if the transistor is turned on.
 
  • #3
schip666! said:
In #1 it may be that the parallel resistor allows some constant current to flow when the transistor is on, since the piezo is basically a capacitor. Without actually trying it I won't assert that it's unnecessary, but an experiment should show.

For #2 my opinion is that the resistor is superflous. It may be an attempt to limit "static shock" if the lead is open and roaming around, as it might be for an actual voltmeter application. Again, IMHO, this is the wrong way to go about it, but arduinistos seem to use this for static protection on touch plates and the like. I think it should be a high value resistor to ground which would also pull the "reading" down when the lead is open. I'd like to hear argument pro-con this from the knowledgeable though.

For #3 I wish you'd post a schematic because I can't follow the breadboard very well. It should look basically like the #1 piezo circuit with a reversed diode in place of the mystery parallel resistor, however on your breadboard it appears that both ends of the relay will be connected to the same power buss when/if the transistor is turned on.

The last image was simply taken from the book, there was no schematic for it. The design is nothing more than a transistor with the diode's anode connected to the collector. The diode's cathode is connected to the positive terminal of the relay. The emitter is grounded and the base is connected to a digital output pin on the arduino.

My concern was that, given the transistor is of type NPN, the current would flow from collector to emitter. This would mean that when the transistor is conducting, the current would be flowing backwards through the diode.
 
  • #4
OKokOK You have released my inner pedant... Here's what I believe to be the schematics:

relay.jpg


On the left is my reverse engineering of the breadboard. The diode is wrong and the relay power is also wrong. So. I would throw out that book and start over -- BTW what book is it? I hope I don't know the author...hmm...actually I hope I DO so I can razz them -- On the right is my view of how things should work, which indicates that you are on the right track with your work.
 
  • #5
schip666! said:
OKokOK You have released my inner pedant... Here's what I believe to be the schematics:

relay.jpg


On the left is my reverse engineering of the breadboard. The diode is wrong and the relay power is also wrong. So. I would throw out that book and start over -- BTW what book is it? I hope I don't know the author...hmm...actually I hope I DO so I can razz them -- On the right is my view of how things should work, which indicates that you are on the right track with your work.

It just seemed strange how the circuit was illustrated. The author states the diode protects the circuit by blocking the return path and forcing the current to circulate in the coil to be released as heat. None of it made sense.

The second schematic (right) appears to make much more sense to me than the other.

The book is actually this one:
https://www.amazon.com/Arduino-Workshop-Hands-On-Introduction-Projects/dp/1593274483/ref=sr_1_1?ie=UTF8&qid=1375042088&sr=8-1&keywords=a+hands+on+introductions+with+65
 
  • #6
schip666! said:
In #1 it may be that the parallel resistor allows some constant current to flow when the transistor is on, since the piezo is basically a capacitor. Without actually trying it I won't assert that it's unnecessary, but an experiment should show.

For #2 my opinion is that the resistor is superflous. It may be an attempt to limit "static shock" if the lead is open and roaming around, as it might be for an actual voltmeter application. Again, IMHO, this is the wrong way to go about it, but arduinistos seem to use this for static protection on touch plates and the like. I think it should be a high value resistor to ground which would also pull the "reading" down when the lead is open. I'd like to hear argument pro-con this from the knowledgeable though.

For #3 I wish you'd post a schematic because I can't follow the breadboard very well. It should look basically like the #1 piezo circuit with a reversed diode in place of the mystery parallel resistor, however on your breadboard it appears that both ends of the relay will be connected to the same power buss when/if the transistor is turned on.

The resistors in the second drawing are very much needed. Those are current limiting resistors. When conducting the LEDs are essentially a short. The ports of the Arduino are rated at 40ma max current draw. The current limiting resistor guarantees that you do not exceed this and serve to control the brightness of the LED. You can pick any resistance in a range with the minimum determined by the 40ma max of the port.
 
Last edited:
  • #7
Integral said:
The resistors in the second drawing are very much needed. Those are current limiting resistors. When conducting the LEDs present a very low resistance so with no other resistance the 5V port would draw a very large current. The ports of the Arduino are rated at 40ma max current draw. The current limiting resistor guarantees that you do not exceed this.

yes the ones in the LED lines are for current limiting but they are not the ones he was asking about.
its the one resistor with the red underline on the A0 input :)

which I would still expect to have a current limiting function for the input to the chip

Dave
 
Last edited:
  • #8
In order to know the purpose of R4 we need to see the program. Since it is connected to an analog port the arduino could be monitoring that voltage and setting a LED depending upon the value. Without the code we can only guess.
 
  • #9
Integral said:
In order to know the purpose of R4 we need to see the program. Since it is connected to an analog port the arduino could be monitoring that voltage and setting a LED depending upon the value. Without the code we can only guess.

Well, yes, that is very likely what the program is doing. However the relatively small resistance of R4 will have no effect on the net input voltage because the input impedance of the ATmega is on the order of 10Mohms.

So I return to my original answer/question: Is this for static discharge protection? And if so, my assertion is the same as above, it should have no net effect whereas a large resistance to ground might serve the purpose by shunting discharges. In this simple setup for a capacitive touch sensor:
http://playground.arduino.cc//Main/CapacitiveSensor?from=Main.CapSense
the resistor to an output pin might serve the same purpose... My somewhat limited experience with the circuit indicates that most of it is superfluous as well however...

Also, Moderator? How come this thread was "closed due to mis-information" earlier this morning?
 
  • #10
Again, to know what R4 does we need to see the code. What is the purpose of that configuration? Without more information, we can only guess.

Question for you, what is the meaning of the port name A1? What is its purpose?

If you cannot answer these questions then I doubt your qualifications for speculating about the purpose of R4.

I am pretty sure that your guess about static protection is wrong.
 
  • #11
The inputs on micros are usually protected against negative voltages and voltages greater than 5 volts by diodes to ground and 5 V respectively.

These diodes do not normally conduct, but when they do, it is worth having a current limiting resistor in circuit to avoid damaging the internal diodes.

Also, with some micros, it is possible to program the same pins as inputs or outputs.
So, a pin that is normally an input and grounded could suddenly output a lot of current if it produced a high level output.

So it is worth having a small resistor there, just in case.
 
  • #12
The load resistor is part of the piezo operation. when the transistor turns off the piezo capacitance discharges through the resistor. (it's being driven at the audio frequency)

The resistor on the A0 analog input is an over/under voltage protection resistor to prevent latchup or at the least, excessive currents for out of range input voltages. There are generally clamping diodes in the pad.
 
Last edited:

1. Why are resistors present in electronic schematics?

Resistors are present in electronic schematics because they are used to control the flow of current in a circuit. They are essential components that help regulate the voltage and prevent damage to other components.

2. What is the purpose of resistors in a circuit?

The main purpose of resistors in a circuit is to limit the flow of current, which helps in controlling the voltage and preventing overheating of components. They also help to divide voltage and create a voltage drop in a circuit.

3. Can a circuit function without resistors?

It is possible for a circuit to function without resistors, but it may not be ideal. Resistors are crucial components that help regulate the flow of current and protect other components from damage. Without resistors, the circuit may become unstable and malfunction.

4. How do resistors affect the overall performance of a circuit?

The resistance value of the resistors used in a circuit can affect its overall performance. Higher resistance values decrease the current flow, while lower resistance values increase the current flow. This can impact the voltage, power, and stability of the circuit.

5. Can resistors be replaced with other components in a circuit?

Resistors have unique properties, and they cannot be replaced with other components in a circuit. However, other components, such as diodes or capacitors, may have a resistance value and can be used as a substitute for a resistor in some cases.

Similar threads

Replies
80
Views
3K
  • Electrical Engineering
Replies
5
Views
2K
  • Electrical Engineering
Replies
1
Views
823
Replies
5
Views
2K
Replies
10
Views
1K
  • Electrical Engineering
Replies
5
Views
3K
Replies
15
Views
7K
  • Electrical Engineering
Replies
5
Views
4K
  • Electrical Engineering
Replies
5
Views
2K
  • Electrical Engineering
Replies
2
Views
2K
Back
Top