You are on page 1of 3

ADC

General Info
Properties
Methods
Events
Types and constants
Application Notes
Typical Usage
Types & definitions
Embedded Components
Component ADC
A/D converter
Component Level: High
Category: CPU Internal Peripherals-Converter-ADC
Events:
(Events are call-back functions called when an important event occurs. Please see the Embedded Components page for
more information.)
EventModule - Name of the user module (without extension), where the events from
this component are placed.
BeforeNewSpeed - This event is called when the CPU speed mode is being changed
(using CPU methods) - before the change. The event is enabled only if speed modes
are supported in the target CPU component (more than one speed mode).
ANSIC prototype: void BeforeNewSpeed(void)
AfterNewSpeed - This event is called when the CPU speed mode is being changed
(using CPU methods) - after the change. The event is enabled only if speed modes are
supported in the target CPU component (more than one speed mode).
ANSIC prototype: void AfterNewSpeed(void)
OnEnd - This event is called after the measurement (which consists of 1 or more
conversions) is/are finished.
The event is available only when the Interrupt service/event property is enabled.
ANSIC prototype: void OnEnd(void)
Priority - OnEnd priority. Default value is based on the interrupt priority defined in
property A/D interrupt priority. For details see description below of the page.
Events for Freescale 5685x, 56F801x, 56F802x, 56F803x, 56F80x, 56F81x, 56F82x,
56F83x, MCF5213_12_11, MCF521xx, MCF5221x, MCF5222x, MCF5223x and
MCF5225x derivatives.
OnHi ghLi mi t - This event is called when the high limit any channel has been
exceeded. If the Number of conversions property is greater than 1, then during one
measurement this event may be invoked up to the Number of conversions times
per each of the measured channels. The event is available only when the Interrupt
service/event property is enabled.
ANSIC prototype: void OnHighLimit(void)
Priority - Priority of the event routine. Default value is based on the interrupt
priority defined in property Interrupt pri ori ty. For details see description below
of the page.
OnLowLimit - This event is called when the low limit any channel has been
exceeded. If the Number of conversions property is greater than 1, then during one
measurement this event may be invoked up to the Number of conversions times
Pgina 1 de 3 Component documentation - Events
21/03/2014 http://127.0.0.1:62853/help/ntopic/com.freescale.doc.processorexpert.components/Beans/...
per each of the measured channels. The event is available only when the Interrupt
service/event property is enabled.
ANSIC prototype: void OnLowLimit(void)
Priority - Priority of the event routine. Default value is based on the interrupt
priority defined in property Interrupt pri ori ty. For details see description below
of the page.
OnZeroCrossing - This event is called when the Zero crossing on any channel has
occurred. The Zero crossing means that the sign of the result has been changed in
the selected direction by Zero crossing property. If the Number of conversions
property is greater than 1, then during one measurement this event may be invoked
more than once per each of the measured channels.
Version specific i nformati on for 56800 derivatives
This event is available only when the Interrupt service/event property is enabled
and MeasureChan and EnableIntChanTrigger methods are disabled - "don't
generate code".
Version specific i nformati on for MCF derivatives
This event is available only when the Interrupt service/event property is enabled
and MeasureChan and EnableExtChanTrigger methods are disabled - "don't
generate code".
ANSIC prototype: void OnZeroCrossing(void)
Priority - Priority of the event routine. Default value is based on the interrupt
priority defined in property Interrupt pri ori ty. For details see description below
of the page.
Events only if ADC support Self calibration.
OnCal ibrationEnd - This event is called when the calibration has been finished.
User should check if the calibration pass or fail by Calibration status method./nThis
event is enabled only if the Interrupt service/event property is enabled.
ANSIC prototype: void OnCalibrationEnd(void)
Priority - Priority of the event routine. Default value is based on the interrupt
priority defined in property A/D i nterrupt pri ori ty. For details see description
below of the page.
Methods only if ADC support Error event.
OnError - This event is called when some of the error interrupts (not the error
returned by a given method) occur. The errors can be read using GetError method.
The event is available only when the Interrupt service/event property is enabled.
ANSIC prototype: void OnError(void)
Pgina 2 de 3 Component documentation - Events
21/03/2014 http://127.0.0.1:62853/help/ntopic/com.freescale.doc.processorexpert.components/Beans/...
Priority - OnError priority. Default value is based on the interrupt priority defined
in property Error interrupt priority. For details see description below of the
page.
Methods only if ADC support Abort event.
OnAbort - This event is called when abort interupt occurs. The event is available
only when the Interrupt service/event property is enabled.
ANSIC prototype: void OnAbort(void)
Priority - OnError priority. Default value is based on the interrupt priority defined
in property Abort i nterrupt pri ori ty. For details see description below of the
page.
For each generated event it is possible to set:
Procedure Name - name of procedure (written by user) that handles the event.
Pri ori ty (if supported) - priority of the user procedure (for instance we may set it here as
uninterruptable). Please refer to chapter "Processor Expert Priority System" for more
PROCESSOR EXPERT is trademark of Freescale Semiconductor, Inc.
Copyright 1997 - 2013 Freescale Semiconductor, Inc.
Pgina 3 de 3 Component documentation - Events
21/03/2014 http://127.0.0.1:62853/help/ntopic/com.freescale.doc.processorexpert.components/Beans/...

You might also like