Enhanced Modular Input/Output Subsystem (eMIOS200)
23-24
Freescale Semiconductor
PXR40 Microcontroller Reference Manual, Rev. 1
Figure 23-14. SAIC with Both Edges Triggering Example
23.4.1.1.3
Single Action Output Compare (SAOC) Mode
In SAOC mode (MODE = 000_0011), a match value is loaded in register A2 and then transferred to
register A1 to be compared with the selected time base. When a match occurs, the EDSEL bit selects
whether the output flip-flop is toggled or the value in EDPOL is transferred to it. At the same time, the
FLAG bit is set to indicate that the output compare match has occurred. Writing to the EMIOS_CADR[
n
]
register stores the value in register A2 and reading to the EMIOS_CADR[
n
] register returns the value of
register A1.
An output compare match can be simulated in software by setting the FORCMA bit in the
EMIOS_CCR[
n
] register. In this case, the FLAG bit is not set.
When SAOC mode is entered coming out of GPIO mode, the output flip-flop is set to the complement of
the EDPOL bit in the EMIOS_CCR[
n
] register.
The counter bus can be either internal or external and is selected through the BSL bits.
show how the unified channel can be used to perform a single output
compare with the EDPOL value being transferred to the output flip-flop and toggling the output flip-flop
at each match, respectively. Note that once in SAOC mode, the matches are enabled. Thus the desired
match value on register A1 must be written before the mode is entered. Register A1 can be updated at any
time, thus modifying the match value, which is reflected in the output signal generated by the channel.
Subsequent matches are enabled with no need of further writes to EMIOS_CADR[
n
]. The FLAG bit is set
at the same time a match occurs (see
).
NOTE
In SAOC mode, the internal channel counter is free-running, and starts
counting as soon as the SAOC mode is entered.
Selected Counter Bus
0x001000
0x001102
FLAG Set Event
A2 (Captured) Value
2
0xxxxxx
0x001000
Input Signal
1
Edge Detect
0x001103
0x001108
0x001104
0x001105
0x001106
0x001107
0x001001
FLAG Pin/Register
Edge Detect
FLAG Clear
Edge Detect
0x001103
0x001108
EDSEL = 1
EDPOL = x
Notes:
1
2
After input filter
EMIOS_CADR[n]
A2
Summary of Contents for PXR4030
Page 1: ...PXR40 Microcontroller Reference Manual Devices Supported PXR4030 PXR4040 PXR40RM Rev 1 06 2011...
Page 30: ...PXR40 Microcontroller Reference Manual Rev 1 Freescale Semiconductor xxx...
Page 40: ...PXR40 Microcontroller Reference Manual Rev 1 xl Freescale Semiconductor...
Page 66: ...Memory Map PXR40 Microcontroller Reference Manual Rev 1 2 4 Freescale Semiconductor...
Page 120: ...Signal Descriptions 3 54 Freescale Semiconductor PXR40 Microcontroller Reference Manual Rev 1...
Page 860: ...FlexCAN Module 24 50 Freescale Semiconductor PXR40 Microcontroller Reference Manual Rev 1...
Page 1167: ...Decimation Filter Freescale Semiconductor 28 53 PXR40 Microcontroller Reference Manual Rev 1...
Page 1168: ...Decimation Filter 28 54 Freescale Semiconductor PXR40 Microcontroller Reference Manual Rev 1...