problem for use remap

More
6 years 4 months ago #171990 by mahdi2001h
Hi



I tried to use remap for add my own G-code and run some python code by them

but when my CNC machine starting read G-codes just all remaped G-code run at start and not run in line that should run (but other lines run correctly)

for use remap I read linuxcnc.org/docs/html/remap/remap.html


my linuxcnc version is 2.7.15


I added this lines in my ini file :
Code:
[RS274NGC] PARAMETER_FILE = linuxcnc.var REMAP=G70 modalgroup=1 argspec=Pq py=g700 REMAP=G70.1 modalgroup=1 argspec=Pq py=g701

and added in G-codes(inside other lines) :
Code:
G70 P8 G70 P9 G70 P10 G70.1 P6



regards

Please Log in or Create an account to join the conversation.

More
6 years 4 months ago #171995 by Aciera
Replied by Aciera on topic problem for use remap
Could you also show your python code?

Please Log in or Create an account to join the conversation.

More
6 years 4 months ago - 6 years 4 months ago #171996 by mahdi2001h
Replied by mahdi2001h on topic problem for use remap
Code:
def g700(self, **words): s.poll() if s.estop == 0: print "test p =" , words["p"] return INTERP_OK def g701(self, **words): s.poll() if s.estop == 0: print "test1" return INTERP_OK
Last edit: 6 years 4 months ago by mahdi2001h.

Please Log in or Create an account to join the conversation.

More
6 years 4 months ago #171997 by rodw
Replied by rodw on topic problem for use remap
There is a Sim with remapping setup. Have you looked at it. It is helpful as none of it is intuitive...

Please Log in or Create an account to join the conversation.

More
6 years 4 months ago - 6 years 4 months ago #171998 by mahdi2001h
Replied by mahdi2001h on topic problem for use remap
where is that?!

How can I use it?
Last edit: 6 years 4 months ago by mahdi2001h.

Please Log in or Create an account to join the conversation.

More
6 years 4 months ago #171999 by rodw
Replied by rodw on topic problem for use remap
From the main linuxcnc config chooser, there should be a whole list of simulations. One of them is called remap... so it will run without a machine and you can study how it works.

Please Log in or Create an account to join the conversation.

Time to create page: 0.396 seconds
Powered by Kunena Forum