cancel
Showing results for 
Search instead for 
Did you mean: 

PSoC 5, 3 & 1 MCU

New Contributor II

Hi,

Hello when we receive one char on rx pin we use api  ch = UART_1_GetChar();

Using any sensor data (IMU) It receive strings kind of thing Ex: #YPR=-2.87,2.39,96.22

so how to save this string using API ? Which API should be used?

0 Likes
Reply
1 Solution
Honored Contributor II

rathangshah,

use example below to receive the string

UART string reception garbage value

/odissey1

View solution in original post

0 Likes
Reply
2 Replies
Esteemed Contributor II

There is no API for reading strings from UART.

I would suggest you to define an End-Of-String character which will indicate where to stop processing for the current string. Usual values are \n or \r.

Bob

0 Likes
Reply
Honored Contributor II

rathangshah,

use example below to receive the string

UART string reception garbage value

/odissey1

View solution in original post

0 Likes
Reply