diff --git a/configs/sim/qtvcp_screens/industrial_lathe_wear/industrial_lathe_wear.ini b/configs/sim/qtvcp_screens/industrial_lathe_wear/industrial_lathe_wear.ini index 7f68bdeb8ca..4a577c8aa0f 100644 --- a/configs/sim/qtvcp_screens/industrial_lathe_wear/industrial_lathe_wear.ini +++ b/configs/sim/qtvcp_screens/industrial_lathe_wear/industrial_lathe_wear.ini @@ -1,8 +1,8 @@ [EMC] VERSION = 1.1 MACHINE = LinuxCNC-HAL-SIM-AXIS -#DEBUG = 0x7FFFFFFF -DEBUG = 0x00004000 +DEBUG = 0x7FFFFFFF +#DEBUG = 0x00004000 [DISPLAY] DISPLAY = qtvcp -d qtlathe PREFERENCE_FILE_PATH = WORKINGFOLDER/qtlathe.pref diff --git a/configs/sim/qtvcp_screens/industrial_lathe_wear/remap.py b/configs/sim/qtvcp_screens/industrial_lathe_wear/remap.py index b500f0151fa..312f3eb7fe6 100644 --- a/configs/sim/qtvcp_screens/industrial_lathe_wear/remap.py +++ b/configs/sim/qtvcp_screens/industrial_lathe_wear/remap.py @@ -22,6 +22,7 @@ # ignore_m6() from stdglue import * +from interpreter import INTERP_OK from emccanon import MESSAGE COUNT = 0 @@ -33,10 +34,11 @@ def ignore_m6(self,**words): return "Ignore M6 failed: %s" % (e) def m2_remap(self, **words): # in remap module - print self.remap_level + print 'remap level:'.format(self.remap_level) + print 'call level:',self.call_level global COUNT COUNT +=1 - print 'run count:{}'.format(COUNT) + print 'Run count:{}'.format(COUNT) #MESSAGE("remapped m2") self.execute("m2") diff --git a/src/emc/rs274ngc/interp_convert.cc b/src/emc/rs274ngc/interp_convert.cc index 44451f2a2a8..e9a48c532cd 100644 --- a/src/emc/rs274ngc/interp_convert.cc +++ b/src/emc/rs274ngc/interp_convert.cc @@ -4282,14 +4282,16 @@ int Interp::convert_stop(block_pointer block, //!< pointer to a block of RS27 ) { -if (IS_USER_MCODE(block,settings,4) && - STEP_REMAPPED_IN_BLOCK(block, STEP_MGROUP4) && - ONCE_M4) { - printf("*remap conversion-%d*\n",block->m_modes[4]); - return convert_remapped_code(block, settings, STEP_MGROUP4, 'm', - block->m_modes[4]);} - - printf("*no remap conversion-%d*\n",block->m_modes[4]); + if (IS_USER_MCODE(block,settings,4) && + STEP_REMAPPED_IN_BLOCK(block, STEP_MGROUP4) && + ONCE_M4) { + printf("*remap conversion-%d*\n",block->m_modes[4]); + return convert_remapped_code(block, settings, STEP_MGROUP4, 'm', + block->m_modes[4]); + }else{ + CONTROLLING_BLOCK(*settings).builtin_used = !STEP_REMAPPED_IN_BLOCK(block, STEP_MGROUP4); + printf("*no remap conversion-%d*\n",block->m_modes[4]); + } /* reset stuff here */ /*1*/ diff --git a/src/emc/rs274ngc/interp_execute.cc b/src/emc/rs274ngc/interp_execute.cc index 11d74b21b13..988bef4889d 100644 --- a/src/emc/rs274ngc/interp_execute.cc +++ b/src/emc/rs274ngc/interp_execute.cc @@ -311,6 +311,7 @@ int Interp::execute_block(block_pointer block, //!< pointer to a block of RS27 printf("*Nope----------------------------------------%d*\n",block->m_modes[4]); status = convert_stop(block, settings); } + printf("*returned status:-----------exit-=%d-----ok=%d---------------------=%d\n",INTERP_EXIT,INTERP_OK,status); if (status == INTERP_EXIT) { return(INTERP_EXIT); }