| ??? 07/11/01 22:27 Read: times |
#13156 - RE: Real Time Clock |
Hi. This is the code, note I'm only using a fixed LRV and HRV, cause I have the same crystal (11.059MHz) on both boards.
My major concern since I got running Ok on a simulator and not on the boards was that may be the EV boards are using the timer1 for the rs232 connections, then I changed to T0 and I got the same erratic behaivor. The boards are workin fine, caus I was able to load a couple of led flashing programs I made, and those programs worked fine. again this is the code, hope someone can help me. pd please excuse my English, I´m spanish speaking native, so sometimes I got spelling-orthography-grammar errors. HOURS EQU 07Ch MINUTES EQU 07Dh SECONDS EQU 07Eh TICKS EQU 07Fh CRYSTAL EQU 11059000 TMRCYCLEEQU 12 TMR_SEC EQU CRYSTAL/TMRCYCLE F20TH EQU 46079 RESET_VALUEEQU 19457 HRV EQU 76 LRV EQU 1 LJMP MAIN PUSH ACC PUSH PSW CLR TR1 MOV TH1,#HRV MOV TL1,#LRV SETB TR1 DJNZ TICKS,EXIT_RTC MOV TICKS,#20 INC SECONDS MOV P1,SECONDS MOV A,SECONDS CJNE A,#60,EXIT_RTC MOV SECONDS,#0 INC MINUTES MOV A,MINUTES CJNE A,#60,EXIT_RTC MOV MINUTES,#0 INC HOURS EXIT_RTCPOP PSW POP ACC RETI MAIN MOV TH1,#HRV MOV TL1,#LRV MOV TMOD,#10h SETB TR1 MOV HOURS,#00 MOV MINUTES,#00 MOV SECONDS,#00 MOV TICKS,#20 SETB EA SETB ET1 MOV P3,#00H MOV P1,#00H INICIO MOV R0,SECONDS MOV P1,R0 LJMP INICIO END |
| Topic | Author | Date |
| Real Time Clock | 01/01/70 00:00 | |
| RE: Real Time Clock | 01/01/70 00:00 | |
| RE: Real Time Clock | 01/01/70 00:00 | |
| RE: Real Time Clock | 01/01/70 00:00 | |
| RE: Real Time Clock | 01/01/70 00:00 | |
| RE: Real Time Clock | 01/01/70 00:00 | |
| RE: Real Time Clock | 01/01/70 00:00 | |
| RE: Real Time Clock | 01/01/70 00:00 | |
| RE: Real Time Clock | 01/01/70 00:00 | |
| RE: Real Time Clock | 01/01/70 00:00 | |
how to send data from ext rAM to PC ? | 01/01/70 00:00 |



