FormatCode Code Formatter is based on serveral powerful syntax parser engines
so you can exactly control the appearance of your source code. Here is the code formatting demo of
FormatCode Assembly 8051 / Asm51 Code Formatter to prove the ability of
code formatting functions of FormatCode:
RS EQU P3.0
RW EQU P3.1
E EQU P3.5
ORG 0000H
MOV P1,#00000001B ACALL ENABLE
MOV P1,#00000001B ACALL ENABLE
MOV P1,#00111000B ACALL ENABLE
MOV P1,#00001111B ACALL ENABLE
MOV P1,#00000110B ACALL ENABLE
MOV P1,#0C0H ACALL ENABLE
mov p1,#01000001b SETB RS
CLR RW
CLR E
ACALL DELAY
SETB E
AJMP $
ENABLE: CLR RS CLR RW
CLR E
ACALL DELAY
SETB E
RET
DELAY: MOV P1,#0FFH
CLR RS
SETB RW
CLR E
NOP
SETB E
JB P1.7,DELAY RET
END
RS equ P3.0
RW equ P3.1
E equ P3.5
org 0000H
mov P1, #00000001B acall ENABLE
mov P1, #00000001B acall ENABLE
mov P1, #00111000B acall ENABLE
mov P1, #00001111B acall ENABLE
mov P1, #00000110B acall ENABLE
mov P1, #0C0H acall ENABLE
mov p1, #01000001b setb RS
clr RW
clr E
acall DELAY
setb E
ajmp $
ENABLE: clr RS clr RW
clr E
acall DELAY
setb E
ret
DELAY: mov P1, #0FFH
clr RS
setb RW
clr E
nop
setb E
jb P1.7, DELAY ret
end
Click here to preview the 8051 Assembly / Asm51 Code Formatting Demo 1.
With FormatCode 8051 Assembly Code Formatters, you can format and transform any foreign Asm51 source code to meet your preferred coding style or any common code convention in several seconds!
|