Cx51 User's Guide

INTERVAL Compiler Directive

Abbreviation

None.

Arguments

An optional interval, in parentheses, for the interrupt vector table. The permitted range is 3 — 64.

Default

INTERVAL (8)

µVision

Options — C51 — Misc controls.

Description

The INTERVAL directive specifies an interval for interrupt vectors. When this directive is specified, the compiler locates interrupt vectors at the absolute address calculated by:

(interval × n) + offset + 3,

where:

intervalis the argument of the INTERVAL directive (default 8).
nis the interrupt number.
offsetis the argument of the INTVECTOR directive (default 0).

Note

  • An interval specification is required for SIECO-51 derivatives which define interrupt vectors in 3-byte intervals.
See Also

INTVECTOR, NOINTVECTOR

Example
C51 SAMPLE.C INTERVAL(3)

#pragma interval(3)