Time-Critical Tasks
ADwin
18
ADwin-Gold II
, Manual February 2013
which is mostly determined by the settling time of the multiplexer and the conversion
time.
SET_MUX1
()
…
'wait for settling of the
'multiplexer
START_CONV
()
WAIT_EOC
()
'wait for end of conversion
READADC
()
'or READADC12() at ADC12()
Using waiting times
You can use (or extend) the waiting times caused by the standard instructions for other
purposes. If you apply these instructions skillfully you may be able to execute faster
measurements.
It is important to set the
Start_Conv
instruction in a sufficient time-delay from the
Set_Mux1
instruction, in order to consider the multiplexer settling time.
Use the waiting times for instance for arithmetic operations and save CPU time:
–
The settling time of the multiplexer is 2µs (max.) at a maximum voltage jump of
20 Volt.
–
The conversion time of the ADC is 2µs.