I.MX6ULL UART Transmission Issue

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

I.MX6ULL UART Transmission Issue

1,669 Views
nagaprasad
Contributor I

Hi all,

we are using i.mx6ull for our product.using uart for communication with external device.when we are trying to transmit more than 4Kb of data,we are unable to receive on other end.please suggest how can we achieve to transmit more than 4kb(8KB).i tried by modifying UART_XMIT_SIZE value but not working.

Thanks & Regards,

Naga Prasad.

Labels (5)
0 Kudos
14 Replies

1,467 Views
kef2
Senior Contributor IV

I think this isn't imx6ull related. Changing kernel N_TTY_BUF_SIZE define perhaps could help crossing 4k limit, but by default you should split your writes to less than 4k.

0 Kudos

1,417 Views
nagaprasad
Contributor I

hi @kef2@Dhruvit 

we tried increasing N_TTY_BUF_SIZE & UART_XMIT_SIZE, kernel crashing.

Thanks & Regards,

Naga Prasad.

0 Kudos

1,384 Views
Dhruvit
NXP TechSupport
NXP TechSupport

Hi @nagaprasad,

I hope you are doing well
 
Please try to configure the DMA buffer size from the device tree using the 'fsl,dma-info' property.
For more information, please refer to the file Documentation/devicetree/bindings/serial/fsl-imx-uart.yaml from the kernel source.
 
Thanks & Regards,
Dhruvit Vasavada

0 Kudos

1,395 Views
kef2
Senior Contributor IV

Then keep splitting your write calls to 4k. 

I saw on google someone succeeded changing that define in the past. Perhaps it was different kernel, no DMA or something else. I take this as a weird kernel feature, which I need to live with... 

0 Kudos

1,629 Views
Dhruvit
NXP TechSupport
NXP TechSupport

Hi @nagaprasad,

I hope you are doing well
 
My apology for the delayed response.
 
Please try to enable the DMA for the UART communication for better results. It will help you to prevent such types of issues.
 
Thanks & Regards,
Dhruvit Vasavada

0 Kudos

1,604 Views
nagaprasad
Contributor I

Hi @Dhruvit ,

Awaiting for your reply.

Thanks & Regards,

Naga Prasad.

0 Kudos

1,592 Views
Dhruvit
NXP TechSupport
NXP TechSupport

Hi @nagaprasad,

I hope you are doing well
 
Please share your board device tree(dts) file for further debugging.
 
Thanks & Regards,
Dhruvit Vasavada

0 Kudos

1,579 Views
nagaprasad
Contributor I
hi,
please help us to resolve this issue asap
0 Kudos

1,570 Views
Dhruvit
NXP TechSupport
NXP TechSupport

Hi @nagaprasad,

I hope you are doing well
 
The configuration seems correct as you get the 4 kb of data correctly.
Kindly share your code for transmitting and receiving the data from UART for further debugging the issue.
 
Thanks & Regards,
Dhruvit Vasavada

0 Kudos

1,504 Views
Dhruvit
NXP TechSupport
NXP TechSupport

Hi @nagaprasad,

I hope you are doing well.

waiting for your response.

Thanks & Regards,
Dhruvit Vasavada

0 Kudos

1,472 Views
nagaprasad
Contributor I

Hi @Dhruvit,

still we are facing same issue, 

for example: when we are trying to transmit 5120 bytes, it is able to transmit only 4095 bytes using serial port programming.

if your able to transmit more than 4095 bytes, please share the test application  or patch file required to do changes.our requirement is should be able to transmit 8200 bytes without splitting data into two halfs for transmission.

please help us to resolve asap. 

Thanks & Regards,

NagaPrasad.

0 Kudos

1,588 Views
nagaprasad
Contributor I

Hi @Dhruvit 

please find attached dts file for imx6ull.

0 Kudos

1,627 Views
nagaprasad
Contributor I

Hi Dhruvit,

Thanks for your reply.

i have tried with enabling dma for uart but still facing same issue,please suggest if anything need to be done for enabling dma

uart5: serial@21f4000 {
compatible = "fsl,imx6ul-uart",
"fsl,imx6q-uart";
reg = <0x021f4000 0x4000>;
interrupts = <GIC_SPI 30 IRQ_TYPE_LEVEL_HIGH>;
clocks = <&clks IMX6UL_CLK_UART5_IPG>,
<&clks IMX6UL_CLK_UART5_SERIAL>;
clock-names = "ipg", "per";
dmas = <&sdma 33 4 0>, <&sdma 34 4 0>;
dma-names = "rx", "tx";
status = "disabled";
}; 

0 Kudos

1,641 Views
nagaprasad
Contributor I

Hi,

Awaiting for any support on this issue.

0 Kudos