| ??? 08/27/06 22:57 Read: times |
#123160 - A51 Equates Responding to: ???'s previous message |
Hello James,
For grins I redid your program to the following and assembled it
using A51.EXE
;******************************************************
.EQU LIGHT, 0A7H ; LED connected to port P2.7
.ORG 0x00
RESET1: LJMP MAIN1
.ORG 0x30
MAIN1: CPL LIGHT ; Compliment P2.7
HERE1: SJMP HERE1 ; Hang here till dooms day
.END
;******************************************************
I then disassembled it with Jeff Post wonderful disassembler
D51.EXE to the following.
;******************************************************
; 8051 Disassembly of temp1.hex
org 0
RESET1: ljmp MAIN1 ; 0000 02 00 30
org 30h
MAIN1: cpl p2.7 ; 0030 b2 a7
HERE1: sjmp HERE1 ; 0032 80 cc
end
;******************************************************
Using JSIM.EXE simulator I single step thru the program and
verified that P2.7 complimented when told.
The only thing missing was a comma in the original EQU line (.EQU
LIGHT, 0A7H)
;******************************************************
hex of program
:03000000020030CB
:04003000B2A780CC27
:00000001FF
;******************************************************
Hope this helps.
Regards,
Charles Bannister
Ps I also misuse the terms assembler and compile (and lots more).
|
| Topic | Author | Date |
| equ statement | 01/01/70 00:00 | |
| EQU | 01/01/70 00:00 | |
| A51 Equates | 01/01/70 00:00 | |
| a51 and d51 | 01/01/70 00:00 | |
update? | 01/01/70 00:00 | |
| Syntax | 01/01/70 00:00 | |
| what a51 | 01/01/70 00:00 | |
| Most are NOT Keil! | 01/01/70 00:00 | |
| and still named a51 | 01/01/70 00:00 | |
| A51 expect comma in equ statement | 01/01/70 00:00 | |
| Another A51 | 01/01/70 00:00 | |
| PseudoSam(tm) 51 assembler. | 01/01/70 00:00 | |
| But he's using TASM51 - not A51! | 01/01/70 00:00 |



