Hello everyone,
Summary first: I'm looking for help in routing an external signal to any of the eFlexPWM fault inputs FAULTn.
I am running a motor off the eFlexPWM.
The FAULTn inputs to this module seem like a great way to disable the PWM output if a fault is detected. They even have a combinatorial path such that when our external overcurrent signal is asserted it will work even if some disastrous clocking issue has occurred - great!
It appears, however, that the only source of the FAULTn(0-3) inputs are XBAR_OUTn(13-16) - which makes sense I guess, nice to have flexibility!
Looking at Figure 49-1 it would appear that all I need to do is use the XBAR to connect a suitable "IO PAD" to, say XBAR_OUT13 and configure the eFlexPWM to respond to the FAULT0 signal.
However, in Table 4-4 I can find no reference to any "IO PAD"s as depicted in Figure 49-1.
So I figured maybe this is just an oversight, no pads to the XBAR, and I need to go via the AOI which seems like a perfect candidate for something like this where signals might need some combinatorial logic before reaching their destination - fantastic!
Figure 49-1 does not show pads connected to the AOI, but since it seems to erroneously show them connected to the XBAR it was not so much a stretch to consider that perhaps they are routed to the AOI instead.
But data on where inputs to the AOI module come from seem to have been left out of the reference manual entirely...?
I am absolutely sure I am missing something here and any help would be much appreciated!
Thank you!
In my last post I showed that it is possible and how to do it; that code sets up a direct combinatorial route from GPIO_AD_07 to FLEXPWM1_FAULT0, through the XBAR.
I would still like to know the following:
Is XBAR1_IN00 always LOGIC LOW, as logical assumption and practical testing indicate?
Note: XBAR1_IN01 is always LOGIC HIGH according to the manual but XBAR1_IN00 is "Reserved".
Are you sure about that?
I'm asking because it seems like if I setup the following configuration...
IOMUXC_SW_MUX_CTL_PAD_GPIO_AD_07:MUX_MODE = 7 (XBAR1_INOUT03)
IOMUXC_GPR_GPR6:IOMUXC_XBAR_DIR_SEL_3 = 0 (XBAR_INOUT3 is input XBAR1_IN03)
XBARA_SEL6:SEL13 (FLEXPWM1_FAULT0) = 3 (XBAR1_IN03)
... it seems to work as expected, with a direct connection between a GPIO and FAULT0 of FLEXPWM1 without requiring any interrupts.
Am doing something wrong or something that is not recommended here?
On that note, I would also love to get clarification on Reserved input XBAR1_IN00.
It would seem during my testing that this is LOGIC LOW, just like XBAR1_IN01 is LOGIC HIGH.
Makes sense since all XBAR_SEL are set to this input on reset, and I do not think a floating input would be chosen.
Is this analysis correct?
Hi,
Thank you so much for your interest in our products and for using our community.
The fault inputs of the eFlexPWM come from external modules to force the PWM outputs to a desired state in case of a fault condition. It cannot be routed to an external signal.
However, what you can do is generate an interrupt with it and in this last routine configure an external signal. For more detail about it you can refer to 45.7 Interrupts section of reference manual.
Hope it helps you.
Have a nice day!