English
Language : 

Z8FS021 Datasheet, PDF (67/68 Pages) Zilog, Inc. – Select from an assortment of lenses and pyroelectric sensors to best fit your application
ZMOTION® Intrusion Detection
Product Specification
59
Appendix C. Software Support Files and Project
Configuration
The following four files are provided to support the PIR Engine:
PIR_API.c. Contains the API register definitions and locates them at there appropriate
places in memory.
PIR_API.h. Provides the bit definitions for the API registers and also contains the macro
definitions for EPIR_INIT and EPIR_ADC_ISR.
API_INIT_xx.h. This header file contains the default API settings specific to the lens and
pyroelectric sensor being used. The application code loads the API registers with these
values prior to executing the EPIR_INIT macro. Several versions of these files are avail-
able from the Zilog website with tested configurations supporting the available lenses and
pyroelectric sensors. These header files are included as the source code associated with the
ZMOTION Detection Lens and Pyro Sensor Configuration Guide (WP0018). Refer to
WP0018 and to the ZMOTION Lens and Pyroelectric Sensor Product Specification
(PS0286) to select the appropriate API_INIT_xx file for the selected lens.
startupePIR.asm. This C start-up file replaces startups.asm or startupl.asm in
ZDS II. It contains the environment initialization, stack, and register pointer configurations
specifically required for a ZMOTION project.
ZDS II Project Settings
The Zilog Developer Studio Integrated Development Environment (ZDS II IDE) is used
for software development. Because the compiled application code has no vision into the
operation of the PIR Engine, it is important to ensure that the application’s working RAM
area is not affected by Engine operations. To facilitate this, the PIR Engine uses working
register group E (in the address range E0h–EFh) as its working RAM area, and the appli-
cation code uses working register group 0 (as defined in startupePIR.asm). These
operations are automatically handled by the compiler, and examples are provided with the
available sample projects. The Small Memory Model must be used for the application soft-
ware.
PS028806-0315
Appendix C. Software Support Files and Project Configuration