openmv/usr/examples/Example1-LCD-Shield-Demo.py
Kwabena W. Agyeman 94910c8ed7 Move LCD code into module. It's now ultra fast, safe and friendly. I
tested everything too and added an example script (very simple).
2016-03-17 20:01:03 -04:00

16 lines
530 B
Python

# Example 1 - LCD Shield Demo
#
# 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, image, lcd
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.
lcd.init() # Initialize the lcd screen.
while(True):
lcd.display(sensor.snapshot()) # Take a picture and display the image.