Figure 100. Example Of Jsqr Queue Of Context With Empty Queue (Case Jqm=0) - ST STM32G4 Series Reference Manual

Advanced arm-based 32-bit mcus
Hide thumbs Also See for STM32G4 Series:
Table of Contents

Advertisement

Analog-to-digital converters (ADC)
It is recommended to manage the queue overflows as described below:
After each P context write into JSQR register, flag JQOVF shows if the write has been
ignored or not (an interrupt can be generated).
Avoid Queue overflows by writing the third context (P3) only once the flag JEOS of the
previous context P2 has been set. This ensures that the previous context has been
consumed and that the queue is not full.
Queue of context: Behavior when the queue becomes empty
Figure 100
becomes empty in both cases JQM=0 or 1.

Figure 100. Example of JSQR queue of context with empty queue (case JQM=0)

P1
Write JSQR
EMPTY
JSQR queue
Trigger 1
ADC J context
(returned by
EMPTY
P1
reading JQSR)
ADC state
RDY
1. Parameters:
P1: sequence of 1 conversion, hardware trigger 1
P2: sequence of 1 conversion, hardware trigger 1
P3: sequence of 1 conversion, hardware trigger 1
Note:
When writing P3, the context changes immediately. However, because of internal
resynchronization, there is a latency and if a trigger occurs just after or before writing P3, it
can happen that the conversion is launched considering the context P2. To avoid this
situation, the user must ensure that there is no ADC trigger happening when writing a new
context that applies immediately.
598/3748
and
Figure 101
show the behavior of the context Queue when the Queue
P2
P1, P2
P1
Conversion1
The queue is not empty
and maintains P2 because JQM=0
P2
P2
RDY
Conversion1
RDY
RM0440 Rev 1
P3
P3
Conversion1
RDY
Conversion1
RM0440
Queue not empty
(P3 maintained)
P3
RDY
Conv
MS30540V3

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the STM32G4 Series and is the answer not in the manual?

Table of Contents

Save PDF