rm-hull / luma.lcd

Python module to drive PCD8544, HT1621, ST7735, ST7567 and UC1701X-based LCDs
https://luma-lcd.readthedocs.io
MIT License
156 stars 56 forks source link

ILI9341 issue? #166

Open bbence84 opened 1 year ago

bbence84 commented 1 year ago

Type of Raspberry Pi

Raspberry PI 4 4GB

Linux Kernel version

Linux 5.15.84-v8+ #1613 SMP PREEMPT Thu Jan 5 12:03:08 GMT 2023 aarch64 GNU/Linux

Expected behaviour

Basically the ILI9341 does not work at all. I am trying to figure out if it's a HW issue (thought it does the same with 2 different units, althought they are from the same order). I just get a black screen, nothing else. I have used the default wiring as described here: https://luma-lcd.readthedocs.io/en/latest/hardware.html#ili9341

I have this board: https://www.amazon.co.uk/240x320-Screen-Serial-Module-ILI9341/dp/B07MXH92RL/

I have tried the following:

  1. Init the board with explicit gpios specified:

    spi_serial = spi(port=0, device=0, gpio_light=18, gpio_rst=24,  gpio_dc=23, gpio_cs=8, bus_speed_hz=52000000)  
    self.device  = ili9341(spi_serial, width=320, height=240)   
  2. Init the board without explicit gpios

  3. Tried running one of the examples: python matrix.py --config ../conf/ili9341.conf

In all cases, I get a blank black screen, no backlight, nothing.

However I can turn on the baclight with a simple python script:

import RPi.GPIO as GPIO
GPIO.setmode(GPIO.BOARD)
GPIO.setup(12, GPIO.OUT)
GPIO.output(12, 0)

But strangely, when I run the example with the ili9341 config or my own script with the default wiring from the wiki, I don't get anything, not even backlight turning on....

Any ideas? :)

Actual behaviour

Black screen, nothing displayed. I tripled checked all my wiring. And again, at least I would assume the blaclight to be turning on, but not even that is happening. Running a short script using RPi.GPIO works fine however. (It turns on the backlight but the screen still does not show anything)