Downloads >> Assembly Codes >> LED Flashing
Assembly code for LED Flashing

Sample code for LED Flashing using delay subroutine.
Following code can be using for 8051 and 8052 ICs like: 89c51, 89c52, 89s51, 89s52, 89c2051.

 

org 0000h jmp start start: mov p1,#FFh call delay mov p1,#00h call delay jmp start delay: mov r0,#10 del2: mov r1,#250 del1: mov r2,#250 djnz r2,$ djnz r1,del1 djnz r0,del2 ret end