??? 01/19/11 01:22 Read: times |
#180696 - First Cycle Compete Responding to: ???'s previous message |
This is for
c) homework assignment reasons? i am not familier with C language and i have already told you that i have just started progrmmimng on microcontrollers so please keep in mind MY LEVEL. Now i am able to run the first cycle (sand dropping) now please suggest me to complete the second cycle (empty the pot) using logical operation and loops please go through the below program ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;8LEDs SAND WATCH ;ICs 89S52 ;Crystal 12MHz ;Hard Ware Delcaration LEDPORT EQU P1 ;Constant Variable STACKVL EQU 70H COUNTER EQU 30H ;Start of Main Program ORG 0000H ;originate AJMP PWRON ;jump to label PWRON ORG 0003H ;interrupt not used in the program RETI ORG 000BH ;interrupt not used in the program RETI ORG 0013H ;interrupt not used in the program RETI ORG 001BH ;interrupt not used in the program RETI ORG 0023H ;interrupt not used in the program RETI ORG 002BH ;interrupt not used in the program RETI ORG 0033H ;interrupt not used in the program RETI PWRON: MAIN: MOV R3,#00H MOV R1,#08H MOV COUNTER,#08H LOOP2: MOV R4,#080H MOV R2,COUNTER DEC COUNTER LOOP1: MOV A,R4 RL A MOV R4,A ADD A,R3 CPL A MOV LEDPORT,A CPL A ACALL DELAY DJNZ R2,LOOP1 MOV R3,A DJNZ R1,LOOP2 SJMP MAIN DELAY: MOV R5,#01H LAP2: MOV R6,#01H LAP1: MOV R7,#0C8H LAP0: DJNZ R7,LAP0 DJNZ R6,LAP1 DJNZ R5,LAP2 RET END |
Topic | Author | Date |
Help Help Codes for 8 LEDs Sand Watch in ASSEMBLY | 01/01/70 00:00 | |
Hourglass? | 01/01/70 00:00 | |
8 LEDs sand watch | 01/01/70 00:00 | |
Table or nested loops | 01/01/70 00:00 | |
Didn't you just repeat exactly the same post? | 01/01/70 00:00 | |
possible approach | 01/01/70 00:00 | |
LED Patterns | 01/01/70 00:00 | |
Using spreadsheets | 01/01/70 00:00 | |
Further -- Consider | 01/01/70 00:00 | |
Cart before horse | 01/01/70 00:00 | |
What does AND and OR? | 01/01/70 00:00 | |
last time I looked 89S52 had 8 kByte flash, ASSEMBLY? | 01/01/70 00:00 | |
First Cycle Compete | 01/01/70 00:00 | |
How to post legible source code | 01/01/70 00:00 | |
algorithm, assembler | 01/01/70 00:00 | |
Thanks for the help and support | 01/01/70 00:00 |