- Open uVision.
- Navigate to Project -> New uVision Project.
- Select the path and give a filename (e.g., exp0).
- Choose the INTEL -> 80C51GB option. 8051
- Copy startup: Yes.
- Within the project, click on the RGY icon for the clock.
- Add source files by navigating to Project Directory -> Source Group (double click) -> Add Files.
- Select the appropriate .A51 files and click OK.
- click wizard icon left to RGY icon
- Output <- menubar check create hex
- download file
- set origin
- set PC
- set disassembly
- plug in J3/J7 port of trainer kit
- turn on power trainer-kit & bb
- Load memory address to pointer:
MOV DPTR, #9000H
. - Access pointer:
MOVX A, @DPTR
. - Access variable:
MOVX @DPTR, B
.
- Control transfer through functions and loops.
- No explicit return keyword; use the JMP family to skip.
- Sequential flow of control using labels and conditional jumps.
Loop_1:
...
Loop_2:
...
CJMP Loop_1
Loop_3:
...
CJNE Loop_2
- Rebuild all target files in Keil Vision to generate the .hex file.
- Open 51e Trainer and download the .hex file from the explorer.
- Disassemble and set the start address to 8100H.
- Set the PC to 8100H and run stepwise.
- Use conditional jumps (
JC
) for comparisons. - Run to break and inspect the logic.
- Search key in memory to display the corresponding index.