KL16 UART Interrupt with PE Setup

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

KL16 UART Interrupt with PE Setup

808 Views
mikewilliams
Contributor I

Hopefully this isn't a stupid question.

 

I'm trying to set up the UART to interrupt on each character.  I assume that the callback function is where I would pull that character out and put it in my own buffer.  My PE setup for the callback looks like this:

 

173855_173855.pngpastedImage_1.png

 

When I call UART_DRV_ReceiveData(), it requires a pointer to a buffer.  What is the difference between the buffer I set in PE and the one I have to pass to the UART_DRV_ReceiveData() call?  How do I set it up so that the UART interrupts on each character and calls the callback function so I can pull that character out into my own buffer?  Do I have to call UART_DRV_ReceiveData() for each character I want to receive?

 

Thanks.

Labels (1)
0 Kudos
1 Reply

426 Views
Robin_Shen
NXP TechSupport
NXP TechSupport

Hi MIKE,

Sorry for the late reply.

I recommend you use Kinetis SDK v2 instead of KSDK1.3.

You can test the UART interrupt example in SDK_2.0_MKL16Z256xxx4 folder.

UART examples in SDK_2.0_MKL16Z256xxx4.png

Search 'KL16' then select your MCU.(for example: MKL16Z256xxx4).

Select KL16.png

After specify additional configuration settings, you can download SDK_2.0_MKL16Z256xxx4.

Download SDK_2.0_MKL16Z256xxx4.png

 

You can getting start with KSDK and KDS from reading below:

 "How to start with KSDK"  and "KDS Document List".

 

Best Regards,

Robin

 

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

0 Kudos