- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
I would like to connect 4 PWM counter overflow triggers to a single DMA channel. PDL documentation and TRM don't describe intermediate signals deeply. I am able to create 1:1 connection but not 4:1.
status = Cy_TrigMux_Connect(TRIG11_IN_TCPWM1_TR_OVERFLOW13, TRIG11_OUT_TR_GROUP0_INPUT11,
CY_TR_MUX_TR_INV_DISABLE, TRIGGER_TYPE_TCPWM_TR_OVERFLOW);
Cy_TrigMux_Connect(TRIG0_IN_TR_GROUP11_OUTPUT2, TRIG0_OUT_CPUSS_DW0_TR_IN0,
CY_TR_MUX_TR_INV_DISABLE, TRIGGER_TYPE_TR_GROUP_OUTPUT__EDE);
The use case is:
- Interconnect 4 PWM triggers with one DMA channel
- Fill array Periods with different periods {10,20,30...100}
- For pwm in PWM run
- setup DMA channel to update pwm period on each overflow from Periods
- enable DMA channel
- start PWM
- if all periods were written stop pwm
- Goto 3
How should multiplexer triggers be set up to achieve such behavior?
Regards
Ondrej Pilat
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello Ondrej,
The input and output of the distribution multiplexers can only be connected in 1:1 fashion. So its directly not possible to route 4 trigger output signals to a single line. If you have a PSoC 6 device that has a UDB block then by using a 4 input OR-gate this can be achieved.
Steps:
1) Connect 4 overflow outputs to 4 inputs of the OR-gate.
2) Connect the output of the OR-gate to trigger input of DW channel.
PSoC Creator will automatically take care of calling APIs to make proper DSI and Trigger mux connections to achieve this.
Regards,
Yeshwanth
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello Ondrej,
The input and output of the distribution multiplexers can only be connected in 1:1 fashion. So its directly not possible to route 4 trigger output signals to a single line. If you have a PSoC 6 device that has a UDB block then by using a 4 input OR-gate this can be achieved.
Steps:
1) Connect 4 overflow outputs to 4 inputs of the OR-gate.
2) Connect the output of the OR-gate to trigger input of DW channel.
PSoC Creator will automatically take care of calling APIs to make proper DSI and Trigger mux connections to achieve this.
Regards,
Yeshwanth
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
PSoC63 isn't able to make 4:1 connection between reduction and distribution multiplexers without UDB blocks, is it?
PSoC63 TRM:
Activation of a specific input trigger, will result in activation of all output triggers that have the
specific input trigger selected through their TR_OUT_CTL.TR_SEL field.
TRM says that it is possible to activate multiple output triggers for one input.
Do we need UDB to interconnect
TRIG11_IN_TCPWM1_TR_OVERFLOW14
TRIG11_IN_TCPWM1_TR_OVERFLOW13 with TRIG0_OUT_CPUSS_DW0_TR_IN0 ?
TRIG11_IN_TCPWM1_TR_OVERFLOW12
TRIG11_IN_TCPWM1_TR_OVERFLOW11
Regards,
Ondrej
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The mux marked in red is a distribution multiplexer. It is a 50:16 mux, Each output line can only be connected to one of those 50 inputs. For example Tr_in[0] can only be connected to one of the 50 inputs. It is not possible to route more than one trigger input to a output line. The other way is true where you can make 1:m connections. That is a single trigger input can be routed to all the 16 lines of Tr_in[0:15].
Yes, UDB is required to logically OR the incoming trigger lines and route it to one DW channel.
Regards,
Yeshwanth