Code: Select all
start:
clr.w %d0
wait01:
bsr.w ResetWatchdog
bsr.w WasteTime
addq.w #1, %d0
cmpi.w #1000, %d0
beq.w Exit1
jmp.s wait01
WasteTime:
nop
nop
nop
nop
rts
ResetWatchdog:
move.b #0x55, (0xFFFA55).l | Reset COP1
move.b #0xAA, (0xFFFA55).l
bclr #7, (0xFFFA21).l | Reset COP2
bset #7, (0xFFFA21).l
rts
Exit1:
.end
Code: Select all
start:
clr.l %d0
wait01:
bsr.w ResetWatchdog
bsr.w WasteTime
addq.l #1, %d0
cmpi.l #1000, %d0
ble.s wait01
rts
WasteTime:
nop
nop
nop
nop
rts
ResetWatchdog:
move.b #0x55, (0xFFFA55).l | Reset COP1
move.b #0xAA, (0xFFFA55).l
bclr #7, (0xFFFA21).l | Reset COP2
bset #7, (0xFFFA21).l
rts
.end