Quantcast
Channel: Raspberry Pi Forums
Viewing all articles
Browse latest Browse all 7605

Interfacing (DSI, CSI, I2C, etc.) • Re: RPI5 how to disable DMA on ttyAMA0 ?

$
0
0
I'm using a C program that reads character by character. This program works very poorly with ttyAMA0 and very well with ttyAMA[1-4].
To run tests, I simply do this:

Initializing the serial channels:
/usr/bin/stty -F /dev/ttyAMA0 1200 sane evenp parenb cs7 –crtscts
/usr/bin/stty -F /dev/ttyAMA3 1200 sane evenp parenb cs7 –crtscts

Then:
root@PI5:~ # cat /dev/ttyAMA3 #Normal behavior: regular display at 1200 bps
OPTARIF BASE 0
ISOUSC 30 9
BASE 059379315 5
PTEC TH.. $
IINST 001 X
IMAX 012 B
PAPP 00300 $
MOTDETAT 000000 B
ADCO 020722012435 @
OPTARIF BASE 0

cat /dev/ttyAMA0
#Works very poorly, a few characters appear from time to time

I also ran a test with minicom:
With ttyAMA0 -> display in bursts of about ten lines
With ttyAMA3 -> regular display of characters at 1200 bps

I suspect DMA management after my various searches, but I still don't have a solution.
dts: rp1: Disable DMA usage for UART0 -> https://github.com/raspberrypi/linux/issues/6371
Pi 5 UARTs broken in 6.6.44 build of rpi-6.6.y -> https://github.com/raspberrypi/linux/issues/6365

Statistics: Posted by ernesto — Mon Mar 17, 2025 8:04 am



Viewing all articles
Browse latest Browse all 7605

Trending Articles