CMPx_C2 field descriptions (continued)
Field
Description
16
CH0F
Channel 0 input changed flag. This bit is set if the channel 0 input changed from the last comparison with
the fixed mux port.
15–14
NSAM
Number of sample clocks
For a given channel, this field specifies how many round-robin clock cycles later the sample takes place.
00
The comparison result is sampled as soon as the active channel is scanned in one round-robin clock.
01
The sampling takes place 1 round-robin clock cycle after the next cycle of the round-robin clock.
10
The sampling takes place 2 round-robin clock cycles after the next cycle of the round-robin clock.
11
The sampling takes place 3 round-robin clock cycles after the next cycle of the round-robin clock.
13–8
INITMOD
Comparator and DAC initialization delay modulus.
These values specify the round robin clock cycles used to determine the comparator and DAC initialization
delays specified by the datasheet. For example the initialization delay is 80us and the round robin clock is
100kHz, then INITMOD should be set to 80us/10us = 8.
000000
The modulus is set to 64 (same with 111111).
other values Initialization delay is set to INITMOD × round robin clock period
ACOn
The result of the input comparison for channel
n
. This field stores the latest comparison result of the input
channel
n
with the fixed mux port. Reading this bit returns the latest comparison result. Writing this field
defines the pre-set state of channel
n
.
38.9 CMP functional description
The CMP module can be used to compare two analog input voltages applied to INP and
INM. CMPO is high when the non-inverting input is greater than the inverting input, and
is low when the non-inverting input is less than the inverting input. This signal can be
selectively inverted by setting C0[INVT] = 1.
C0[IER] and C0[IEF] are used to select the condition that causes the CMP module to
assert an interrupt to the processor. C0[CFF] is set on a falling edge, and C0[CFR] is set
on a rising edge of the comparator output. The optionally filtered CMPO can be read
directly through C0[COUT].
38.9.1 Initialization
A typical startup sequence is as follows.
Chapter 38 Comparator (CMP)
Kinetis KE1xF Sub-Family Reference Manual, Rev. 4, 06/2019
NXP Semiconductors
895
Содержание KE1xF Series
Страница 2: ...Kinetis KE1xF Sub Family Reference Manual Rev 4 06 2019 2 NXP Semiconductors...
Страница 60: ...SysTick Clock Configuration Kinetis KE1xF Sub Family Reference Manual Rev 4 06 2019 60 NXP Semiconductors...
Страница 114: ...Initialization application information Kinetis KE1xF Sub Family Reference Manual Rev 4 06 2019 114 NXP Semiconductors...
Страница 138: ...Usage Guide Kinetis KE1xF Sub Family Reference Manual Rev 4 06 2019 138 NXP Semiconductors...
Страница 320: ...Private Peripheral Bus PPB memory map Kinetis KE1xF Sub Family Reference Manual Rev 4 06 2019 320 NXP Semiconductors...
Страница 342: ...Functional Description Kinetis KE1xF Sub Family Reference Manual Rev 4 06 2019 342 NXP Semiconductors...
Страница 360: ...Usage Guide Kinetis KE1xF Sub Family Reference Manual Rev 4 06 2019 360 NXP Semiconductors...
Страница 490: ...Interrupts Kinetis KE1xF Sub Family Reference Manual Rev 4 06 2019 490 NXP Semiconductors...
Страница 550: ...Memory map and register definition Kinetis KE1xF Sub Family Reference Manual Rev 4 06 2019 550 NXP Semiconductors...
Страница 562: ...Boot Kinetis KE1xF Sub Family Reference Manual Rev 4 06 2019 562 NXP Semiconductors...
Страница 662: ...Power supply supervisor Kinetis KE1xF Sub Family Reference Manual Rev 4 06 2019 662 NXP Semiconductors...
Страница 694: ...On chip resource access control mechanism Kinetis KE1xF Sub Family Reference Manual Rev 4 06 2019 694 NXP Semiconductors...
Страница 706: ...Usage Guide Kinetis KE1xF Sub Family Reference Manual Rev 4 06 2019 706 NXP Semiconductors...
Страница 724: ...Application Information Kinetis KE1xF Sub Family Reference Manual Rev 4 06 2019 724 NXP Semiconductors...
Страница 736: ...Usage Guide Kinetis KE1xF Sub Family Reference Manual Rev 4 06 2019 736 NXP Semiconductors...
Страница 750: ...Debug and Security Kinetis KE1xF Sub Family Reference Manual Rev 4 06 2019 750 NXP Semiconductors...
Страница 798: ...Functional description Kinetis KE1xF Sub Family Reference Manual Rev 4 06 2019 798 NXP Semiconductors...
Страница 808: ...Functional description Kinetis KE1xF Sub Family Reference Manual Rev 4 06 2019 808 NXP Semiconductors...
Страница 866: ...Usage Guide Kinetis KE1xF Sub Family Reference Manual Rev 4 06 2019 866 NXP Semiconductors...
Страница 1164: ...Usage Guide Kinetis KE1xF Sub Family Reference Manual Rev 4 06 2019 1164 NXP Semiconductors...
Страница 1178: ...Usage Guide Kinetis KE1xF Sub Family Reference Manual Rev 4 06 2019 1178 NXP Semiconductors...
Страница 1380: ...Usage Guide Kinetis KE1xF Sub Family Reference Manual Rev 4 06 2019 1380 NXP Semiconductors...
Страница 1472: ...Kinetis KE1xF Sub Family Reference Manual Rev 4 06 2019 1472 NXP Semiconductors...
Страница 1482: ...Kinetis KE1xF Sub Family Reference Manual Rev 4 06 2019 1482 NXP Semiconductors...