Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

Is it wrong to connect led in this way to at89c51???

Status
Not open for further replies.

subinalex

Junior Member level 1
Joined
May 27, 2010
Messages
15
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Location
kattappana
Activity points
1,427
dear friends,

For a project i have 8 leds connected to port 0 with 1k zip pull ups
now my question is about connecting led

1.Is it safe connecting led's anode to Vcc through a 220 ohm resistor and cathode to port 0 which already has 1k zip resistors.

2. for connecting led to output of a driver ic l293d..which output 9v...what confgn of led i must use?..and need i connect it with cathode of led to pin of l293d and anode to vcc through 220 ohm?.....

Please answer my questions...i am afraid to connect it because i fear uc will burn or so?...and i hav only 1 uc.....

Added after 6 minutes:

when i connected buzzer red wire to port pin and black wire to gnd i couldnt hear any sound....i also connected led also in this manner...then it didnt blinked...


but when i connected its red wire to vcc and black wire to port pin i was able to hear sound as per i wrote in the program......thiss why i ask whether same should be done for leds.??
 

Hi,
Becouse its OutHi= max ca 7.6V & OutLow= max ca 1.4V, your LED will have ca. 7.6V = you need a current limiting serial resistor for both configuration...
You must read a datasheet of your buzzer, maybe it need some voltage/current threshold to work_as immer_ & your uC output was others controlled...
I dont believe that your uC can be dead if the output is loaded with 1KOhm & a LED, on a 5V system it means only ca. 3mA output current.
Most modern uC delivers up to 20 mA/pin, but often has a power limit/package...:)
K.
 

subinalex said:
dear friends, For a project i have 8 leds connected to port 0 with 1k zip pull ups now my question is about connecting led
1.Is it safe connecting led's anode to Vcc through a 220 ohm resistor and cathode to port 0 which already has 1k zip resistors.

2. for connecting led to output of a driver ic l293d..which output 9v...what confgn of led i must use?..and need i connect it with cathode of led to pin of l293d and anode to vcc through 220 ohm?.....

Please answer my questions...i am afraid to connect it because i fear uc will burn or so?...and i hav only 1 uc.....

Added after 6 minutes:

when i connected buzzer red wire to port pin and black wire to gnd i couldnt hear any sound....i also connected led also in this manner...then it didnt blinked...

but when i connected its red wire to vcc and black wire to port pin i was able to hear sound as per i wrote in the program......thiss why i ask whether same should be done for leds.??

If your supply is 5volts, the 1K sips pulling up the port 0 is a bit more. You may use a 4K7 sip comfortably. Connecting of LED's + to vcc and 220E to port is fine when vcc is 5 volts.

For connecting led to output of a driver ic l293d..which output 9v...first confirm on which logic of the IC you need to glow the LED? LOw or HI and then connect it in the required way. 220E is a bit low for Vcc 9 v. 1K will suit best for a RED LED.

8051's ports tend to pull toward GND when activated. You need to configuer your external circuits in the same way. Unlike in PIC, you can make a PIN HI, LOW, or even Float it.
Cheers
 

dear friends....


My LED whose anode connected to port 0 which has a zip resistor(pull up) and cathode to gnd is not blinking wherea on multimeter it shows the port is high....


shall i connect led's anode to pull up resistor and cathode to the port pin....now as the zip resistor and port pin is parallel....i have a doubt is it shorted or so?......
 

Hi,
Do you know pls how many voltage & current your blinking LED needs?
Test it pls to first on an external supply...
K.
 

hey friends..........

:D i got all leds blinking.....

i connected anode of green led to pull up resistor of port 0 and cathode to ground ..it blinked...

then i connected cathode of yellow led to port 2 and its anode to 5 v through 220 ohm....got it also correct similarly i connected buzzer also working fine.....


AM I IN CORRECT PATH.....????:?::?::?:
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top