mirror of
https://github.com/apache/nuttx.git
synced 2026-05-28 20:08:15 +08:00
imxrt: add option to select PWM trigger source value from configuration
Current implementation supports the trigger generation only from timer capture on period value. This is sufficient for PWM synchronization but may not be enough for other purposes as ADC triggering for example. This change adds an option to generate the trigger based on a duty cycle value. Signed-off-by: Michal Lenc <michallenc@seznam.cz>
This commit is contained in:
@@ -181,7 +181,7 @@ Output on pin B is currently supported only as a complementary option to pin A.
|
||||
The lower-half of this driver is initialize by calling :c:func:`imxrt_pwminitialize`.
|
||||
|
||||
PWM module can be synchronized by an external signal. The external signal used for synchronization
|
||||
is selected by IMXRT_FLEXPWMx_MODx_SYNC_SRC config option. The number in IMXRT_FLEXPWM4_MOD4_SYNC_SRC
|
||||
is selected by IMXRT_FLEXPWMx_MODx_SYNC_SRC config option. The number in IMXRT_FLEXPWMx_MODx_SYNC_SRC
|
||||
corresponds with the XBAR number. Following numbers can be used for synchronization of PWMs with other
|
||||
PWM module when using iMXRT1020, iMXRT1050 or iMXRT1060.
|
||||
|
||||
@@ -221,6 +221,9 @@ iMXRT1170 has different XBAR connections:
|
||||
- PWM4 Module 3 = 88
|
||||
- PWM4 Module 4 = 89
|
||||
|
||||
Option IMXRT_FLEXPWMx_MODx_TRIG allows the module to generate a trigger signal. The trigger is generated on
|
||||
timer capture of either period or duty cycle value based on the configuration.
|
||||
|
||||
SAI
|
||||
---
|
||||
|
||||
|
||||
Reference in New Issue
Block a user