Remote-processing BASIC 52 Instrukcja Użytkownika Strona 95

  • Pobierz
  • Dodaj do moich podręczników
  • Drukuj
  • Strona
    / 163
  • Spis treści
  • BOOKMARKI
  • Oceniono. / 5. Na podstawie oceny klientów
Przeglądanie stron 94
RPBASIC-52 PROGRAMMING GUIDE
2-76
The overall speed of RPBASIC-52 slows down by about 3% when all ON LINE tasks are enabled.
Review HARDWAR E AND SOFTWARE INTERRU PTS in the first part of this manual for interrupt
handling and multitasking information.
RELATED none
ERRORS
BAD ARGUM ENT when number > 7 or I/O line is not between 0-7 or 100-123.
EXAMPLE
The following example sets up several interrupts.
10 ON LINE 0,1,1000
20 ON LINE 5,2,2000
30 ON LINE 3,3,3000
.
.
.
1000 PRINT "In LINE 0 interrupt"
1100 RETURN
2000 PRINT "In LINE 5 interrupt."
2010 PRINT "Suspending other line interrupts."
2020 ON LINE OFF
.
.
.
2300 PRINT "Resuming line interrupts."
2310 ON LINE ON , CLEAR
2320 RETURN
3000 PRINT "In LINE 3 interrupt."
3010 RETURN
Lines 10-30 set up ON LINE interrupts for lines 1, 2, and 3. For this example, line 5 cannot be interrupted by
any other line changes. Line 2020 suspends interrupts. The program continues to process this subroutine and
lines are still checked for changes. Line 2310 resumes line interrupts but it also clears out previous changes.
Przeglądanie stron 94
1 2 ... 90 91 92 93 94 95 96 97 98 99 100 ... 162 163

Komentarze do niniejszej Instrukcji

Brak uwag