Motorola M68CPU32BUG User Manual Page 122

  • Download
  • Add to my manuals
  • Print
  • Page
    / 196
  • Table of contents
  • BOOKMARKS
  • Rated. / 5. Based on customer reviews
Page view 121
SYSTEM CALLS
M68CPU32BUG/D REV 1 5-8
.DELAY Timer Delay Function .DELAY
5.2.4 Timer Delay Function
SYSCALL .DELAY
TRAP CODE: $0043
The .DELAY function generates timing delays based on the processor clock. This function uses
the MCU periodic interrupt timer for operation. The user specifies the desired delay count
(number of interrupt pulses generated). .DELAY returns system control to the user after the
specified delay is completed. Initialize (.TM_INI) and start (.TM_STR0) the timer before using
the .TM_RD function.
Entry Conditions:
SP ==> Delay time (number of interrupt pulses) <long>
Exit Conditions Different From Entry:
SP ==> The timer keeps running after the delay and parameters are
removed from the stack.
EXAMPLE
SYSCALL .TM INI
Initialize timer
SYSCALL .TM_STR0
Start timer
PEA.L &1500
Load a 1500 interrupt pulse delay
SYSCALL .DELAY
*
*
*
PEA.L &50000 Load a 50000 interrupt pulse delay
SYSCALL .DELAY
Page view 121
1 2 ... 117 118 119 120 121 122 123 124 125 126 127 ... 195 196

Comments to this Manuals

No comments