FRDM-KL26Z low power uart

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

FRDM-KL26Z low power uart

1,482 Views
vipinkumar27
Contributor II

I have to use low power uart .Does it come under low power serial communication interface ?

I was going through hello world example .For this example,they have used UART0  which is under lpsci.

low power uart 's .c  and .h files are not visible to me under frdm-kl26z .

Is UART under lpsci ,a low power uart?

B'coz there are three uarts ,2 normal and one low power.

Labels (1)
0 Kudos
Reply
3 Replies

806 Views
vipinkumar27
Contributor II

lpsci driver example for uart0 is working fine .So,I used the lpsci driver example structure to write the uart driver example but I found 1 difference in uart_user_config_t and lpsci_user_config_t i.e

uart_user_config_t uartConfig = {

        .bitCountPerChar = kUart8BitsPerChar,

        .parityMode      = kUartParityDisabled,

        .stopBitCount    = kUartOneStopBit,

        .baudRate        = BOARD_DEBUG_UART_BAUD

    };

typedef struct LpsciUserConfig {

    clock_lpsci_src_t clockSource;      /*!< LPSCI clock source in fsl_sim_hal_'device'.h @internal gui name="Clock source" id="ClockSource" */

    uint32_t baudRate;                  /*!< LPSCI baud rate @internal gui name="Baud rate" id="BaudRate" */

    lpsci_parity_mode_t parityMode;     /*!< parity mode, disabled (default), even, odd @internal gui name="Parity mode" id="Parity" */

    lpsci_stop_bit_count_t stopBitCount; /*!< number of stop bits, 1 stop bit (default) or 2 stop bits @internal gui name="Stop bits" id="StopBits" */

    lpsci_bit_count_per_char_t bitCountPerChar; /*!< number of bits, 8-bit (default) or 9-bit in

                                                   a word (up to 10-bits in some LPSCI instances) @internal gui name="Bits per char" id="DataBits" */

} lpsci_user_config_t;

In both these structures,clocksource is defined for lpsci but not for uart.

I tried working with uart1 but nothing is getting displayed on terminal screen .

0 Kudos
Reply

806 Views
cutworth
NXP Employee
NXP Employee

Hi Vipin,

Yes, the LPSCI driver under KSDK is for low power UART. UART0 on KL26 is low power UART as it has asynchronous clock, while UART1 and UART2 are clocked by bus clock, so they do not work under low power modes.

Hao

0 Kudos
Reply

806 Views
Alice_Yang
NXP TechSupport
NXP TechSupport

Hello Vipin,

Yes, the UART0 can also work in the Low power mode , please see the Reference Manual :

pastedImage_0.png

And the uart1 and UART2 are not work in the low power mode :

pastedImage_1.png


Have a great day,
Alice Yang

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

0 Kudos
Reply