Feel free to fork and use as you like it is MIT license
I have some nice ideas for making some little PCBs for these screens with some nice features that hopefully OpenMV designers will like and want to use and especially I hope the users of OpenMV cam will like them. Stay tuned
and got the wrong picture of double screens 160 wide and about 80 high
in upper part of the screen [ ][ ].
Correct picture occured only with 0,0,160,120 but only as part of the screen.
I can confirm that the library does not work with the latest firmware version. I had the same problem. I managed to make the screen to work correctly though using the fixed firmware : http://forums.openmv.io/download/file.php?id=536
I have an Openmv H7 and I wanted to use it with a ili9341 240x320 2.8" display without the need of the IDE. The camera works fine when connected to the OpenMV IDE. Nice display good frame rate etc… But when I hook it to the 2.8" display all I get is a small strip of the video. I can see the display is active by waving my hand in front of the camera so I know it’s getting the video feed. it’s just restricted to a small edge of the display. I make the changes in the scripts of “Screen =TFT(spi, TFT.ili9341)” and “screen.set_window(0,0,320,240)” I have read and searched the forums and have tried several different firmware’s suggested but to no avail. I’ve read in the forums where it has been a ongoing problem. Has the issue of the ili9341 interface been corrected for the H7? If so can someone send me in the right direction? Thanks.
OpenMV IDE Info:
Board H7, Sensor OV7725, Frimware: 3.6.0 Port COM3
FYI: Using latest OpenMV IDE and an H7 w/ latest firmware…
I have successfully integrated the Adafruit 2.2" ILI9340C TFT module into my project, using the following TFT driver (referenced in this thread - thanks OutOfTheBots!):
First, copy the file “OpenMV_TFT.py” to the USB flash storage of the H7. Then, run the (slightly modified) code below:
#TFT screen demo to steam frame buffer to a external SPI screen
import sensor, image, time
from machine import SPI
from OpenMV_TFT import TFT
sensor.reset()
sensor.set_pixformat(sensor.RGB565)
sensor.set_framesize(sensor.QVGA)
sensor.skip_frames(time = 2000)
clock = time.clock()
spi = SPI(2, baudrate=54000000) #create an SPI bus
#create an instance of the screen driver
#you mustr pass a SPI bus and type of screen (ili9341 or st7735
#optional can pass cs pin and dc pin default is cs='P3' and dc='P9'
screen = TFT(spi, TFT.ili9341)
#set window on screen to write to (x_start, Y_start, width, height)
#the window needs to be inside the resolution of the screen and must match the exact size of fb
screen.set_window(0,0,320,240)
while(True):
clock.tick()
img = sensor.snapshot()
# some image processing code goes here...
screen.write_to_screen(img) #send the fb to the screen
print(clock.fps())
Key points: Note DC==9 per the comments. Also BACKLIGHT (LED) & RESET are connected to 3.3v.