trgmux_clone_pwm#
Overview#
The TRGMUX project is a simple demonstration program of the SDK TRGMUX driver. It generates a 10KHz PWM by LPIT0 CH0, and clone by TRGMUX to output this PWM to eight TRGMUX_OUTx pins.
Supported Boards#
FRDM-KE15Z
Hardware requirements
Micro USB cable
FRDM-KE15Z board
Personal Computer
Board settings
The example requires connection between the trgmux pin and oscilloscope. Connect each of the trgmux output pin with the anode of oscilloscope: J21-8(FRDM-KE15Z board) -> Anode of oscilloscope. Or J21-7(FRDM-KE15Z board) -> Anode of oscilloscope. Or J4-2 (FRDM-KE15Z board) -> Anode of oscilloscope. Or J4-4 (FRDM-KE15Z board) -> Anode of oscilloscope. Or J4-11(FRDM-KE15Z board) -> Anode of oscilloscope. Or J2-17(FRDM-KE15Z board) -> Anode of oscilloscope. Or J2-15(FRDM-KE15Z board) -> Anode of oscilloscope. Or PTD0 (FRDM-KE15Z board) -> Anode of oscilloscope. GND (FRDM-KE15Z board) -> Cathode of oscilloscope.
Prepare the Demo
Connect a USB cable between the host PC and the OpenSDA USB port on the target board.
Open a serial terminal with the following settings:
115200 baud rate
8 data bits
No parity
One stop bit
No flow control
Download the program to the target board.
Either press the reset button on your board or launch the debugger in your IDE to begin running the demo.
Running the demo
When the example runs successfully, you can see the 10KHz PWM on each of the 8 pins.
FRDM-KE16Z
Hardware requirements
Micro USB cable
FRDM-KE16Z board
Personal Computer
Board settings
The example requires connection between the trgmux pin and oscilloscope. Connect each of the trgmux output pin with the anode of oscilloscope: J2-3(FRDM-KE16Z board) -> Anode of oscilloscope. Or J1-12(FRDM-KE16Z board) -> Anode of oscilloscope. Or J2-5 (FRDM-KE16Z board) -> Anode of oscilloscope. Or D4-3 (FRDM-KE16Z board) -> Anode of oscilloscope.
GND (FRDM-KE16Z board) -> Cathode of oscilloscope.
Prepare the Demo
Connect a USB cable between the host PC and the OpenSDA USB port on the target board.
Open a serial terminal with the following settings:
115200 baud rate
8 data bits
No parity
One stop bit
No flow control
Download the program to the target board.
Either press the reset button on your board or launch the debugger in your IDE to begin running the demo.
Running the demo
When the example runs successfully, you can see the 10KHz PWM on each of the 8 pins.
FRDM-KE17Z
Hardware requirements
Micro USB cable
FRDM-KE17Z board
Personal Computer
Board settings
The example requires connection between the trgmux pin and oscilloscope. Connect each of the trgmux output pin with the anode of oscilloscope: J1-5(FRDM-KE17Z board) -> Anode of oscilloscope. Or J1-7(FRDM-KE17Z board) -> Anode of oscilloscope. Or J1-2 (FRDM-KE17Z board) -> Anode of oscilloscope. Or J1-4 (FRDM-KE17Z board) -> Anode of oscilloscope. Or J4-1(FRDM-KE17Z board) -> Anode of oscilloscope. Or J2-2(FRDM-KE17Z board) -> Anode of oscilloscope. Or J4-7(FRDM-KE17Z board) -> Anode of oscilloscope. Or J4-5 (FRDM-KE17Z board) -> Anode of oscilloscope. GND (FRDM-KE17Z board) -> Cathode of oscilloscope.
Prepare the Demo
Connect a USB cable between the host PC and the OpenSDA USB port on the target board.
Open a serial terminal with the following settings:
115200 baud rate
8 data bits
No parity
One stop bit
No flow control
Download the program to the target board.
Either press the reset button on your board or launch the debugger in your IDE to begin running the demo.
Running the demo
When the example runs successfully, you can see the 10KHz PWM on each of the 8 pins.
FRDM-KE17Z512
Hardware requirements
Micro USB cable
FRDM-KE17Z512 board
Personal Computer
Board settings
The example requires connection between the trgmux pin and oscilloscope. Connect each of the trgmux output pin with the anode of oscilloscope: J1-5(FRDM-KE17Z512 board) -> Anode of oscilloscope. Or J2-2(FRDM-KE17Z512 board) -> Anode of oscilloscope. Or J4-3(FRDM-KE17Z512 board) -> Anode of oscilloscope. Or J5-1(FRDM-KE17Z512 board) -> Anode of oscilloscope. Or J4-1(FRDM-KE17Z512 board) -> Anode of oscilloscope. Or J2-11(FRDM-KE17Z512 board) -> Anode of oscilloscope. Or J4-7(FRDM-KE17Z512 board) -> Anode of oscilloscope. Or J4-5(FRDM-KE17Z512 board) -> Anode of oscilloscope. GND (FRDM-KE17Z512 board) -> Cathode of oscilloscope.
Prepare the Demo
Connect a USB cable between the host PC and the MCU-LINK USB port on the target board.
Open a serial terminal with the following settings:
115200 baud rate
8 data bits
No parity
One stop bit
No flow control
Download the program to the target board.
Either press the reset button on your board or launch the debugger in your IDE to begin running the demo.
Running the demo
When the example runs successfully, you can see the 10KHz PWM on each of the 8 pins.
FRDM-MCXE247
Hardware requirements
USB-C cable
FRDM-MCXE247 board
Personal Computer
Board settings
The example requires connection between the trgmux pin and oscilloscope. Connect each of the trgmux output pin with the anode of oscilloscope: J4-12 (TRGMUX_OUT0) -> Anode of oscilloscope. Or J1-7 (TRGMUX_OUT2) -> Anode of oscilloscope. Or J4-10 (TRGMUX_OUT3) -> Anode of oscilloscope. Or J7-1 (TRGMUX_OUT4) -> Anode of oscilloscope. Or J2-4 (TRGMUX_OUT6) -> Anode of oscilloscope. Or J7-5 (TRGMUX_OUT7) -> Anode of oscilloscope. GND (FRDM-MCXE247 board) -> Cathode of oscilloscope.
Prepare the Demo
Connect a USB cable between the host PC and the MCU-LINK USB port on the target board.
Open a serial terminal with the following settings:
115200 baud rate
8 data bits
No parity
One stop bit
No flow control
Download the program to the target board.
Either press the reset button on your board or launch the debugger in your IDE to begin running the demo.
Running the demo
When the example runs successfully, you can see the 10KHz PWM on each of the 6 pins (2 pins are not accessible on FRDM-MCXE247 pin headers).