My Name is Ahmad Shamshiri and I am presenting this tutorial from Canada
Hello, welcome to a video from Robojax. in this video I'm going to explain the
usage and calculation of resistor and pin configuration for the seven-segment
LED display. we have either one two or maybe more digits of 7-segment display
but there are one more characteristic and that is if they are common cathode
or common anode depending on the type of application you might use different type
of
7-segment display. this is called 7-segment display because we
have seven pieces of LED or we have seven in LEDs here so one two three four
five six seven seven segments and there is also a decimal point so let me show
you on the diagram so this is a diagram and the top piece is called A and so
forth B C D E F and the middle one is G so DP decimal point. in this case we have
LED arranged in this way and this package so ABCD and these are this side
of diode is called anode and this is called cathode so the cathode in this
case or common which means all of the cathodes of these eight LEDs are
connected so we just need one wire but on this side we need separate wire for
each to turn them on and individually. Here one LED is for the decimal point this
is also an and LED so so this is the other one this is called common anode so
I know this common and then cathode which is the negative this would be
connected to the negative they are separately so we bring the positive here
and the negative will be connected here through some means or maybe Arduino
or some other circuit that connects it so this will be turned on
each of those and it will display thing so for example for to display 1
this will be ON for two ABGE and D will be ON and so forth. so you know that
let's look here so these are the pins so Pin one two three four five and then six
seven eight nine ten so if I put this on my breadboard (see tutorial video on breadboard)
I've already invert this open one starts here so one two three four five and then
go here counterclockwise six seven eight nine ten so you counted that way and
this is also the same but the difference is this is common anode. so this is
common cathode and this is a common anode and also we have two digit display
the two digit display the number of pins does not increase so what it does is we
have one common anode or cathode in this case this is common Casaus for one digit
and we have also another common for this one so we have this 7 plus 1 is 8 and
also we have 7 plus 1 is 8 so we have only 8 pins for all of those depending
which common is activated this will be turned on or off so which I'm going to
connect next. this one is common cathode so the cathode of this one is common as
you can see on the screen so the cathode is common which is the negative side we
have all these common cathode so the negative is common and the positive will
be connected to different digits to turn this on this is common as you can see on
the screen so pin number 3 and 8 is common so this is as you can see I'm
counting pin 1 2 3 twice from the edge 1 2 3 so this is common and this positive
this is already 2 volts so I'm connecting it to any of those so if I
connect this to 1 as you can see here number 1
number one we'll turn on the E so this side is E as you can see the E is ON
So now if I connect this to the second one you can see the D will be on
so two is D and also if I connect it to the fourth one let's see so four is C
and then here the decimal 8 is common so this these are connected to
each other it is the middle the middle here and the middle on this side so to
pin on this side and to pin on that side or the actual pin so the middle one is
common and so forth. so the last one is here which is the the G so you can
see G is number 10 so this is another one now let's look at the at the common
anode so this is common anode so this time for the common I'm gonna use this
one so the red is now common and the negative will move between the pins so
you can see here now the digit E is on D is ON , C the decimal point, and this pin 6
again to just remind you then six is B so that is B also I've created
this layout here 1 2 3 4 5 6 7 8 9 10 you can download it from my website
www.robojax.com so the link is provided at the description. Then I'm gonna
tell you if your voltage is not properly adjusted I'm gonna give you the
explanation on how to calculate that okay now let's look at a two digit
common cathode LED 7-segment display .so this has a 10 pina so starts from 1 to 5
and then 10 the same way 1 to 10 but here the common is for each digit each
digit separate and then we have the other pens are common so let's have a look
at there so when I when I insert this here pay attention that we have empty
spot so after the 2 spot the third one starts and then 2 in at the end is empty
so when I when I insert my pin I have to skip 1 2 and then
starts from here at the end the two is also skipped and here two also skept
so now let's look at a diagram here so we have two digits the same way
side-by-side decimal point ABCDEFG so here the common cathode so
this is a positive and a cathode and cathode is a negative. so pin number 10
is a and B is 9 C is 1 D is 4 and so forth but if you want to turn the digit
1 so you have to connect the common to 8 so this is digit 1 now let's turn it on
so 1 5 here this is 6 so that escaped from the 2 that is 6 7 & 8 so now I'm
connecting an 8 and 2 more pins left as you can see here so now to turn the
segment A as you can see on the diagram I have to connect it to the pin number 10
so that was 8 9 and then 10 10 is for A, 9 is for B so if I connect 9 that's a B and
the diagram C is in 1 so I have come here at one that is a B C that is C
as you can see on the diagram D however is at 4 so that one two three and
then four that is D. E is 3 so that is E and then F as you can see on
the diagram I created this diagram because I couldn't find it online F is
at sex so five is here six should be here and
then the same way by the way if I move this common to the next one so the
second digit F will be activated and then G as you can see is at 5 so if I
move this to 5. 5 is here so G is activated now if I move this you can see
on this diagram if I move this to 8 and so this will b turned on okay so
let's look at this. this is it for the single digit that we have here it says
the the forward current (IF) is twenty milli ampere and we have some other
characteristic this is the model that I have VF here it says
forward voltage is 2.2 volts and that's the current so we need these
two important parameters and then we also have to know our main source of voltage
this can be used at 3.3 volts with Arduino or 5 volts with a USB connector
which Arduino has but for different voltages you can do the same
calculation. so here is how it works the IF, I refers to current and F
forward so forward current is 20 milliampere which you can write it as
0.02A ampere and then VF forward voltage this is a typical 2.2 for this
one so each LED is a diode it's a light emitting diode and they are
set with a resistor to limit the voltage or voltage divider as well it will work
as a voltage divider so I put the values here so the
and that passes through here is 0.02 impaired and the resistor is here and
the LED's forward voltage is 2.2V volts that's 2
point 2 the formula is this V input the main voltage that comes here either
whatever you have 3 volts 5 volts V input minus VF divided by current
so here is 5 volts let's say I'm connecting 5 volts minus 2.2
divided by 0.02 ampere that's the current, so you need to put 140
ohm resistance on the path so here is for this example so 3 is common cathode
and then if I connect this so that's one of the segment is on so if you want to
use your resistor as you see on the diagram each diode H each LED needs it's
all resistors so you need to put the same number of this is eight seven
segment plus the disabled point if you use it otherwise 7 you need seven
resistors so each will have its own because this is common cathode you put
your resistors in a node here and this side and the voltage will come and goes
to go through this resistor as shown here so we will put the resistor here at
anode. now look at the circuit that I have this is just an arbitrary
resistor so I'm gonna put it here
so the positive here comes to a resistor. this line is all
connected so the positive comes and from here I have to put a wire a jumper wire
to connect these two. of course I have not done the calculation depending how
big it is you see it's very dim now it's preventing all the voltage to
come here so the voltage drop appears as a current passes through so this will
prevent the full voltage to appear here and it will absorb some of the
voltage so that's why we call it voltage dividers. okay that's it guys if you
liked this video please thumb up 👍 and also subscribe to my channel if you
haven't done so far