I have 2 of them from older rpi projects. As i got oled workin very easy and this a better resolution than the oled i would give it a try. I only want to print system info,so there is no need for full xserver. Driving them from userspace like the oled gives possibility to draw all information
Here is a way using spidev which maybe does not require gpio pin conversion,but uses again the adafruit libs
Btw.the display seems to be supported in staging with fb_tft,but how to draw to fb without xserver?
There is an in-kernel driver for this display which exposes a framebuffer device – hence you can then open /dev/fb0 from userspace and draw around in it. No need for any hardware-specific knowledge in user-space, nor need for any vendor-specific libraries, …
config TINYDRM_ILI9486
tristate "DRM support for ILI9486 display panels"
depends on DRM && SPI
select DRM_KMS_HELPER
select DRM_GEM_DMA_HELPER
select DRM_MIPI_DBI
select BACKLIGHT_CLASS_DEVICE
help
DRM driver for the following Ilitek ILI9486 panels:
* PISCREEN 3.5" 320x480 TFT (Ozzmaker 3.5")
* RPILCD 3.5" 320x480 TFT (Waveshare 3.5")
If M is selected the module will be called ili9486.
Yes, using DT-overlay would be the natural choice here. You don’t need to use phandle for that, just use DT overlay /plugin/ syntax and use target-path pointing to the SPI bus.
That should not be a problem, the overlay should compile as-is and just add a record for the phandle which is then matched during runtime when U-Boot applies the overlay.
any idea how to debug this? have only connected 1x 5v, 1x 3v3 and 1xGND + spi-pins including CS0 (no CS1), reset and the dc-pin (defined like above)…wonder if i need to set the CS in dts? and i’m not sure polarity is right…only found the wiki i linked above
did you made a connection via ethernet? I’m trying to use an oled spi display by myself. So far I connected only a logic analyzer on the GPIO header. I noticed that as soon as I send some data via spidev, all LEDs on the ethernet ports are flashing for a second, hence I assume that some kind of reset is applied to the switch IC.
Can you confirm that observation?
The data is send correctly via SPI.
I also tried to use the SPI pins as simple GPIO and toggle them manually. But I was not able to reproduce that behavior.
Mhm,had spidev recognized in my kernel,but did not know how to access my display over this because i did not get the luma-lcd module installed (missing gpio library for r3). I tried using display driver from kernel,but did not get it working yet
I think I’m also seeing this, once I start communicating on the SPI port ( spi1.0 ) ( or the kernel initializes the device on there as set in my DTS ) Teh Ethernet LEDs flash and i stop getting Ethernet comms
I’ve been testing SPI communication ( with multiple CS pins on the SPIC port ):
root@openwrt:~# ping 8.8.8.8
PING 8.8.8.8 (8.8.8.8): 56 data bytes
64 bytes from 8.8.8.8: seq=0 ttl=117 time=12.039 ms
64 bytes from 8.8.8.8: seq=1 ttl=117 time=13.262 ms
64 bytes from 8.8.8.8: seq=2 ttl=117 time=16.911 ms
^C
--- 8.8.8.8 ping statistics ---
3 packets transmitted, 3 packets received, 0% packet loss
round-trip min/avg/max = 12.039/14.070/16.911 ms
root@openwrt:~# echo "test" > /dev/spidev1.0
root@openwrt:~# ping 8.8.8.8
PING 8.8.8.8 (8.8.8.8): 56 data bytes
^C
--- 8.8.8.8 ping statistics ---
4 packets transmitted, 0 packets received, 100% packet loss
it does the same when I use “spidev1.1” ie. my other GPIO chipselect, so its probably not the CS pins ( something todo with the switch JTAG connections or are the SPIC pins shared with the MT7531 causing it to reset? )