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.

Whats the easiest way to get 3 leds to run in order?

Status
Not open for further replies.

itsallgood

Member level 2
Member level 2
Joined
Mar 15, 2002
Messages
48
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,286
Activity points
329
led runner circuit

Hi guys,

Whats the easiest way to get 3 leds to run in order?

I've been trying for about 3 weeks make a led blink in proteous with pics, so is there any other way to do it, or could somebody PLEASE send me the proteous source file or somthing.

Regards
 

led runner

Hi,

I would use a modulus 3 counter and a 555 timer. The counter will continuously count 0-1-2-0-1-2-0. Thus, running in order. The 555 timer can be set at whatever oscillation rate you want to give the desired effect.

I hope that helps

david119
 

12c508 led

Instead of playing with 555s and counters try to get hands on PICAXE-08 microcontroller (8-pin PIC microcontroller with BASIC interpreter), connect 3 LEDs to its outputs and using your PC computer program it with something like this:
Code:
loop:

	high 0 			‘ switch on output 0
	pause 1000 			‘ wait 1 second
	low 0 			‘ switch off output 0

	high 1 			‘ switch on output 1
	pause 1000 			‘ wait 1 second
	low 1 			‘ switch off output 1

	high 4 			‘ switch on output 4
	pause 1000 			‘ wait 1 second
	low 4 			‘ switch off output 4
	
	goto loop 			‘ loop back to start

end

If you want the LEDs to 'run' faster, change 'pause 1000' to anythink you like, for example, 'pause 100' = 0.1s delay ..

Regards,
IanP
 

    itsallgood

    Points: 2
    Helpful Answer Positive Rating
Re: 3 LED runner??

Hi,

Thanks so much for both your answers :)

I think IanP has posted exactly what i want to do, with the pic chip, the problem for me comes in actually wiring the circuit up?

Could you please explain how you actually wire this circuit up...

Also, my programmer doesnt do the chip you mention, only PIC16F84A (which cost a lot), and 12c508 -- which i dont know if it can do much?

I can change your code in picbasic pro to hex, but then how would i actually wire the circuit up to make the leds come on. I have loaded your code into a 16f84a, and i can see it working in proteus -- i can see the little legs change colour (i've marked them in green), but nothing i can do will make the LED light up, i have tried every way of wiring the chip to the battery, to the led, and it doesnt work. If i just do a stright battery to LED, it lights up, but i do not know how to give the chip power.

**broken link removed**

Thanks so much.
 

Re: 3 LED runner??

First of all, to program PICAXE microcontrollers you don't need any special programmer .. just two resistors (10kΩ and 22kΩ) and access to the PC's serial port ..

Connecting LEDs to PIC microcontrollers' outputs is quite simple - in most cases outputs can source/sink sufficient current to drive typical LEDs ..
The only one thing to remember is a resistor that limits the LED's current .. see picture below ..

Regards,
IanP
 

Re: 3 LED runner??

you can use a three bit shifter counter,

q0 = d2.
q1 = d0
q2 = d1

best regards




itsallgood said:
Hi guys,

Whats the easiest way to get 3 leds to run in order?

I've been trying for about 3 weeks make a led blink in proteous with pics, so is there any other way to do it, or could somebody PLEASE send me the proteous source file or somthing.

Regards
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top