Discussion in "General help Guidance and Discussion" started by    ASLANPETER    Sep 6, 2010.
Mon Sep 06 2010, 08:05 PM
Hi Guys,
forgive me, it is surely a silly question but i am stuck. i need to control a led with an output pin of an 8051 micrcontroller. basically the micrcontroller is running a code and when a condition is verified ,an output pin is cleared. this ouput is linked to the anode of a led which should be wired to the VCC via a resisitor. the resistor and LED should be placed on a dedicated bread board which hence should be connected to 5v voltage. what should I do with the GND section on the broadboard?? should i leave it unconnected? will the VCC wire make any sense on its own without GND? or should i rather not to power up the breadboard and connect a resistor leg to the VCC output of the power supply? which is the correct way and why?
thank you

[ Edited Tue Sep 07 2010, 12:53 AM ]
Tue Sep 07 2010, 02:13 AM
the 'gnd' to the LED's cathode is provided by the 8051's port pin,hence you needn't provide gnd on the breadboard...simply Vcc to the anode through the resistor and a port pin connection to the cathode.
But this is assuming you are using the same supply for both the mico and the LED bb.If not you'll have to connect the gnd terminals of both the supplies at some point.
Tue Sep 07 2010, 02:18 PM
There are two ways you can connect LEDs to controller port.

1. Active High Logic
2. Active Low Logic.

1. Active high logic means LED will be on when port pin is 1 and LED will be off when pin is 0. In this type of arrangement, LED is driver from port pin of controller if port pin does not have enough current then a pullup is used on.

       / Resistor
       |   LED
Port -----|>

2. Active low is other way around, when port pin is 0, LED is on and when port pin is 1 LED is off. In this type of arrangement port pin is used as current sinking device, when LED is on current will sink from VCC through resistor and LED then into microcontroller pin. typical connections are like this.

         LED       R
Port -----|<|----/\/\/\---VCC

Tags interfacing LED to controlleractive low led circuitactive high led circuitled interfacing with microcontroller

Get Social


Powered by e107 Forum System


Thu May 13 2021, 07:18 PM
Pretty section of content. I just stumbled upon your weblog and in accession capital to assert that I get actually enjoyed account your blog posts. Any way I will be subscribing to your augment and even I achievement you access consistently quickly. https://mkfinstitute.com Trisha Trisha
Wed May 12 2021, 01:23 PM
Jed Roan
Now you can promote your site all over the internet for FREE: http://www3.listofsitesthatacceptfreeads.club
Wed May 12 2021, 08:20 AM
If some one wants to be updated with most recent technologies afterward he must be visit this web page and be up to date every day. annual credit report https://creditscoresetf.com
Wed May 12 2021, 06:11 AM
Great website. A lot of useful information here. I'm sending it to some pals ans also sharing in delicious. And of course, thanks on your effort! annual credit report https://creditscorecheckn.com
Wed May 12 2021, 05:37 AM
Does your site have a contact page? I'm having problems locating it but, I'd like to shoot you an email. I've got some recommendations for your blog you might be interested in hearing. Either way, great website and I look forward to seeing it improve over time. get credit report https://freecreditreportww.com



Thu Jun 25 2020, 03:46 PM
Mon Jun 22 2020, 03:03 PM
Tue Jun 16 2020, 05:10 PM
Sat Jun 13 2020, 09:43 PM
Thu May 21 2020, 12:44 PM
Thu May 21 2020, 01:28 AM
Wed May 20 2020, 07:05 PM
Wed May 20 2020, 11:52 AM


Guests: 99, Members: 0 ...

most ever online: 182184
(Members: , Guests: 182184) on 06 Aug 2010: 05:37 AM

Members: 38215
Newest member: Mirza123