ESP32-CAM with ILI9341

All ESP32 boards running MicroPython.
Target audience: MicroPython users with an ESP32 board.
Post Reply
TRMrNo
Posts: 15
Joined: Fri May 28, 2021 9:24 pm

ESP32-CAM with ILI9341

Post by TRMrNo » Sat Jul 02, 2022 10:13 am

Hello,

I am trying to display live video on ILI9341 SPI display. JPEG function of the camera is working properly. However I could not get any image when I configure the camera in RGB565 format.

Does anyone make such an implemantation ?

Or do you know a library which can display jpeg image on LCD display, In case I use the camera in JPEG mode ?

Or do you know a library which can convert jpeg to raw RGB565 format ?

Code: Select all

camera.init(0, format=camera.RGB565, fb_location=camera.PSRAM)
buf = camera.capture()
>> buf
>> False

Code: Select all

spi = SPI(baudrate=40000000, polarity=0, phase=0, sck=Pin(14), mosi=Pin(13), miso=Pin(12))
display = Display(spi, dc=Pin(2), cs=Pin(15), rst=Pin(0))

state = camera.init(0, format=camera.RGB565, fb_location=camera.PSRAM)
#state = camera.init(0, format=camera.JPEG, fb_location=camera.PSRAM)
print("Camera State: ",state)
camera.framesize(camera.FRAME_96X96)

while True:
    buf = bytearray(2 * 96 * 96)
    buf = camera.capture()
    display.block(0,0,96,96,buf)
    print("image")
    display.draw_rectangle(0,0,96,96,255)
Best Regards

tepalia02
Posts: 99
Joined: Mon Mar 21, 2022 5:13 am

Re: ESP32-CAM with ILI9341

Post by tepalia02 » Sat Jul 16, 2022 10:45 am

Since you're getting no response here, I think you can address your problem in this thread: viewtopic.php?f=14&t=1996&start=10

Post Reply