iMX28 application UART

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

iMX28 application UART

2,284件の閲覧回数
nick33
Contributor II

Hi

 

I am writing some C code to set up and use AUART_0.  through /dev/ttySP0. I am opening the port successfully and, when I write the port I am am actually getting data on the TX pin but then I get the following error: "mxs-auart mxs-auart.0: Unhandled status 52028d".

 

Any ideas are greatly appreciated!

ラベル(1)
0 件の賞賛
4 返答(返信)

693件の閲覧回数
nick33
Contributor II

Got it working! Avinash is right, these error codes appear to be associated with parity errors, framing errors, etc and I cannot find them documented anywhere either. My code is similar to Marcos except I'm not calling ioctl().

 

Also, I was not sending an LFCR after the string I was trying to send to my modem i.e. "ATZ\r\n" so now wonder I wasn't getting anything back!

0 件の賞賛

693件の閲覧回数
___myir
Contributor II

I also faced similar problem, the errors messages was printed when I use parity, it would no appears if I didn't  use parity.

0 件の賞賛

693件の閲覧回数
katte
Contributor II

Can you write your code for open the com port?
I use this:

/* open UART */
if ((I_uart_file = ::open(device, O_RDWR | O_NOCTTY | O_NDELAY)) == -1) {
/*
* Could not open the port.
*/
I_isOpen = P_Error;
return;
}
/* set BAUDRATE */
tcgetattr(I_uart_file, &termios_old);
termios_mxc = termios_old;
termios_mxc.c_lflag &= ~(ICANON | ECHO | ISIG);
cfsetospeed(&termios_mxc,B115200);
cfsetispeed(&termios_mxc,B115200);
retval = tcsetattr(I_uart_file, TCSANOW, &termios_mxc);
line_val = LOOPBACK;
ioctl(I_uart_file, TIOCMSET, &line_val);


and I don't have any problem.

0 件の賞賛

693件の閲覧回数
AvinashGodbole
Contributor I

I also faced similar problem. I was getting the error code as 52080. Searched a lot in various documents, but could not find.

Practically I foound that these error codes are for parity error, framing error etc.

0 件の賞賛