Peripheral Beans cover all the hardware functionality and they are intended for expert use of the respective
peripherals. This bean implements the peripheral initialization of an Periodic Interrupt Timer (PIT) module
of the Freescale HCS12X MCU derivatives.
Peripheral initialization
The bean contains no high level methods or events, it provides only initialization of the hardware module. By default is the internal
initialization called automatically from the "PE_low_level_init" in CPU module, analogous to the initialization of other
PE beans. However the calling of this init code in the CPU module can be disabled and the user may call this function in
another module.
If the initialization property
"Call init in CPU init.code" is set to
"no" then the initialization is removed
from the CPU module code and the user have to call the
'BeanName_Init()' function elsewhere, i.e. in the main module.
Interrupt service
Processor Expert™ generates interrupt service support of PIT peripheral only for the interrupt vector which the ISR routine
name is specified for. Otherwise the interrupts are served by the default routine(s). The support include interrupt vector
hooking and priority setting for the respective interrupt vector.
The peripheral beans does not generate code for the interrupt service routines specified in the Interrupts properties group
of the Init_PIT bean (see Bean Inspector window). If there are any of the interrupts enabled in the bean the user is responsible
for the handling of such ISR's. Correct interrupt service routine "ISR name" must be implemented in the user code.
Warning:
This is low level bean. Usually it is not possible to use one setting of this bean for different microcontrollers.
PIT module
The period interrupt timer (PIT) is an array of 24-bit timers that can be used to trigger peripheral modules
or raise periodic interrupts.
The PIT includes these features:
- Four timers implemented as modulus down-counters with independent time-out periods.
- Time-out periods selectable between 1 and 224 bus clock cycles. Time-out equals m*n bus clock cycles with 1 <= m <= 256 and 1 <= n <= 65536.
- Timers that can be enabled individually.
- Four time-out interrupts.
- Four time-out trigger output signals available to trigger peripheral modules.
- Start of timer channels can be aligned to each other.
Peripheral Initialization Beans provide a low-level hardware approach to
initialize registers of the peripheral module. They are intended for experienced users.
This bean belongs to the category: CPU Internal Peripherals-Peripheral Initialization Beans