6.5 Passthrough Subroutine

The passthrough subroutine is shown in Figure 6-6. The flowchart on the left indicates the functionality in software while the one on the right indicates hardware functionality. The passthrough subroutine consists of the following steps:

  1. Once the program enters Passthrough mode, the ADC, DAC and sampling timer are turned on.
  2. With each tick of the sampling timer, an ADC conversion is performed and the data passes directly through to the DAC via DMA.
  3. The passthrough is stopped when the button is pressed again. To close the passthrough session, the sampling timer is stopped and the ADC and DAC are disabled.
Figure 6-6. Passthrough Subroutine