• 免费好用的星瞳AI云服务上线!简单标注,云端训练,支持OpenMV H7和OpenMV H7 Plus。可以替代edge impulse。 https://forum.singtown.com/topic/9519
  • 我们只解决官方正版的OpenMV的问题(STM32),其他的分支有很多兼容问题,我们无法解决。
  • 如果有产品硬件故障问题,比如无法开机,论坛很难解决。可以直接找售后维修
  • 发帖子之前,请确认看过所有的视频教程,https://singtown.com/learn/ 和所有的上手教程http://book.openmv.cc/
  • 每一个新的提问,单独发一个新帖子
  • 帖子需要目的,你要做什么?
  • 如果涉及代码,需要报错提示全部代码文本,请注意不要贴代码图片
  • 必看:玩转星瞳论坛了解一下图片上传,代码格式等问题。
  • openMV不能正常脱机工作,如何解决?急!



    • 各位大咖,openMV未能正常脱机工作,不知是哪里出了错,想请教大家。大致情况是:
      1、如果我单单让openmv通过串口发消息到arduino板上,不进行图像识别的话,发消息在脱机状态下是可以实现的,它会一直发送;
      2、加上图像识别的代码后,不脱机连接电脑的情况下,是能识别以及发送消息的;
      3、但一旦脱机好像openmv就不工作了,也不知是不会去识别了还是识别了没发消息;
      4、程序我事先都已经是烧到openmv板以及SD卡里了。
      5、供电正常。
      ——————————接线图——————————————————————————
      1_1572944022118_微信图片_20191105164743.jpg 0_1572944022094_微信图片_20191105164736.jpg
      ——————————openMV IDE程序——————————————————————————

      import time, sensor, image, time, pyb
      from image import SEARCH_EX, SEARCH_DS
      from pyb import UART
      
      sensor.reset()
      
      sensor.set_contrast(1)
      sensor.set_gainceiling(16)
      
      sensor.set_framesize(sensor.QQVGA)
      
      sensor.set_pixformat(sensor.GRAYSCALE)
      
      
      template1 = image.Image("/J.pgm")
      template2 = image.Image("/Js.pgm")
      template3 = image.Image("/Jx.pgm")
      template4 = image.Image("/Jz.pgm")
      template5 = image.Image("/Jy.pgm")
      uart = UART(3, 9600)
      clock = time.clock()
      
      
      while (True):
          clock.tick()
          img = sensor.snapshot()
      
      
          r1 = img.find_template(template1, 0.70, step=4, search=SEARCH_EX)
          if r1:
              img.draw_rectangle(r1)
              uart.write("1\r")
              time.sleep(1000)
      
          r2 = img.find_template(template2, 0.70, step=4, search=SEARCH_EX)
          if r2:
              img.draw_rectangle(r2)
              uart.write("1\r")
              time.sleep(1000)
      
          r3 = img.find_template(template3, 0.70, step=4, search=SEARCH_EX)
          if r3:
              img.draw_rectangle(r3)
              uart.write("1\r")
              time.sleep(1000)
      
          r4 = img.find_template(template4, 0.70, step=4, search=SEARCH_EX)
          if r4:
              img.draw_rectangle(r4)
              uart.write("1\r")
              time.sleep(1000)
      
          r5 = img.find_template(template5, 0.70, step=4, search=SEARCH_EX)
          if r5:
              img.draw_rectangle(r5)
              uart.write("1\r")
              time.sleep(1000)
      
          print(clock.fps())
      
      

      ——————————arudino程序——————————————————————————

      #include <SoftwareSerial.h>
      
      SoftwareSerial softSerial(10, 11); // RX, TX
      
      void setup() {
        // put your setup code here, to run once:
        softSerial.begin(9600);
        Serial.begin(9600);
      }
      
      void loop() {
        int a1=1;
        while (a1=1){
         while (softSerial.available()>0)
        {
         char rec=(char)softSerial.read();
         Serial.print(rec);
         delay(5);
        }
        }
        }
       
      
      
      

      谢谢大家~





    • @kidswong999 格式化试过了,没有用。。。。



    • https://book.openmv.cc/example/02-Board-Control/led-control.html

      测试闪LED的程序,如果不行,就寄回维修。