Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

Atmega32

Status
Not open for further replies.

Computer_Smart

New Member
Hi i am trying to make a Wig Wag sequence for a traffic light using the Atmega32

I have already programmed in Atmel AVR software the 0.5 second delay routine based on a processor speed of 8MHz.

.CSEG

LDI R16,0xC1
LDI R17,0x4B
LDI R18,0x15



AGAIN:

DEC R16
BRNE AGAIN

DEC R17
BRNE AGAIN

DEC R18
BRNE AGAIN


SELF: JMP SELF
now i need to create a routine that will produce flashing red lights (Wig Wag sequence see image below or go to this site **broken link removed** ) on the major and minor roads. The flash rate is to be a repetitive 0.5 second on 0.5 second off.

Can someone please help me to program this. Thanks

**broken link removed**
 
Last edited:
Status
Not open for further replies.

New Articles From Microcontroller Tips

Back
Top