UART0 not working with KE06

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

UART0 not working with KE06

Jump to solution
1,548 Views
newke06user
Contributor I

Hi,

I am using Freescale Kinetics KE06 MCU for my project.

Most of the things on the MCU are up and working such as CAN, UART1 and UART2 but the UART0.

Configuration for UART0 is expected to be identical to UART1 and UART2 but i am really stuck with UART0.

UART1 and UART2 are working perfectly on 19200 bps with break field enabled (for LIN) with using default MCU pins.

The only difference for UART0 compared to other UARTs configuration is - PIN assignment from default (PTB0-PTB1) to PTA2 and PTA3.

For the UART0 pin reassignment from PTB0/PTB1 to PTA2/PTA3, other than UART configurations i had additionally did -

SIM->PINSEL |= SIM_PINSEL_UART0PS_MASK;

Even with above additional configuration UART0 doesn't work, either on FRDM evaluation board or my final/production hardware which uses only KE06 MCU (not K20/IRDA/Accel sensor etc as Eval board).

For more explanation on doesn't work - i am able to receive what i am sending using loopback mode but when i connect my actual device which is expected to receive/tx data over UART0, doesn't receive anything.

Could you please let me know if i am missing something.

Do i need to do additional setting for PIN reassignment.

Please let me know if i am clear with my question.

Thanks

Labels (1)
Tags (2)
0 Kudos
1 Solution
900 Views
mjbcswitzerland
Specialist V

Hi

pastedImage_0.png

Check that the UART0 Tx goes high - it will need a pull-up.

Otherwise, check that the I2C0 has not been enabled since it will have priority over the UART function.

Regards

Mark

Kinetis: µTasker Kinetis support

KE: µTasker FRDM-KE02Z support  / µTasker FRDM-KE02Z40M support  / µTasker FRDM-KE06Z support

KEA: µTasker TRK-KEA128 support

For the complete "out-of-the-box" Kinetis experience and faster time to market

View solution in original post

0 Kudos
3 Replies
900 Views
kerryzhou
NXP TechSupport
NXP TechSupport

Hi vikas shrivastava,

    Please add external pullup resistor in the ptA2 and PTA3 pin, these pins are true opendrain, and the internal pullup has no effect when configured as output high for UART.

Wish it helps you!


Have a great day,
Jingjing

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

0 Kudos
900 Views
davidsherman
Senior Contributor I

I am using UART0 on the PTB0/PTB1 pins, but I don't recall anything unusual in making it work.  The line you mention for changing pins looks strange, unless there's some structure someone defined that maps to the SIM_PINSEL0 register.  Using the mke06z4.h header that Freescale supplies, the line would be:

SIM_PINSEL0 |- SIM_PINSEL_UART0PS_MASK

You might check to see if the value at 0x4004800C actually has bit 7 set.

0 Kudos
901 Views
mjbcswitzerland
Specialist V

Hi

pastedImage_0.png

Check that the UART0 Tx goes high - it will need a pull-up.

Otherwise, check that the I2C0 has not been enabled since it will have priority over the UART function.

Regards

Mark

Kinetis: µTasker Kinetis support

KE: µTasker FRDM-KE02Z support  / µTasker FRDM-KE02Z40M support  / µTasker FRDM-KE06Z support

KEA: µTasker TRK-KEA128 support

For the complete "out-of-the-box" Kinetis experience and faster time to market

0 Kudos