Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5

RoboDK: Mecademic meca500: Connect issue: Python cannot find files

#1
Hello,

I am using RoboDK v5.4.3 released 2022-07-24. Robot: Mecademic Meca500-r3 is running firmware v8.4 if that matters. I am trying to connect to and do basic movements on our Mecademic Meca 500 r3 over it's ethernet, but there are some errors connecting to hardware. The m500's web interface works fine, so I deduce the hardware is good, the connection is probably good (at least at the physical layer), and I have let anything requesting a hole in Windows Firewall that access. The Ping function in RoboDK works.

I did note some issues during install such as this:


That looks like something failed, but was not fully captured or traced.

The Ping works, yet when connecting I get these errors in the log window:



It looks like the Pythonpath is not working right, so I re-installed. Same issue. So then I re-ran some setup.py's manually to try and resolve dependencies, which seemed to help, but did not fully resolve the issue.


It looks similar, but still missing something. The files are there, I'm not sure why it "can't find them". I started poking around with some python tools, but was limited by not wanting to touch the RoboDK python environment, and too new to want to perhaps induce other issues by pointing RoboDK to a conda virtual environment I control and attempt to resolve RoboDK's dependencies within. But I did install RoboDK with Python, here is its configuration pointing to that environment:

Any ideas? Not being able to connect is quite a show-stopper for both application and futher development, but maybe we can leverage simulation more while this is being resolved.

