Synchronized Transmit and Receive Masking Signals with Timer/Counter Type D

In order to effectively mask the PWM transmission from the receive line, correct synchronization of the transmit and receive masking signals is necessary. This is possible by using the "One Ramp" Waveform Generation mode of Timer/Counter Type D (for more information, refer to the device data sheet). As can be seen in the figure below, the compare values can be configured to generate two synchronized outputs able to be used as masks to control transmission and reception utilizing the transducer.

Figure 1. Generation of Synchronized Transmit and Receive Masking Signals using TCD One Ramp Mode
The different compare values have the following roles and should be customized according to the hardware being used: