RT1062 LCD Shield No Attribute SPIDisplay

When I try to run the LCD Shield Example on the RT1062 with firmware V4.5.9, I get the error AttributeError: ‘module’ object has no attribute ‘SPIDisplay’

The default example works with v4.5.9 for me:

# This work is licensed under the MIT license.
# Copyright (c) 2013-2023 OpenMV LLC. All rights reserved.
# https://github.com/openmv/openmv/blob/master/LICENSE
#
# LCD Example
#
# Note: To run this example you will need a LCD Shield for your OpenMV Cam.
#
# The LCD Shield allows you to view your OpenMV Cam's frame buffer on the go.

import sensor
import display

sensor.reset()  # Initialize the camera sensor.
sensor.set_pixformat(sensor.RGB565)  # or sensor.GRAYSCALE
sensor.set_framesize(sensor.QQVGA2)  # Special 128x160 framesize for LCD Shield.
# Initialize the lcd screen.
# Note: A DAC or a PWM backlight controller can be used to control the
# backlight intensity if supported:
#  lcd = display.SPIDisplay(backlight=display.DACBacklight(channel=2))
#  lcd.backlight(25) # 25% intensity
# Otherwise the default GPIO (on/off) controller is used.
lcd = display.SPIDisplay()

while True:
    lcd.write(sensor.snapshot())  # Take a picture and display the image.

Copied your code into a new file and get this error

Traceback (most recent call last):
File “”, line 23, in
AttributeError: ‘module’ object has no attribute ‘SPIDisplay’
OpenMV v4.5.9; MicroPython v1.23.0-r19; OpenMV IMXRT1060-MIMXRT1062DVJ6A

Board: OpenMV Cam RT1062 Legacy
Sensor: OV5640
Firmware Version: 4.5.9 [latest]

Not sure what’s going on. I have an RT1062 with 4.5.9 too and the script works…

Can you click the Firmware Version label in the IDE and reset it to the release?

Clicked on Firmware Version label and reset to release version. Firmware was reloaded. Firmware VErsion4.5.9 - [latest]. Still getting no attribute ‘SPIDisplay’

firmware.zip (1.7 MB)

I just flashed this version and it works on my RT1062? v4.5.9

Flashed that firmware to my RT1062 and still same error with example lcd_1.py. Very strange.

Not sure what to do here… I’ve flashed it to my camera a few times and it works as expected.

Tools → Installing the latest dev release works fine too.

Erased SD card, rebooted computer, reinstalled latest release firmware, tapped my head and rubbed my stomach … and now it works :slight_smile: