Value error sensor control failed 是怎么回事?
-
import pyb import sensor, image, time,utime import car from pid import PID from pyb import UART from code_123 import code_123 from code_132 import code_132 from code_213 import code_213 from code_231 import code_231 from code_321 import code_321 from code_312 import code_312 from Read import uart_read from red import find_red from blue import find_blue from green import find_green from Test import wave_distance_process sensor.reset() sensor.set_vflip(True) sensor.set_hmirror(True) sensor.set_pixformat(sensor.RGB565) sensor.set_framesize(sensor.QQVGA) sensor.skip_frames(10) sensor.set_auto_whitebal(False) clock = time.clock() uart = UART(3, 115200) m = [0,0,0] while(True): car.run(50,50) img = sensor.snapshot() img.lens_corr(1) for code in img.find_qrcodes(): uart.write(code.payload()+'\0') m=list(code.payload()) if(m!=[0,0,0]): print(m) if m[0]=='1' and m[1]=='2' and m[2]=='3': find_red() wave_distance_process() while(wave_distance_process()>=6.0 and wave_distance_process()<=9.0): find_red() find_green() while(wave_distance_process()>=6.0 and wave_distance_process()<=9.0): find_green() find_blue() while(wave_distance_process()>=6.0 and wave_distance_process()<=9.0): find_blue()
-
你的程序我没有办法运行,不是全部的源码