naeem_28
Newbie level 4
hi
please help me i want to interface 24c16 eeprom with 89c51
i just want when the power cut and resume the power 89c51 should not reset, i want 89c51 start from that point where the power cut ,i don't know how to write eeprom interface code
my asm code is below,
with regard,
thank u
$mod51
ORG 0b
mov p0,#11111111b
mov p2,#0b
mov p3,#0b
start:
mov p1,#11111111b
name: jb p0.0,name
clr p1.0
acall was
clr p1.1
acall was
clr p1.2
acall was
clr p1.3
acall was
clr p1.4
acall was
clr p1.5
acall was
clr p1.6
ahmad: jb p0.6,ahmad
sjmp start
was: mov r0,#45
loop1: mov r1,#25
loop2: mov r2,#250
loop3: nop
djnz r2,loop3
DJNZ r1,loop2
djnz r0,loop1
ret
end:sad::sad:
please help me i want to interface 24c16 eeprom with 89c51
i just want when the power cut and resume the power 89c51 should not reset, i want 89c51 start from that point where the power cut ,i don't know how to write eeprom interface code
my asm code is below,
with regard,
thank u
$mod51
ORG 0b
mov p0,#11111111b
mov p2,#0b
mov p3,#0b
start:
mov p1,#11111111b
name: jb p0.0,name
clr p1.0
acall was
clr p1.1
acall was
clr p1.2
acall was
clr p1.3
acall was
clr p1.4
acall was
clr p1.5
acall was
clr p1.6
ahmad: jb p0.6,ahmad
sjmp start
was: mov r0,#45
loop1: mov r1,#25
loop2: mov r2,#250
loop3: nop
djnz r2,loop3
DJNZ r1,loop2
djnz r0,loop1
ret
end:sad::sad: