openmv运行程序后自动断电如何解决?
-
# Untitled - By: Lenovo - 周二 9月 17 2019 import sensor, image, time, pyb sensor.reset() # Initialize the camera sensor. sensor.set_pixformat(sensor.GRAYSCALE) # or sensor.GRAYSCALE sensor.set_framesize(sensor.B128X128) # or sensor.QQVGA (or others) sensor.set_windowing((92,112)) sensor.skip_frames(10) # Let new settings take affect. sensor.skip_frames(time = 1000) while(True): img = sensor.snapshot() roi1=(10,0,80,60) roi2=(40,20,78,20) d1= img.find_lbp(roi1) d1= img.find_lbp(roi2)
用的M7模块,运行后直接断电
-
find_lbp程序是错的,导致重启。
-
-
@kidswong999 能不能解释一下为什么错了,如何解决错误
-
import sensor, image, time, pyb
sensor.reset() # Initialize the camera sensor.
sensor.set_pixformat(sensor.GRAYSCALE) # or sensor.GRAYSCALE
sensor.set_framesize(sensor.B128X128) # or sensor.QQVGA (or others)
sensor.set_windowing((92,112))
sensor.skip_frames(10) # Let new settings take affect.
sensor.skip_frames(time = 1000)
while(True):
img = sensor.snapshot()
roi1=(10,0,80,60)
d1= img.find_lbp(roi1)删去部分函数,只重复给d1赋值相同的lbp时,不会断电
-
看我链接里的例子,是正确的。