Having another go at remaping M6
this is just a problem of Unix pathnames.
the log says:
cant resolve path to 'python/toplevel.py'
no Python plugin available
which means:
- using a REMAP module requires the Python plugin to be configured and initialized
- to initialize, the Python plugin must be able to read the toplevel Python script which is set with the [PYTHON]TOPLEVEL=<path to toplevel script>
- during startup the path 'python/toplevel.py' could not be found - it is a relative path and obviously it cant find either the 'python' directory or the 'toplevel.py' script within it
So as soon as you use a REMAP, the interpreter needs to be able to find the toplevel script
Fix: replace [PYTHON]TOPLEVEL=<absolute path to toplevel script>
like /home/gary/linuxcnc/config/yadayada/python/toplevel.py
same goes for the APPEND/PREPEND pathes
-m
Please Log in or Create an account to join the conversation.
- garymcrobertpdx
- Offline
- Elite Member
- Posts: 164
- Thank you received: 1
OK PYTHON]TOPLEVEL= and APPEND/PREPEND appear in my ini file
I assume those are the ones that need the path corrected to one some what
like the example you provided /home/gary/linuxcnc/config/yadayada/python/toplevel.py
I searched for any Python directory's or files in the home directory
no Python directorys were found and only a few python scripts like
hole circle.py No toplevel.py found.
when going wider afield, locate did find many directorys and files like this
/usr/share/doc/linuxcnc/examples/sample-configs/sim/remap/rack-toolchange/python/toplevel.py
Could it be that I need to install an additional Python package???
G.
Please Log in or Create an account to join the conversation.
Michael
OK PYTHON]TOPLEVEL= and APPEND/PREPEND appear in my ini file
I assume those are the ones that need the path corrected to one some what
like the example you provided /home/gary/linuxcnc/config/yadayada/python/toplevel.py
I searched for any Python directory's or files in the home directory
no Python directorys were found and only a few python scripts like
hole circle.py No toplevel.py found.
when going wider afield, locate did find many directorys and files like this
/usr/share/doc/linuxcnc/examples/sample-configs/sim/remap/rack-toolchange/python/toplevel.py
Could it be that I need to install an additional Python package???
G.
Gary -
you are not missing any additional Python packages. Stepconf just doesnt know about remapping so if you use remapping the configuration options have to be added manually lateron.
Since I cannot tell where your working configuration is, I assume now you have your configuration under /home/gary/foo , and the inifile is foo.ini .
1. create a directory /home/gary/foo/python
2. copy /usr/share/doc/linuxcnc/examples/sample-configs/sim/remap/rack-toolchange/python/toplevel.py to /home/gary/foo/python
3. copy /usr/share/doc/linuxcnc/examples/sample-configs/sim/remap/python-stdglue/stdglue.py to /home/gary/foo/python
4. copy /usr/share/doc/linuxcnc/examples/sample-configs/sim/remap/rack-toolchange/python/remap.py to /home/gary/foo/python (note this imports the stdglue handlers available as outlined in the documentation)
5. in foo.ini add [PYTHON]TOPLEVEL=/home/gary/foo/python/toplevel.py
6. in foo.ini add [PYTHON]APPEND=/home/gary/foo/python , which adds the directory where the relevant Python modules for remapping live to the Python path.
- Michael
Please Log in or Create an account to join the conversation.
-m
Please Log in or Create an account to join the conversation.
- garymcrobertpdx
- Offline
- Elite Member
- Posts: 164
- Thank you received: 1
I ran a basic remap m6 example it seems to work.
Thank you Michael for the patent helping hand.
I suspect I have much more work ahead of me
before I get this all working but I now have a
starting place.
Gary
Please Log in or Create an account to join the conversation.
IT'S ALIVE !!!
...
Gary
good to hear! this stuff isnt terribly accessible yet, and there's a big difference between "works for the developer" and "works for the rest of us" - but you're off to a good start
out of curiosity what are you trying to achieve?
- Michael
Please Log in or Create an account to join the conversation.