June 15, 20233 yr I'm missing something essential. I have NanoPi Neo v1.4 with Armbian 23.5 Jammy CLI (Linux nanopineo 6.1.30-sunxi). My display is Nokia5110 LCD or PCD8544 With spi-spidev DT I can successfully via `spidev0.0` with `spi-tools`. I.e. I confirm that spi is working. Now, I studied about DTO and fbtft driver, found that it supports pcd8544. I wrote this kind of DTO and added it to `armbianEnv.txt` /* * Device: LCD5110 (nokia5110) 1.6"(84x48px) SPI display Module PCD8544 * Module Connector * SDI(MOSI) <- PC0 * SCK <- PC2 * CS <- PC3 * RESET <- PA1 * DC/RS <- PA3 * LED <- PA2 */ /dts-v1/; /plugin/; / { compatible = "allwinner,sun8i-h3"; fragment@0 { target = <&pio>; __overlay__ { display_pins: display_pins { pins = "PA1", "PA3"; /*RESET, DC_RS*/ function = "gpio_out"; }; }; }; fragment@1 { target = <&spi0>; __overlay__ { /* needed to avoid dtc warning */ #address-cells = <1>; #size-cells = <0>; status = "okay"; cs-gpios = <&pio 2 3 0>; /* ChipSelect PC3 */ pcd8544: pcd8544@0 { compatible = "philips,pcd8544"; reg = <0>; pinctrl-names = "default"; pinctrl-0 = <&display_pins>; spi-max-frequency = <4000000>; buswidth = <8>; fps = <5>; // led-gpios = <&pio 0 2 1>; /*LED=PA2*/ reset-gpios = <&pio 0 1 1>; /*RESET=PA1*/ dc-gpios = <&pio 0 3 0>; /*DC_RS=PA3*/ }; }; }; }; I'm seeing in serial output `Applying user provided DT overlay sun8i-h3-spi-pdc8544.dtbo` But... Thats all. `dmesg | grep spi` or `dmesg | grep fbtft` is empty. `lsmod | grep fb` - also nothing. `ls /dev/fb*` - nope. If I manually call for `sudo modprobe spi:fb_pcd8544` this prints into dmesg: Quote fbtft: module is from the staging directory, the quality is unknown, you have been warned. fb_pcd8544: module is from the staging directory, the quality is unknown, you have been warned. SPI driver fb_pcd8544 has no spi_device_id for philips,pcd8544 I've tried a lot of different tweaks in DTO, I've tried different releases from download page for my board. I don't know what am I missing. Is it somehow related to CLI nature of images? Why does no fb device apeears? Any help would be appreciated. Thank you. Edited June 16, 20233 yr by viteo
June 15, 20233 yr Hi there, does 'lsmod | grep pdc8544' even show that they module has even load? unfortunately the fbtft drivers are not that well supported hence being in the staging directory. I would advice that you look for a tiny drm based driver which is the way that small displays tend to be handled with the more recent kernel versions best of luck
June 16, 20233 yr Author oh. i've looked at your reply and something catched my eye. it's not `pdc8544` it's `pcd8544` I was copypasting this alias string from internet for three days.. checked modinfo and there: Quote alias: spi:pcd8544 alias: spi:fb_pcd8544 alias: philips,pcd8544 i'm sorry. i'm so dumb. Replaced with right string: compatible = "philips,pcd8544"; It's working now! p.s. i've edited original post for the case someone copy DT code. p.p.s. I'll take a loot at tinydrm, but googleing doen't give much for v6 kernel. if it's not a generic driver, there might not be pcd8544 tinydrm driver. Edited June 16, 20233 yr by viteo
July 5, 20233 yr Author Guys, I'm lookig for your help again. Trying to start this display with TinyDRM. The module I looking for is `panel-mipi-dbi`. I've built Armbian with this module enabled. Edited my dts as follows: /dts-v1/; /plugin/; / { compatible = "allwinner,sun8i-h3"; fragment@0 { target = <&pio>; __overlay__ { display_pins: display_pins { pins = "PA1", "PA3", "PA2"; /*RESET, DC_RS*/ function = "gpio_out", "gpio_out", "gpio_out"; }; }; }; fragment@1 { target = <&spi0>; __overlay__ { /* needed to avoid dtc warning */ #address-cells = <1>; #size-cells = <0>; status = "okay"; cs-gpios = <&pio 2 3 0>; /* ChipSelect PC3 */ num-chipselects = <1>; panel: panel@0 { compatible = "pcd8544", "panel-mipi-dbi-spi"; reg = <0>; spi-max-frequency = <4000000>; dc-gpios = <&pio 0 3 0>; /*DC_RS=PA3*/ reset-gpios = <&pio 0 1 1>; /*RESET=PA1*/ /*led-gpios = <&pio 0 2 0>; /*LED=PA2*/ write-only; width-mm = <35>; height-mm = <27>; panel-timing { hactive = <84>; vactive = <48>; hback-porch = <0>; vback-porch = <0>; clock-frequency = <0>; hfront-porch = <0>; hsync-len = <0>; vfront-porch = <0>; vsync-len = <0>; }; }; }; }; }; Tried both variants with `<&pio>` target and without. Double checked aliases Also added firmware `pcd8544.bin` to /lib/firmware command 0x21 # Function set command 0x04 # Temperature control (0) command 0x17 # Bias system (4) command 0x22 # Function set command 0x0C # Display control But no luck again. Module is not loaded, dmesg tells nothing =/ Also found this topic, but my display is still blank. Edited July 5, 20233 yr by viteo
October 26, 20232 yr Author Solution i've managed to create DRM driver for that display. https://lore.kernel.org/linux-devicetree/20230807121022.1871-2-viteosen@gmail.com/ that was impressive jouney pcd8544.c pcd8544-drm-spi.dts
December 7, 20241 yr Hello viteo Did you give up on the mipi-dbi-spi driver? I have a st7796s, and I tried "compatible="4in,panel-mipi-dbi-spi" ", as suggested in https://forums.raspberrypi.com/viewtopic.php?t=358240&hilit=Ili9341#p2165638 and I saw your example as the only example of mipi-dbi-spi in armbian, so I am trying to modify your DTS I tried "compatible=sitronix,st7796s" and it doesn't work
December 13, 20241 yr Author i'd made a new driver for PCD8544 display, because it is not compatible with mipi. A lot of time has passed since then, but i found my dts for st7789. hope it help you. st7789v-drm-spi.dts panel-mipi-dbi.dts Edited December 13, 20241 yr by viteo
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.