共 882 条结果匹配 "底层源码",(耗时 0.10 秒)
定时器2的时钟源到底是多少?
定时器2的时钟源到底是84Mhz,还是84hz啊。中文手册里是84hz。但是有个博主的代码,配置定时器1(时钟源168hz)
它的工作频率是0.2Mhz。
源代码查找
uart.writechar() 怎么找到这个函数源代码
编译源码不过,源码是主模块一个个下的
Use make V=1 or set BUILD_VERBOSE in your environment to increase build verbosity.
../../py/mkrules.mk:110: *** FROZEN_MPY_DIR cannot be used in conjunction with FROZEN_MANIFEST. Stop.
make: *** [FIRMWARE_OBJS] Error 2
GitHub源码如何学习
你好,想查看·openmv调用函数其对应的源码,在GitHub上下载下来不会看,请问有对应的教程吗?或者我是要先去学习github?
想要阅读openmv源码
想要阅读openmv源码,看下二维码扫描的相关代码,有没有指南,或者谁给点脉络?
眼睛识别源代码
有没有眼睛识别源代码
查找色块的源码
find_blobs函数具体怎样实现?
blob源码是先找到阈值进行二值化,然后利用基于扫描线的洪水填充法查找连通域?在这过程把x.y.w.h统计了?还是怎样实现的?
想看OpenMV程序源码
请问哪里可以看到OpenMV3里面功能函数的实现源码?比如人脸识别、色块识别这些的具体实现过程的程序,而不单单是封装好的功能函数?
为什么openmv里vl53l1x模块底层的设备地址为0x29,但是设备的数据手册里地址为0x52
为什么底层的地址和设备地址不一样?
源代码执行出问题
import sensor, image, time
from pid import PID
from pyb import Servo
pan_servo=Servo(1)
tilt_servo=Servo(2)
red_threshold = (13, 49, 18, 61, 6, 47)
pan_pid = PID(p=0.07, i=0, imax=90) #脱机运行或者禁用图像传输,使用这个PID
tilt_pid = PID(p=0.05, i=0, imax=90) #脱机运行或者禁用图像传输,使用这个PID
#pan_pid = PID(p=0.1, i=0, imax=90)#在线调试使用这个PID
#tilt_pid = PID(p=0.1, i=0, imax=90)#在线调试使用这个PID
sensor.reset() # Initialize the camera sensor.
sensor.set_pixformat(sensor.RGB565) # use RGB565.
sensor.set_framesize(sensor.QQVGA) # use QQVGA for speed.
sensor.skip_frames(10) # Let new settings take affect.
sensor.set_auto_whitebal(False) # turn this off.
clock = time.clock() # Tracks FPS.
def find_max(blobs):
max_size=0
for blob in blobs:
if blob[2]*blob[3] > max_size:
max_blob=blob
max_size = blob[2]*blob[3]
return max_blob
while(True):
clock.tick() # Track elapsed milliseconds between snapshots().
img = sensor.snapshot() # Take a picture and return the image.
blobs = img.find_blobs([red_threshold])
if blobs:
max_blob = find_max(blobs)
pan_error = max_blob.cx()-img.width()/2
tilt_error = max_blob.cy()-img.height()/2
print("pan_error: ", pan_error)
img.draw_rectangle(max_blob.rect()) # rect
img.draw_cross(max_blob.cx(), max_blob.cy()) # cx, cy
pan_output=pan_pid.get_pid(pan_error,1)/2
tilt_output=tilt_pid.get_pid(tilt_error,1)
print("pan_output",pan_output)
pan_servo.angle(pan_servo.angle()+pan_output)
tilt_servo.angle(tilt_servo.angle()-tilt_output)
这是怎磨回事