Discussion in "General help Guidance and Discussion" started by    ASLANPETER    Sep 6, 2010.
Mon Sep 06 2010, 04:05 PM
#1
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 Mon Sep 06 2010, 08:53 PM ]
Mon Sep 06 2010, 10:13 PM
#2
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, 10:18 AM
#3
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.

      VCC
       |
       \
       / Resistor
       \
       /
       |   LED
Port -----|>
|---GND
Pin


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
Pin

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

Get Social

Information

Powered by e107 Forum System

Conversation

scena
Wed May 20 2020, 03:59 AM
Does anyone have microcontroller programming software for STC15F104W (core 8051, 4 k, 128 byte, 6 I/O pin, UART ... DIL8), that works?
Sun May 03 2020, 01:08 AM
Tamu Gurung
Hi I am looking for a assembly language program for a digital decimal counter. Time counts max limit of 2 mins starting from 2.00 mins and ending at 0.00. time is to be displayed on 4 7-segment LED displays. Edsim51 simulator to be used. Thanks
Wed Mar 25 2020, 07:09 PM
Tajammul
Sir kindly send the code file i2c for 8051
ExperimenterUK
Sat Mar 14 2020, 04:06 AM
@ Rohitnani,ABEBE..which project ?
Fri Mar 13 2020, 06:25 PM
ABEBE
how can get hadwere of this project
Rohitnani
Sat Mar 07 2020, 09:41 PM
Sir, Could you please send me the zip file input password....
Wed Feb 26 2020, 09:28 PM
Peter Parker
Is it possible to send multiple messages using only 1 GSM module?
Sat Feb 01 2020, 02:42 PM
Pearl Olin
Hello,
Wed Jan 22 2020, 10:46 PM
MINU CHAUDHARY
I m getting errors while simulation process during interfacing socket output and lcd... Can i get the report of ur project which is same as us.
Tue Jan 14 2020, 11:38 AM
shubham kharade
when i am trying to simulate the program in Proteus 8 professional, I am getting some errors as cannot find module file dhtxx.md can u help me

Downloads

Comments

Davidthils
Thu May 21 2020, 08:44 AM
Jakeror
Wed May 20 2020, 09:28 PM
motorCar
Wed May 20 2020, 03:05 PM
Vordrync
Wed May 20 2020, 07:52 AM
JadenjiT
Wed May 20 2020, 03:15 AM
scena
Tue May 19 2020, 06:08 PM
CodySiz
Tue May 19 2020, 02:22 PM
ClaireSat
Mon May 18 2020, 09:50 PM

Online

Guests: 45, Members: 0 ...

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

Members: 38211
Newest member: Davidthils
Forum Activity
xrxx Avatar
Posted By xrxx
Thu Apr 30 2020, 06:59 AM
BCD MULTIPLICATIONAssume that you have to 2 BCD nu...
liqian Avatar
Posted By liqian
Tue Apr 28 2020, 05:26 AM
I happened to see your post and I got many useful ...
ExperimenterUK Avatar
Posted By ExperimenterUK
Tue Apr 28 2020, 04:21 AM
The code is hard to read.Please zip it and attach ...
rogermado Avatar
Posted By rogermado
Sun Apr 26 2020, 01:53 AM
@ExperimenterUK, thanks for your reply. You'll fin...
ExperimenterUK Avatar
Posted By ExperimenterUK
Sat Apr 25 2020, 05:42 PM
Some simulators handle displays better than others...
rogermado Avatar
Posted By rogermado
Sat Apr 25 2020, 03:59 PM
Hello everyone, sorry in advance if i'm not in the...
PHANTOM28 Avatar
Posted By PHANTOM28
Fri Feb 28 2020, 10:25 AM
Hi.I hope you all can help me. I am relatively ne...
ExperimenterUK Avatar
Posted By ExperimenterUK
Fri Feb 21 2020, 05:05 PM
ajay_bhargav Avatar
Posted By ajay_bhargav
Fri Feb 21 2020, 04:45 AM
Yes you can do that.1. Create a channel @Thingspea...
ananyagupta Avatar
Posted By ananyagupta
Thu Feb 20 2020, 03:58 AM
With regards to the particular characters sent to ...