Hi, @SuperBeginner,
1. MCU Clock Reference
To create a new clock reference or modify the already existing ones, you should access the following path in the configuration tool:
Mcu tab -> McuModuleConfiguration tab -> McuClockSettingConfig tab -> McuClockReferencePoint tab
Here you will find all the references of the clocks:
dragostoma_0-1725516691886.png
As mentioned in the Reference Manual, S32K312 has only LPUART_0 that uses AIPS_PLAT_CLK, the rest of the instances use AIPS_SLOW_CLK.
dragostoma_0-1725516848303.png
So to make sure that the other instances can still be used successfully, you can create a new reference for the UART, clocked by AIPS_PLAT_CLK.
dragostoma_1-1725517017728.png
After that, you should make sure that the UART channel you want to use, which has the LPUART_0 instance set, uses the correct clock reference, the one we just created:
dragostoma_2-1725517095566.png
2. MCU Clock Enablement
To enable the clock of the peripheral you want to use, you should access the following path in the configuration tool:
Mcu tab -> McuModuleConfiguration tab -> McuModeSettingConf tab -> McuPeripheral tab
Here you will find the list with all the available peripheral clocks.
dragostoma_3-1725517403942.png
To be able to use the new instance of LPUART, the related peripheral clock must be enabled.
dragostoma_4-1725517453669.png
3. Interrupts Configuration
To be able to use the interrupt handlers, they must be enabled in the Platform tab, which can be found at the following path:
Platform tab -> Interrupt Controller tab
Here you will find the list with all the available interrupt handlers.
dragostoma_5-1725518066149.png
In order to be able to use the interrupt handler related to the LPUART_0 instance, it must be enabled, a priority must be set and it must be named based on the definition and implementation in the drivers MBDT generates code on top of. In this case will be LPUART_UART_IP_0_IRQHandler.
dragostoma_6-1725518167978.png
I hope this information clarifies the configuration and use of a new instance of LPUART.
Best regards,
Dragos