ADC Triggered by PWM Does Not Work as Expected
R2026bIssue
When using the ADC (r_adc) or ADC_B (r_adc_b)
block with a PWM-triggered conversion source, ADC conversions may not start even though
the PWM signal is running.
This issue occurs when the PWM trigger output required by the ADC peripheral is not enabled in the PinOutput Support configuration. Without the required PWM extra feature configuration, the PWM module generates the output waveform, but the corresponding trigger request is not routed to the ADC peripheral. As a result, ADC conversions are not triggered by the PWM event.
Solution
Open the PinOutput Support configuration for the PWM channel used as the ADC trigger source.
Enable the required PWM Extra Features option that exposes the trigger request for the selected PWM peripheral.
In the ADC block, select the corresponding PWM trigger source in the Request Source parameter.
Rebuild and redeploy the model.
After deployment, verify that ADC conversions occur when the configured PWM trigger event is generated.
Verify the Configuration
Ensure that:
The PWM channel selected in PinOutput Support matches the PWM channel configured to generate the trigger.
The ADC Request Source parameter is configured to use the same PWM trigger source.
The PWM trigger functionality is enabled before running the application.