How to use S32K144 TRGMUX_IN0 trigger LPUART send data?

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

How to use S32K144 TRGMUX_IN0 trigger LPUART send data?

ソリューションへジャンプ
423件の閲覧回数
PYGC
Contributor II

I need a sample code.

 

void init_trgmux(void)
{
    // TRGMUX_IN0
    PCC->PCCn[PCC_PORTB_INDEX] = PCC_PCCn_CGC(1);
    PORTB->PCR[5]= PORT_PCR_MUX(6);

    // TRGMUX_LPUART1_INDEX
    TRGMUX->TRGMUXn[TRGMUX_LPUART1_INDEX] &= TRGMUX_TRGMUXn_SEL0_MASK;
    TRGMUX->TRGMUXn[TRGMUX_LPUART1_INDEX] |= TRGMUX_TRGMUXn_SEL0(TRGMUX_TRIG_SOURCE_TRGMUX_IN0);
}

 

 

0 件の賞賛
1 解決策
415件の閲覧回数
PetrS
NXP TechSupport
NXP TechSupport

Hi,

what do you want to achieve in fact? E.g. use TRGMUX_IN0 as hw control flow signal for LPUART transmit? Similarly as CTS_B input does?.
As chapter 53.4.8.2 states the LPUART supports one peripheral input trigger (from TRGMUX), that can be configured in one of the following ways.

PetrS_0-1682504905093.png

Configuration is done in PINCFG register.

BR, Petr

元の投稿で解決策を見る

0 件の賞賛
2 返答(返信)
416件の閲覧回数
PetrS
NXP TechSupport
NXP TechSupport

Hi,

what do you want to achieve in fact? E.g. use TRGMUX_IN0 as hw control flow signal for LPUART transmit? Similarly as CTS_B input does?.
As chapter 53.4.8.2 states the LPUART supports one peripheral input trigger (from TRGMUX), that can be configured in one of the following ways.

PetrS_0-1682504905093.png

Configuration is done in PINCFG register.

BR, Petr

0 件の賞賛
408件の閲覧回数
PYGC
Contributor II
Thank you so much!

I found the order of execution:

1. Configure TRGMUX
2. Configure LPUART (including PINCFG)
3. Write TX data
4. Wait for TRGMUX trigger signal
5. When the trigger signal is asserted, the TX data is automatically sent
0 件の賞賛