欧美极品高清xxxxhd,国产日产欧美最新,无码AV国产东京热AV无码,国产精品人与动性XXX,国产传媒亚洲综合一区二区,四库影院永久国产精品,毛片免费免费高清视频,福利所导航夜趣136

 找回密碼
 立即注冊

QQ登錄

只需一步,快速開始

搜索
查看: 2643|回復(fù): 1
打印 上一主題 下一主題
收起左側(cè)

多功能智能語音家居衣柜

[復(fù)制鏈接]
跳轉(zhuǎn)到指定樓層
樓主
ID:625887 發(fā)表于 2020-4-1 16:45 | 只看該作者 |只看大圖 回帖獎勵 |倒序瀏覽 |閱讀模式
之前參加ican比賽,做了一個智能語音衣柜的項目,獲得了國家二等獎,電控部分完全是一個人完成的,外型是用3D打印的,用到了飛思卡爾的plc芯片,還有openmv,還有語音模塊,視頻里人丑忽略,大家多多執(zhí)教,謝謝,最后附上程序。B站有視頻:https://www.bilibili.com/video/BV1qQ4y1M739



Python源程序如下:
  1. from pid import PID
  2. from pyb import Servo
  3. import sensor, image, time,pyb
  4. from pyb import UART
  5. pan_pid = PID(p=0.075, i=0, imax=90)
  6. tilt_pid = PID(p=0.05, i=0, imax=90)
  7. s1 = Servo(1)
  8. tilt_servo=Servo(2)
  9. s3 = Servo(3)
  10. sensor.reset()
  11. led1 = pyb.LED(1)
  12. led2 = pyb.LED(2)
  13. led3 = pyb.LED(3)
  14. sensor.set_contrast(3)
  15. sensor.set_gainceiling(16)
  16. sensor.set_framesize(sensor.QVGA)
  17. sensor.set_windowing((320, 240))
  18. sensor.set_pixformat(sensor.GRAYSCALE)
  19. sensor.skip_frames(time = 2000)
  20. sensor.set_auto_gain(False, value=100)
  21. led1.on()
  22. led2.on()
  23. led3.on()
  24. def draw_keypoints(img, kpts):
  25.         if kpts:
  26.                 print(kpts)
  27.                 img.draw_keypoints(kpts)
  28.                 img = sensor.snapshot()
  29.                 time.sleep(1000)
  30. kpts1 = None
  31. K=5000
  32. clock = time.clock()
  33. i = 0
  34. while (True):
  35.         s3.angle(-60)
  36.         b = 1500 + i
  37.         s1.pulse_width(b)
  38.         i = i+40       
  39.         if(i>1000):
  40.                 i = 0
  41.         clock.tick()
  42.         img = sensor.snapshot()
  43.         if (kpts1 == None):
  44.                 kpts1 = img.find_keypoints(max_keypoints=150, threshold=7, scale_factor=1.2)
  45.                 draw_keypoints(img, kpts1)
  46.         else:
  47.                 kpts2 = img.find_keypoints(max_keypoints=150, threshold=7, normalized=True)
  48.                 if (kpts2):
  49.                         img = sensor.snapshot()
  50.                         match = image.match_descriptor(kpts1, kpts2, threshold=85)
  51.                         if (match.count()>10):
  52.                          while(1):
  53.                                 kpts2 = img.find_keypoints(max_keypoints=150, threshold=7, normalized=True)
  54.                                 img = sensor.snapshot()
  55.                                 img.draw_rectangle(match.rect())
  56.                                 img.draw_cross(match.cx(), match.cy(), size=10)
  57.                                 s1.pulse_width(b)
  58.                                 time.sleep(2000)
  59.                                 s3.angle(-20)
  60.                                 time.sleep(2000)
  61.                                 s1.angle(-180)
  62.                                 time.sleep(2000)
  63.                                 s3.angle(-60)
  64.                                 time.sleep(200000)
復(fù)制代碼

以上資料51hei提供下載(注意資料不全  僅供參考):
比賽程序.zip (292.2 KB, 下載次數(shù): 9)


分享到:  QQ好友和群QQ好友和群 QQ空間QQ空間 騰訊微博騰訊微博 騰訊朋友騰訊朋友
收藏收藏 分享淘帖 頂 踩
回復(fù)

使用道具 舉報

沙發(fā)
ID:1 發(fā)表于 2020-4-1 21:36 | 只看該作者
本帖需要重新編輯補全電路原理圖,源碼,詳細(xì)說明與圖片即可獲得100+黑幣(帖子下方有編輯按鈕)
回復(fù)

使用道具 舉報

您需要登錄后才可以回帖 登錄 | 立即注冊

本版積分規(guī)則

小黑屋|51黑電子論壇 |51黑電子論壇6群 QQ 管理員QQ:125739409;技術(shù)交流QQ群281945664

Powered by 單片機教程網(wǎng)

快速回復(fù) 返回頂部 返回列表