Ideally, I'd run my own python environment in a conda venv, but to start, I can say I let it install its own Python and dependencies in it's preferred folder, and is using bone stock Python 3.7 from the installation, as best I can tell. This should be fine since I think it explicitly calls this python.exe and associates with that environment/folder (but can't seem to find the installed files).

Here are some seemingly related forum posts, but they are different:
//www.sinclairbody.com/forum/Thread-Meca500-...obot-issue
//www.sinclairbody.com/forum/Thread-RoboDk-c...er-problem
>> Very similar to my issues and steps attempted, but I am not using a custom driver. It is the stock driver.
//www.sinclairbody.com/forum/Thread-Can-t-connect-to-robot




Ah, this is why my post was too long and pictures added a ton of characters. They are being base64 encoded and quickly exceed the post character limit. Argh. see here for how to post images on RoboDK forum://www.sinclairbody.com/forum/Thread-READ-THI...GUIDELINES
#2
Can you try the following?

C:\RoboDK\Python\python.exe -m pip install --upgrade --force-reinstall mecademicpy

We used to bundle the mecademicpy driver with RoboDK, but removed in recently. It should automatically install.
RoboDK版本是什么you using?
Please read theForum Guidelinesbefore posting!
Find useful information about RoboDK by visiting our2022世界杯32强赛程表时间 .
#3
(10-06-2022, 11:49 AM)Sam Wrote:Can you try the following?

C:\RoboDK\Python\python.exe -m pip install --upgrade --force-reinstall mecademicpy

We used to bundle the mecademicpy driver with RoboDK, but removed in recently. It should automatically install.
RoboDK版本是什么you using?

I saw in v5.5,

New in RoboDK v5.5.0 (2022-08-19)
  • Added support for importing STEP and IGES files on MacOS
  • Fixed joint limits issue with the collision free planner
  • Fixedmecademicpy installer
  • 改进的三菱司机
  • Added Surface Pattern Generation App
  • Updated Mac version
  • Added option to filter KUKA CIRC movements
So I updated v5.4.3 (2022-07-24) to: v5.5.1.22568 (latest as of this post)

Unfortunately this just got me back to the first issue, seemingly related to lack of a dependency or inability to traverse the path correctly,

Code:
Starting robot driver: C:/RoboDK/api/robot/apimecademicpy.py
Starting...
Unexpected error: Traceback (most recent call last):
Unexpected error: File "C:/RoboDK/api/robot/apimecademicpy.py", line 26, in
Unexpected error: exec("from v" + version_str + ".apimecademicpy import *")
Unexpected error: File "", line 1, in
Unexpected error: File "C:\RoboDK\api\robot\apimecademicpy.py", line 62, in
Unexpected error: File "C:\RoboDK\Python\mecademicpy\robot.py", line 6, in
Unexpected error: import deprecation
Unexpected error: ModuleNotFoundError: No module named 'deprecation'
Sending command...
Stopped
Driver apimecademicpy.py not running

But your fix (basically) worked! I did not have a `python.exe`in C:\RoboDK\Python\, so I called the --force reinstall using the included python 3.7 environment:
Code:
user@h0stname MINGW64 /c/RoboDK/Python37
$ ./python.exe -m pip install --upgrade --force-reinstall mecademicpy
Collecting mecademicpy
Downloading https://files.pythonhosted.org/packages/79/62/c8bfc25593befb28d9747f575b0ed7c49b76457742804764752229072c9c/mecademicpy-1.2.1-py3-none-any.whl (65kB)
Collecting deprecation (from mecademicpy)
Downloading https://files.pythonhosted.org/packages/02/c3/253a89ee03fc9b9682f1541728eb66db7db22148cd94f89ab22528cd1e1b/deprecation-2.1.0-py2.py3-none-any.whl
Collecting dataclasses-json>=0.5.4 (from mecademicpy)
Downloading https://files.pythonhosted.org/packages/58/7e/2042610dfc8121e8119ad8b94db496d8697e4b0ef7a6e378018a2bd84435/dataclasses_json-0.5.7-py3-none-any.whl
Collecting requests (from mecademicpy)
Downloading https://files.pythonhosted.org/packages/ca/91/6d9b8ccacd0412c08820f72cebaa4f0c0441b5cda699c90f618b6f8a1b42/requests-2.28.1-py3-none-any.whl (62kB)
Collecting pandas (from mecademicpy)
Downloading https://files.pythonhosted.org/packages/b2/56/f886ed6f1777ffa9d54c6e80231b69db8a1f52dcc33f5967b06a105dcfe0/pandas-1.3.5-cp37-cp37m-win_amd64.whl (10.0MB)
Collecting packaging (from deprecation->mecademicpy)
Using cached https://files.pythonhosted.org/packages/05/8e/8de486cbd03baba4deef4142bd643a3e7bbe954a784dc1bb17142572d127/packaging-21.3-py3-none-any.whl
Collecting typing-inspect>=0.4.0 (from dataclasses-json>=0.5.4->mecademicpy)
Downloading https://files.pythonhosted.org/packages/be/01/59b743dca816c4b6ca891b9e0f84d20513cd61bdbbaa8615de8f5aab68c1/typing_inspect-0.8.0-py3-none-any.whl

Note `packaging` is the only one in this list where it already had the identical package downloaded and could use the cached version. While maybe some got updated, this leads me to think there is still something wonky with the mecademicpy installer. This Python 3.7 environment is confirmed to be my system Python, figuring I should let it have this just in case, and I can do my other stuff on the side in conda with explicit virtual environments in their own area.
So it is now connecting, and usually can move. Though...

我不确定相关,但我有时会these in the logs:

Code:
连接到机器人192.168.0.100
Working...
Robot status: Active: False, Homed: False, Simmode: False, Error: False, Pause: False, EOB: True
Robot infos: Model: Meca500, Revision: 3, Version: 8.4.5.2580, SN: M500-[redacted], IP: 192.168.0.100
Reset errors...
Unexpected error: Received robot error 1005 (MX_ST_NOT_ACTIVATED): The robot is not activated.
Connection problems
Connection refused. You may need to reboot your Meca robot.

Disconnected
Ready
'NoneType' object has no attribute 'wait'
Disconnected

It seems like something drops or is unhandled, and a list becomes undefined or 'None', but it doesn't say what. The web interface can then be used to re-connect, clear errors, home, and then I can connect again in RoboDK (after closing the connection there). There is no need to re-boot it, though I do need to re-home in the web interface to use it and get it back into a state RoboDK is happy with. Is there a way to turn up log verbosity, or trace this myself? Is this related to a module not being installed by the mecademicpy installer? Or any other ideas?
Thank you for your continued support. Happy this is Python, which is great for taking apart and tinkering when problems arise.
#4
What is the version of the driver you are using? I believe this was fixed in 3.0.1.

Contact us at info@www.sinclairbody.com and mention my name, we can better investigate and send you the latest driver version.
Please read theForum Guidelinesbefore posting!
Find useful information about RoboDK by visiting our2022世界杯32强赛程表时间 .
#5
(10-06-2022, 07:52 PM)Sam Wrote:What is the version of the driver you are using? I believe this was fixed in 3.0.1.

Contact us at info@www.sinclairbody.com and mention my name, we can better investigate and send you the latest driver version.

pip freeze reveals "mecademicpy==1.2.1", not sure if this is the same as the selected driver: "apimecademicpy.py" or other available driver: "apimecademic.py", or what the difference is.

Crawling the dir looking for apimecademicpy, mecademicpy, version strings, __version__, etc. did not yield results other than '1.2.1'. But I just did a --force-reinstall which should have grabbed the latest version?

I will f/up with email.




Users browsing this thread:
1 Guest(s)