juj / fbcp-ili9341

A blazing fast display driver for SPI-based LCD displays for Raspberry Pi A, B, 2, 3, 4 and Zero

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Error with lxde on ili9341

mixerreq opened this issue · comments

commented

i have issue with lxde while i logging in display driver just crashing...

this is my log of driver

bcm_host_get_peripheral_address: 0x3f000000, bcm_host_get_peripheral_size: 16777216, bcm_host_get_sdram_address: 0xc0000000
BCM core speed: current: 250000000hz, max turbo: 400000000hz. SPI CDIV: 6, SPI max frequency: 66666667hz
Allocated DMA channel 7
Allocated DMA channel 1
Enabling DMA channels Tx:7 and Rx:1
DMA hardware register file is at ptr: 0x75b4f000, using DMA TX channel: 7 and DMA RX channel: 1
DMA hardware TX channel register file is at ptr: 0x75b4f700, DMA RX channel register file is at ptr: 0x75b4f100
Resetting DMA channels for use
DMA all set up
Initializing display
Resetting display at reset GPIO pin 24
Setting TFT backlight on at pin 23
Creating SPI task thread
InitSPI done
DISPLAY_FLIP_ORIENTATION_IN_SOFTWARE: Swapping width/height to update display in portrait mode to minimize tearing.
Relevant source display area size with overscan cropped away: 240x320.
Source GPU display is 240x320. Output SPI display is 240x320 with a drawable area of 240x320. Applying scaling factor horiz=1.00x & vert=1.00x, xOffset: 0, yOffset: 0, scaledWidth: 240, scaledHeight: 320
Creating dispmanX resource of size 240x320 (aspect ratio=0.750000).
GPU grab rectangle is offset x=0,y=0, size w=240xh=320, aspect ratio=0.750000
All initialized, now running main loop...
DMA channel 0 has peripheral map 0 (is lite channel: 0, currently active: 0, current control block: (nil))
DMA channel 1 has peripheral map 5 (is lite channel: 0, currently active: 1, current control block: 0xbeba6020)
DMA channel 2 has peripheral map 11 (is lite channel: 0, currently active: 1, current control block: (nil))
DMA channel 3 has peripheral map 17 (is lite channel: 0, currently active: 1, current control block: 0xff4e12a0)
DMA channel 4 has peripheral map 13 (is lite channel: 0, currently active: 1, current control block: 0xf7401680)
DMA channel 5 has peripheral map 0 (is lite channel: 0, currently active: 0, current control block: (nil))
DMA channel 6 has peripheral map 13 (is lite channel: 0, currently active: 1, current control block: (nil))
DMA channel 7 has peripheral map 6 (is lite channel: 1, currently active: 1, current control block: 0xbeba6000)
DMA channel 8 has peripheral map 0 (is lite channel: 1, currently active: 0, current control block: (nil))
DMA channel 9 has peripheral map 0 (is lite channel: 1, currently active: 0, current control block: (nil))
DMA channel 10 has peripheral map 0 (is lite channel: 1, currently active: 0, current control block: (nil))
DMA channel 11 has peripheral map 0 (is lite channel: 1, currently active: 0, current control block: (nil))
DMA channel 12 has peripheral map 0 (is lite channel: 1, currently active: 0, current control block: (nil))
DMA channel 13 has peripheral map 0 (is lite channel: 1, currently active: 0, current control block: (nil))
DMA channel 14 has peripheral map 0 (is lite channel: 1, currently active: 0, current control block: (nil))
DMA channel collision! DMA channel 1 was expected to be assigned to our peripheral 7, but something else has assigned it to peripheral 5!
System is likely unstable now, rebooting is advised.

OS: Raspberry pi OS (Legacy) 32 bit
Hardware: Raspberry Pi 3B+ 1.4 Ghz
Screen driver: ili9341
345198158_956560008865022_8215200098509283097_n

commented

The error suggests there is some other software driver that is using the DMA RX channel 1.

Try using another DMA RX channel for fbcp-ili9341. See https://github.com/juj/fbcp-ili9341#specifying-other-build-options :

-DDMA_RX_CHANNEL=<num>: Specifies the DMA channel number to use for SPI receive commands.
Change this if you find a DMA channel conflict.

Potentially good looking alternatives would be

DMA channel 0 has peripheral map 0 (is lite channel: 0, currently active: 0, current control block: (nil))
DMA channel 5 has peripheral map 0 (is lite channel: 0, currently active: 0, current control block: (nil))

so either -DDMA_RX_CHANNEL=0 or -DDMA_RX_CHANNEL=5 might work.

If neither of those work out and there is still a conflict, then there is a document at https://www.raspberrypi.org/app/uploads/2012/02/BCM2835-ARM-Peripherals.pdf that lists what those peripheral numbers mean:

image
image

These might give an idea of what is utilizing the same DMA channel.

In this case it looks like something that is driving PWM peripheral decided to use this DMA channel, hence the crash.

commented

The error suggests there is some other software driver that is using the DMA RX channel 1.

Try using another DMA RX channel for fbcp-ili9341. See https://github.com/juj/fbcp-ili9341#specifying-other-build-options :

-DDMA_RX_CHANNEL=<num>: Specifies the DMA channel number to use for SPI receive commands.
Change this if you find a DMA channel conflict.

Potentially good looking alternatives would be

DMA channel 0 has peripheral map 0 (is lite channel: 0, currently active: 0, current control block: (nil))
DMA channel 5 has peripheral map 0 (is lite channel: 0, currently active: 0, current control block: (nil))

so either -DDMA_RX_CHANNEL=0 or -DDMA_RX_CHANNEL=5 might work.

If neither of those work out and there is still a conflict, then there is a document at https://www.raspberrypi.org/app/uploads/2012/02/BCM2835-ARM-Peripherals.pdf that lists what those peripheral numbers mean:

image image

These might give an idea of what is utilizing the same DMA channel.

In this case it looks like something that is driving PWM peripheral decided to use this DMA channel, hence the crash.

Thanks for fast reply. After compiling driver with added agruments now lxde loading. Thanks for your answer
IMG_20230512_062220