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



    • 我已经在Openmv IDE 中调试出我所需要的脚本,用来识别LED 灯的颜色和闪烁频率并打印出这些信息.现在我想在Linux环境中,用别的自动化程序来调用这个openmv的脚本所能实现的功能,抓取脚本的打印信息,以实现其他自动化测试和这个摄像头自动识别的功能整合.
      现在遇到的问题是,Linux (ubuntu 22.04)环境中使用python3命令来执行这个脚本会出现pyb模组不能安装, 调用最基本的helloworld 脚本也会报错. 网上查到使用 openmv ****.py 命令执行,安装不了openmv 这个命令。AI 提示从GitHub 上下载安装,但是链接没有任何响应。
      请帮忙告知正确的调用方法。以拜托这个openmv IDE 这个图形界面,执行脚本让脚本直接输出我要的打印。



    • 可以使用OpenMV的RPC的例子,这与IDE无关。

      1,OpenMV上改写代码:https://github.com/openmv/openmv/blob/master/scripts/examples/08-RPC-Library/34-Remote-Control/popular_features_as_the_remote_device.py

      添加你的rpc程序,就是检测LED的程序。
      注意要脱机运行。注意要使用interface = rpc.rpc_usb_vcp_slave()而不是interface = rpc.rpc_uart_slave(baudrate=115200)。
      这样可以直接用USB的虚拟串口。

      2,电脑上使用python脚本远程调用OpenMV的程序,步骤:https://github.com/openmv/openmv/blob/master/tools/rpc/README.md



    • python3 -u controller.py
      Traceback (most recent call last):
      File "/home/paulzhang/remotescript/controller.py", line 4, in
      interface = rpc.rpc_usb_vcp_master("/dev/ttyACM0")
      NameError: name 'rpc' is not defined

      I had installed the pyserial module, it seems rpc module can not be run in linux python3 environment. can you give a simple sample script such as helloworld let the ubuntu server running the python3 script to remote control the openmv print the fps data ,then print this data in python3 script output. thanks.



    • 你应该把rpc.py复制到你要运行的代码旁边。也就是controller.py旁边。



    • @kidswong999 python3 -u controller.py
      Traceback (most recent call last):
      File "/home/paulzhang/Desktop/openmv-master/scripts/libraries/controller.py", line 1, in
      import json, struct, serial, rpc
      File "/home/paulzhang/Desktop/openmv-master/scripts/libraries/rpc.py", line 9, in
      import omv
      ModuleNotFoundError: No module named 'omv'

      find / -name omv
      /home/paulzhang/Desktop/openmv-master/src/omv
      find: ‘/run/user/1000/doc’: Permission denied
      find: ‘/run/user/1000/gvfs’: Permission denied
      how to fix this issue.



    • I installed the omv-source, had found the omv module ,but now error report no pyb module found , but I can't find and install the pyb module, how to fix this issue ?
      python3 controller.py
      Traceback (most recent call last):
      File "/home/paulzhang/Desktop/omv-source/openmediavault-master/deb/openmediavault/srv/salt/_grains/controller.py", line 1, in
      import json, struct, serial, rpc
      File "/home/paulzhang/Desktop/omv-source/openmediavault-master/deb/openmediavault/srv/salt/_grains/rpc.py", line 10, in
      import pyb
      ModuleNotFoundError: No module named 'pyb'



    • 此回复已被删除!