rendered paste body? M4x.diff
? m4x.diff
? hal/utils/comp.py
Index: config.h.in
===================================================================
RCS file: /cvs/emc2/src/config.h.in,v
retrieving revision 1.11
diff -u -p -r1.11 config.h.in
--- config.h.in 23 Oct 2006 14:54:10 -0000 1.11
+++ config.h.in 4 Nov 2006 23:26:00 -0000
@@ -29,7 +29,7 @@
/* Assorted defines used through out the source code. */
#define ACTIVE_G_CODES 13
-#define ACTIVE_M_CODES 7
+#define ACTIVE_M_CODES 9
#define ACTIVE_SETTINGS 3
#define MM_PER_INCH 25.4
Index: emc/motion/command.c
===================================================================
RCS file: /cvs/emc2/src/emc/motion/command.c,v
retrieving revision 1.70
diff -u -p -r1.70 command.c
--- emc/motion/command.c 17 Oct 2006 19:28:07 -0000 1.70
+++ emc/motion/command.c 4 Nov 2006 23:26:01 -0000
@@ -957,13 +957,28 @@ check_stuff ( "before command_handler()"
emcmotStatus->qVscale = emcmotCommand->scale;
break;
- case EMCMOT_FEED_OVERRIDE:
+ case EMCMOT_FO_ENABLE:
/* enable/disable overriding speed */
/* can happen at any time */
- rtapi_print_msg(RTAPI_MSG_DBG, "FEED_OVERRIDE");
+ if ( emcmotCommand->mode != 0 ) {
+ rtapi_print_msg(RTAPI_MSG_DBG, "FEED OVERRIDE: ON");
+ } else {
+ rtapi_print_msg(RTAPI_MSG_DBG, "FEED OVERRIDE: OFF");
+ }
emcmotStatus->fo_mode = emcmotCommand->mode; //0 means no override is possible
break;
+ case EMCMOT_FH_ENABLE:
+ /* enable/disable feed hold */
+ /* can happen at any time */
+ if ( emcmotCommand->mode != 0 ) {
+ rtapi_print_msg(RTAPI_MSG_DBG, "FEED HOLD: ENABLED");
+ } else {
+ rtapi_print_msg(RTAPI_MSG_DBG, "FEED HOLD: DISABLED");
+ }
+ /*FIXME : JMK does something usefull here with emcmotCommand->mode; //0 means feed_hold is not taken into consideration*/
+ break;
+
case EMCMOT_SPINDLE_SCALE:
/* override spindle speed */
/* can happen at any time */
@@ -974,15 +989,19 @@ check_stuff ( "before command_handler()"
emcmotStatus->spindle_scale = emcmotCommand->scale;
break;
- case EMCMOT_SPINDLE_OVERRIDE:
+ case EMCMOT_SO_ENABLE:
/* enable/disable overriding spindle speed */
/* can happen at any time */
- rtapi_print_msg(RTAPI_MSG_DBG, "SPINDLE_OVERRIDE");
+ if ( emcmotCommand->mode != 0 ) {
+ rtapi_print_msg(RTAPI_MSG_DBG, "SPINDLE OVERRIDE: ON");
+ } else {
+ rtapi_print_msg(RTAPI_MSG_DBG, "SPINDLE OVERRIDE: OFF");
+ }
emcmotStatus->so_mode = emcmotCommand->mode; //0 means no override is possible
break;
- case EMCMOT_ADAPTIVE_FEED:
+ case EMCMOT_AF_ENABLE:
/* enable/disable adaptive feedrate override from HAL pin */
/* can happen at any time */
if ( emcmotCommand->flags != 0 ) {
Index: emc/motion/motion.h
===================================================================
RCS file: /cvs/emc2/src/emc/motion/motion.h,v
retrieving revision 1.67
diff -u -p -r1.67 motion.h
--- emc/motion/motion.h 29 Oct 2006 23:53:35 -0000 1.67
+++ emc/motion/motion.h 4 Nov 2006 23:26:02 -0000
@@ -117,10 +117,11 @@ extern "C" {
EMCMOT_TELEOP, /* set mode to teleop */
EMCMOT_SCALE, /* scale the speed */
- EMCMOT_FEED_OVERRIDE, /* enable scaling the speed (M48/M49) */
+ EMCMOT_FO_ENABLE, /* enable/disable scaling the speed (M48/M49) */
+ EMCMOT_FH_ENABLE, /* enable/disable feed_hold */
EMCMOT_SPINDLE_SCALE, /* scale the spindle speed */
- EMCMOT_SPINDLE_OVERRIDE, /* enable scaling the spindle speed (M48/M49) */
- EMCMOT_ADAPTIVE_FEED, /* enable/disable adaptive feedrate */
+ EMCMOT_SO_ENABLE, /* enable/disable scaling the spindle speed (M48/M49) */
+ EMCMOT_AF_ENABLE, /* enable/disable adaptive feedrate */
EMCMOT_OVERRIDE_LIMITS, /* temporarily ignore limits until jog done */
EMCMOT_HOME, /* home an axis */
Index: emc/nml_intf/canon.hh
===================================================================
RCS file: /cvs/emc2/src/emc/nml_intf/canon.hh,v
retrieving revision 1.15
diff -u -p -r1.15 canon.hh
--- emc/nml_intf/canon.hh 24 Oct 2006 20:04:34 -0000 1.15
+++ emc/nml_intf/canon.hh 4 Nov 2006 23:26:03 -0000
@@ -329,9 +329,6 @@ translation commands. */
extern void START_SPEED_FEED_SYNCH(double spindlesync);
extern void STOP_SPEED_FEED_SYNCH();
-/* used for EDM adaptive moves with motion internal feed override (0..1) */
-extern void START_ADAPTIVE_FEED();
-extern void STOP_ADAPTIVE_FEED();
/* Machining Functions */
@@ -506,10 +503,23 @@ logged, the comment command is printed o
which is the value of comment_text. This serves to allow formal
comments at specific locations in programs or command files. */
+/* used for EDM adaptive moves with motion internal feed override (0..1) */
+extern void DISABLE_ADAPTIVE_FEED();
+extern void ENABLE_ADAPTIVE_FEED();
+
+/* used to deactivate user control of feed override */
extern void DISABLE_FEED_OVERRIDE();
extern void ENABLE_FEED_OVERRIDE();
+
+/* used to deactivate user control of spindle speed override */
extern void DISABLE_SPEED_OVERRIDE();
extern void ENABLE_SPEED_OVERRIDE();
+
+/* used to deactivate user control of feed hold */
+extern void DISABLE_FEED_HOLD();
+extern void ENABLE_FEED_HOLD();
+
+
extern void FLOOD_OFF();
/* Turn flood coolant off. */
extern void FLOOD_ON();
Index: emc/nml_intf/emc.cc
===================================================================
RCS file: /cvs/emc2/src/emc/nml_intf/emc.cc,v
retrieving revision 1.30
diff -u -p -r1.30 emc.cc
--- emc/nml_intf/emc.cc 24 Oct 2006 20:04:34 -0000 1.30
+++ emc/nml_intf/emc.cc 4 Nov 2006 23:26:06 -0000
@@ -474,11 +474,14 @@ int emcFormat(NMLTYPE type, void *buffer
case EMC_TRAJ_SET_SPINDLE_SCALE_TYPE:
((EMC_TRAJ_SET_SPINDLE_SCALE *) buffer)->update(cms);
break;
- case EMC_TRAJ_SET_FEED_OVERRIDE_TYPE:
- ((EMC_TRAJ_SET_FEED_OVERRIDE *) buffer)->update(cms);
+ case EMC_TRAJ_SET_FO_ENABLE_TYPE:
+ ((EMC_TRAJ_SET_FO_ENABLE *) buffer)->update(cms);
break;
- case EMC_TRAJ_SET_SPINDLE_OVERRIDE_TYPE:
- ((EMC_TRAJ_SET_SPINDLE_OVERRIDE *) buffer)->update(cms);
+ case EMC_TRAJ_SET_SO_ENABLE_TYPE:
+ ((EMC_TRAJ_SET_SO_ENABLE *) buffer)->update(cms);
+ break;
+ case EMC_TRAJ_SET_FH_ENABLE_TYPE:
+ ((EMC_TRAJ_SET_FH_ENABLE *) buffer)->update(cms);
break;
case EMC_TRAJ_SET_TELEOP_ENABLE_TYPE:
((EMC_TRAJ_SET_TELEOP_ENABLE *) buffer)->update(cms);
@@ -801,10 +804,12 @@ const char *emc_symbol_lookup(long type)
return "EMC_TRAJ_SET_SCALE";
case EMC_TRAJ_SET_SPINDLE_SCALE_TYPE:
return "EMC_TRAJ_SET_SPINDLE_SCALE";
- case EMC_TRAJ_SET_FEED_OVERRIDE_TYPE:
- return "EMC_TRAJ_SET_FEED_OVERRIDE";
- case EMC_TRAJ_SET_SPINDLE_OVERRIDE_TYPE:
- return "EMC_TRAJ_SET_SPINDLE_OVERRIDE";
+ case EMC_TRAJ_SET_FO_ENABLE_TYPE:
+ return "EMC_TRAJ_SET_FO_ENABLE";
+ case EMC_TRAJ_SET_SO_ENABLE_TYPE:
+ return "EMC_TRAJ_SET_SO_ENABLE";
+ case EMC_TRAJ_SET_FH_ENABLE_TYPE:
+ return "EMC_TRAJ_SET_FH_ENABLE";
case EMC_TRAJ_SET_TELEOP_ENABLE_TYPE:
return "EMC_TRAJ_SET_TELEOP_ENABLE";
case EMC_TRAJ_SET_TELEOP_VECTOR_TYPE:
@@ -2015,11 +2020,11 @@ void EMC_TRAJ_SET_SPINDLE_SCALE::update(
}
/*
-* NML/CMS Update function for EMC_TRAJ_SET_FEED_OVERRIDE
+* NML/CMS Update function for EMC_TRAJ_SET_FO_ENABLE
* Automatically generated by Alex Joni :)
* on Tue Oct 17 00:14:16 GMT+3 2006
*/
-void EMC_TRAJ_SET_FEED_OVERRIDE::update(CMS * cms)
+void EMC_TRAJ_SET_FO_ENABLE::update(CMS * cms)
{
EMC_TRAJ_CMD_MSG::update(cms);
@@ -2032,7 +2037,20 @@ void EMC_TRAJ_SET_FEED_OVERRIDE::update(
* Automatically generated by Alex Joni :)
* on Tue Oct 17 00:14:16 GMT+3 2006
*/
-void EMC_TRAJ_SET_SPINDLE_OVERRIDE::update(CMS * cms)
+void EMC_TRAJ_SET_SO_ENABLE::update(CMS * cms)
+{
+
+ EMC_TRAJ_CMD_MSG::update(cms);
+ cms->update(mode);
+
+}
+
+/*
+* NML/CMS Update function for EMC_TRAJ_SET_FH_ENABLE
+* Automatically generated by Alex Joni :)
+* on Sat Nov 04 11:42:16 GMT+2 2006
+*/
+void EMC_TRAJ_SET_FH_ENABLE::update(CMS * cms)
{
EMC_TRAJ_CMD_MSG::update(cms);
@@ -2040,6 +2058,7 @@ void EMC_TRAJ_SET_SPINDLE_OVERRIDE::upda
}
+
/*
* NML/CMS Update function for EMC_IO_ABORT
* Automatically generated by NML CodeGen Java Applet.
Index: emc/nml_intf/emc.hh
===================================================================
RCS file: /cvs/emc2/src/emc/nml_intf/emc.hh,v
retrieving revision 1.43
diff -u -p -r1.43 emc.hh
--- emc/nml_intf/emc.hh 24 Oct 2006 20:04:34 -0000 1.43
+++ emc/nml_intf/emc.hh 4 Nov 2006 23:26:09 -0000
@@ -123,8 +123,9 @@
#define EMC_TRAJ_SET_TELEOP_VECTOR_TYPE ((NMLTYPE) 231)
#define EMC_TRAJ_SET_SPINDLESYNC_TYPE ((NMLTYPE) 232)
#define EMC_TRAJ_SET_SPINDLE_SCALE_TYPE ((NMLTYPE) 233)
-#define EMC_TRAJ_SET_FEED_OVERRIDE_TYPE ((NMLTYPE) 234)
-#define EMC_TRAJ_SET_SPINDLE_OVERRIDE_TYPE ((NMLTYPE) 235)
+#define EMC_TRAJ_SET_FO_ENABLE_TYPE ((NMLTYPE) 234)
+#define EMC_TRAJ_SET_SO_ENABLE_TYPE ((NMLTYPE) 235)
+#define EMC_TRAJ_SET_FH_ENABLE_TYPE ((NMLTYPE) 236)
#define EMC_TRAJ_STAT_TYPE ((NMLTYPE) 299)
@@ -415,10 +416,11 @@ extern int emcTrajSetAcceleration(double
extern int emcTrajSetMaxVelocity(double vel);
extern int emcTrajSetMaxAcceleration(double acc);
extern int emcTrajSetScale(double scale);
-extern int emcTrajSetFeedOverride(unsigned char mode);
+extern int emcTrajSetFOEnable(unsigned char mode); //feed override enable
+extern int emcTrajSetFHEnable(unsigned char mode); //feed hold enable
extern int emcTrajSetSpindleScale(double scale);
-extern int emcTrajSetSpindleOverride(unsigned char mode);
-extern int emcTrajSetAdaptiveFeed(unsigned char enable);
+extern int emcTrajSetSOEnable(unsigned char mode); //spindle speed override enable
+extern int emcTrajSetAFEnable(unsigned char enable); //adaptive feed enable
extern int emcTrajSetMotionId(int id);
extern double emcTrajGetLinearUnits();
extern double emcTrajGetAngularUnits();
@@ -1273,10 +1275,10 @@ class EMC_TRAJ_SET_SPINDLE_SCALE:public
double scale;
};
-class EMC_TRAJ_SET_FEED_OVERRIDE:public EMC_TRAJ_CMD_MSG {
+class EMC_TRAJ_SET_FO_ENABLE:public EMC_TRAJ_CMD_MSG {
public:
- EMC_TRAJ_SET_FEED_OVERRIDE():EMC_TRAJ_CMD_MSG(EMC_TRAJ_SET_FEED_OVERRIDE_TYPE,
- sizeof(EMC_TRAJ_SET_FEED_OVERRIDE)) {
+ EMC_TRAJ_SET_FO_ENABLE():EMC_TRAJ_CMD_MSG(EMC_TRAJ_SET_FO_ENABLE_TYPE,
+ sizeof(EMC_TRAJ_SET_FO_ENABLE)) {
};
// For internal NML/CMS use only.
@@ -1285,10 +1287,10 @@ class EMC_TRAJ_SET_FEED_OVERRIDE:public
unsigned char mode; //mode=0, override off (will work with 100% FO), mode != 0, override on, user can change FO
};
-class EMC_TRAJ_SET_SPINDLE_OVERRIDE:public EMC_TRAJ_CMD_MSG {
+class EMC_TRAJ_SET_SO_ENABLE:public EMC_TRAJ_CMD_MSG {
public:
- EMC_TRAJ_SET_SPINDLE_OVERRIDE():EMC_TRAJ_CMD_MSG(EMC_TRAJ_SET_SPINDLE_OVERRIDE_TYPE,
- sizeof(EMC_TRAJ_SET_SPINDLE_OVERRIDE)) {
+ EMC_TRAJ_SET_SO_ENABLE():EMC_TRAJ_CMD_MSG(EMC_TRAJ_SET_SO_ENABLE_TYPE,
+ sizeof(EMC_TRAJ_SET_SO_ENABLE)) {
};
// For internal NML/CMS use only.
@@ -1297,6 +1299,17 @@ class EMC_TRAJ_SET_SPINDLE_OVERRIDE:publ
unsigned char mode; //mode=0, override off (will work with 100% SO), mode != 0, override on, user can change SO
};
+class EMC_TRAJ_SET_FH_ENABLE:public EMC_TRAJ_CMD_MSG {
+ public:
+ EMC_TRAJ_SET_FH_ENABLE():EMC_TRAJ_CMD_MSG(EMC_TRAJ_SET_FH_ENABLE_TYPE,
+ sizeof(EMC_TRAJ_SET_FH_ENABLE)) {
+ };
+
+ // For internal NML/CMS use only.
+ void update(CMS * cms);
+
+ unsigned char mode; //mode=0, override off (feedhold is disabled), mode != 0, override on, user can use feedhold
+};
class EMC_TRAJ_SET_MOTION_ID:public EMC_TRAJ_CMD_MSG {
public:
Index: emc/rs274ngc/gcodemodule.cc
===================================================================
RCS file: /cvs/emc2/src/emc/rs274ngc/gcodemodule.cc,v
retrieving revision 1.7
diff -u -p -r1.7 gcodemodule.cc
--- emc/rs274ngc/gcodemodule.cc 31 Oct 2006 03:32:23 -0000 1.7
+++ emc/rs274ngc/gcodemodule.cc 4 Nov 2006 23:26:09 -0000
@@ -422,8 +422,8 @@ int GET_EXTERNAL_MIST() { return 0; }
CANON_PLANE GET_EXTERNAL_PLANE() { return 1; }
double GET_EXTERNAL_SPEED() { return 0; }
int GET_EXTERNAL_TOOL_MAX() { return CANON_TOOL_MAX; }
-void STOP_ADAPTIVE_FEED() {}
-void START_ADAPTIVE_FEED() {}
+void DISABLE_ADAPTIVE_FEED() {}
+void ENABLE_ADAPTIVE_FEED() {}
bool PyFloat_CheckAndError(const char *func, PyObject *p) {
if(PyFloat_Check(p)) return true;
Index: emc/rs274ngc/interp_array.cc
===================================================================
RCS file: /cvs/emc2/src/emc/rs274ngc/interp_array.cc,v
retrieving revision 1.9
diff -u -p -r1.9 interp_array.cc
--- emc/rs274ngc/interp_array.cc 31 Jul 2006 02:59:33 -0000 1.9
+++ emc/rs274ngc/interp_array.cc 4 Nov 2006 23:26:10 -0000
@@ -68,7 +68,6 @@ group 8 = {g43,g49} - tool length
group 10 = {g98,g99} - return mode in canned cycles
group 12 = {g54,g55,g56,g57,g58,g59,g59.1,g59.2,g59.3} - coordinate system
group 13 = {g61,g61.1,g64} - control mode (path following)
-group 14 = {g50,g51} - adaptive feed enable/disable
*/
// This stops indent from reformatting the following code.
@@ -99,7 +98,7 @@ const int Interp::_gees[] = {
/* 440 */ -1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,
/* 460 */ -1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,
/* 480 */ -1,-1,-1,-1,-1,-1,-1,-1,-1,-1, 8,-1,-1,-1,-1,-1,-1,-1,-1,-1,
-/* 500 */ 14,-1,-1,-1,-1,-1,-1,-1,-1,-1,14,-1,-1,-1,-1,-1,-1,-1,-1,-1,
+/* 500 */ -1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,
/* 520 */ -1,-1,-1,-1,-1,-1,-1,-1,-1,-1, 0,-1,-1,-1,-1,-1,-1,-1,-1,-1,
/* 540 */ 12,-1,-1,-1,-1,-1,-1,-1,-1,-1,12,-1,-1,-1,-1,-1,-1,-1,-1,-1,
/* 560 */ 12,-1,-1,-1,-1,-1,-1,-1,-1,-1,12,-1,-1,-1,-1,-1,-1,-1,-1,-1,
@@ -138,31 +137,35 @@ group 5 = {m62,m63,m64,m65} - turn I/O
group 6 = {m6} - tool change
group 7 = {m3,m4,m5} - spindle turning
group 8 = {m7,m8,m9} - coolant
-group 9 = {m48,m49} - feed and speed override switch bypass
+group 9 = {m48,m49, - feed and speed override switch bypass
+ m50, - feed override switch bypass P1 to turn on, P0 to turn off
+ m51, - spindle speed override switch bypass P1 to turn on, P0 to turn off
+ m52, - adaptive feed override switch bypass P1 to turn on, P0 to turn off
+ m53} - feedstop override switch bypass P1 to turn on, P0 to turn off
group 10 = {m100..m199} - user-defined
*/
const int Interp::_ems[] = {
- 4, 4, 4, 7, 7, 7, 6, 8, 8, 8,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- 4, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, 9, 9,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- 4, -1, 5, 5, 5, 5, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- 10, 10, 10, 10, 10, 10, 10, 10, 10, 10,
- 10, 10, 10, 10, 10, 10, 10, 10, 10, 10,
- 10, 10, 10, 10, 10, 10, 10, 10, 10, 10,
- 10, 10, 10, 10, 10, 10, 10, 10, 10, 10,
- 10, 10, 10, 10, 10, 10, 10, 10, 10, 10,
- 10, 10, 10, 10, 10, 10, 10, 10, 10, 10,
- 10, 10, 10, 10, 10, 10, 10, 10, 10, 10,
- 10, 10, 10, 10, 10, 10, 10, 10, 10, 10,
- 10, 10, 10, 10, 10, 10, 10, 10, 10, 10,
- 10, 10, 10, 10, 10, 10, 10, 10, 10, 10};
+ 4, 4, 4, 7, 7, 7, 6, 8, 8, 8, // 9
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, // 19
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, // 29
+ 4, -1, -1, -1, -1, -1, -1, -1, -1, -1, // 39
+ -1, -1, -1, -1, -1, -1, -1, -1, 9, 9, // 49
+ 9, 9, 9, 9, -1, -1, -1, -1, -1, -1, // 59
+ 4, -1, 5, 5, 5, 5, -1, -1, -1, -1, // 69
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, // 79
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, // 89
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, // 99
+ 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, //109
+ 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, //119
+ 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, //129
+ 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, //139
+ 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, //149
+ 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, //159
+ 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, //169
+ 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, //179
+ 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, //189
+ 10, 10, 10, 10, 10, 10, 10, 10, 10, 10};//199
/*
Index: emc/rs274ngc/interp_check.cc
===================================================================
RCS file: /cvs/emc2/src/emc/rs274ngc/interp_check.cc,v
retrieving revision 1.9
diff -u -p -r1.9 interp_check.cc
--- emc/rs274ngc/interp_check.cc 3 Aug 2006 19:17:07 -0000 1.9
+++ emc/rs274ngc/interp_check.cc 4 Nov 2006 23:26:11 -0000
@@ -299,6 +299,10 @@ int Interp::check_other_codes(block_poin
(block->m_modes[5] != 63) &&
(block->m_modes[5] != 64) &&
(block->m_modes[5] != 65) &&
+ (block->m_modes[9] != 50) &&
+ (block->m_modes[9] != 51) &&
+ (block->m_modes[9] != 52) &&
+ (block->m_modes[9] != 53) &&
(block->user_m != 1) &&
(motion != G_82) && (motion != G_86) &&
(motion != G_88) && (motion != G_89) && (motion != G_76)),
Index: emc/rs274ngc/interp_convert.cc
===================================================================
RCS file: /cvs/emc2/src/emc/rs274ngc/interp_convert.cc,v
retrieving revision 1.45
diff -u -p -r1.45 interp_convert.cc
--- emc/rs274ngc/interp_convert.cc 3 Nov 2006 17:04:40 -0000 1.45
+++ emc/rs274ngc/interp_convert.cc 4 Nov 2006 23:26:15 -0000
@@ -924,34 +924,6 @@ int Interp::convert_control_mode(int g_c
return INTERP_OK;
}
-/*
-
-Called by: convert_g.
-
-For G50 & G51, the canon functions START_ADAPTIVE_FEED() and
-STOP_ADAPTIVE_FEED() are called. These enable a second feed override
-control based on an external input (this second override goes from
-0 to 1 and corresponds to 0..100%). It gets multiplied with the
-user feed override. This is useful for EDM machines for example.
-
-*/
-
-int Interp::convert_adaptive_mode(int g_code, setup_pointer settings)
-{
- static char name[] = "convert_adaptive_mode";
-
- if(g_code == G_50) {
- START_ADAPTIVE_FEED();
- settings->adaptive_feed=1;
- } else if (g_code == G_51) {
- STOP_ADAPTIVE_FEED();
- settings->adaptive_feed=0;
- } else
- ERM(NCE_BUG_CODE_NOT_G50_OR_G51);
-
- return INTERP_OK;
-}
-
/****************************************************************************/
/*! convert_coordinate_system
@@ -1493,9 +1465,6 @@ int Interp::convert_g(block_pointer bloc
if (block->g_modes[13] != -1) {
CHP(convert_control_mode(block->g_modes[13], block->p_number, settings));
}
- if (block->g_modes[14] != -1) {
- CHP(convert_adaptive_mode(block->g_modes[14], settings));
- }
if (block->g_modes[3] != -1) {
CHP(convert_distance_mode(block->g_modes[3], settings));
}
@@ -1774,6 +1743,47 @@ int Interp::convert_m(block_pointer bloc
settings->feed_override = OFF;
settings->speed_override = OFF;
}
+
+ if (block->m_modes[9] == 50) {
+ if (block->p_number != 0) {
+ ENABLE_FEED_OVERRIDE();
+ settings->feed_override = ON;
+ } else {
+ DISABLE_FEED_OVERRIDE();
+ settings->feed_override = OFF;
+ }
+ }
+
+ if (block->m_modes[9] == 51) {
+ if (block->p_number != 0) {
+ ENABLE_SPEED_OVERRIDE();
+ settings->speed_override = ON;
+ } else {
+ DISABLE_SPEED_OVERRIDE();
+ settings->speed_override = OFF;
+ }
+ }
+
+ if (block->m_modes[9] == 52) {
+ if (block->p_number != 0) {
+ ENABLE_ADAPTIVE_FEED();
+ settings->adaptive_feed = ON;
+ } else {
+ DISABLE_ADAPTIVE_FEED();
+ settings->adaptive_feed = OFF;
+ }
+ }
+
+ if (block->m_modes[9] == 53) {
+ if (block->p_number != 0) {
+ ENABLE_FEED_HOLD();
+ settings->feed_hold = ON;
+ } else {
+ DISABLE_FEED_HOLD();
+ settings->feed_hold = OFF;
+ }
+ }
+
/* user-defined M codes */
if (block->m_modes[10] != -1) {
int index = block->m_modes[10];
Index: emc/rs274ngc/interp_internal.hh
===================================================================
RCS file: /cvs/emc2/src/emc/rs274ngc/interp_internal.hh,v
retrieving revision 1.16
diff -u -p -r1.16 interp_internal.hh
--- emc/rs274ngc/interp_internal.hh 24 Oct 2006 20:04:35 -0000 1.16
+++ emc/rs274ngc/interp_internal.hh 4 Nov 2006 23:26:15 -0000
@@ -376,7 +376,8 @@ typedef struct setup_struct
context sub_context[INTERP_SUB_ROUTINE_LEVELS];
int oword_labels;
offset oword_offset[INTERP_OWORD_LABELS];
- int adaptive_feed; // adaptive feed is enabled
+ ON_OFF adaptive_feed; // adaptive feed is enabled
+ ON_OFF feed_hold; // feed hold is enabled
}
setup;
Index: emc/rs274ngc/interp_write.cc
===================================================================
RCS file: /cvs/emc2/src/emc/rs274ngc/interp_write.cc,v
retrieving revision 1.9
diff -u -p -r1.9 interp_write.cc
--- emc/rs274ngc/interp_write.cc 25 Jun 2006 19:23:52 -0000 1.9
+++ emc/rs274ngc/interp_write.cc 4 Nov 2006 23:26:15 -0000
@@ -98,7 +98,6 @@ int Interp::write_g_codes(block_pointer
gez[11] =
(settings->control_mode == CANON_CONTINUOUS) ? G_64 :
(settings->control_mode == CANON_EXACT_PATH) ? G_61 : G_61_1;
- gez[12] = (settings->adaptive_feed != 0) ? G_50 : G_51;
return INTERP_OK;
}
@@ -137,8 +136,18 @@ int Interp::write_m_codes(block_pointer
(settings->mist == ON) ? 7 : (settings->flood == ON) ? -1 : 9;
emz[5] = /* 5 flood */
(settings->flood == ON) ? 8 : -1;
- emz[6] = /* 6 overrides */
- (settings->feed_override == ON) ? 48 : 49;
+ if (settings->feed_override == ON) {
+ if (settings->speed_override == ON) emz[6] = 48;
+ else emz[6] = 50;
+ } else if (settings->speed_override == ON) {
+ emz[6] = 51;
+ } else emz[6] = 49;
+
+ emz[7] = /* 7 overrides */
+ (settings->adaptive_feed == ON) ? 52 : -1;
+
+ emz[8] = /* 8 overrides */
+ (settings->feed_hold == ON) ? 53 : -1;
return INTERP_OK;
}
Index: emc/rs274ngc/rs274ngc_errors.cc
===================================================================
RCS file: /cvs/emc2/src/emc/rs274ngc/rs274ngc_errors.cc,v
retrieving revision 1.17
diff -u -p -r1.17 rs274ngc_errors.cc
--- emc/rs274ngc/rs274ngc_errors.cc 31 Jul 2006 02:59:34 -0000 1.17
+++ emc/rs274ngc/rs274ngc_errors.cc 4 Nov 2006 23:26:16 -0000
@@ -241,14 +241,13 @@ char * _rs274ngc_errors[] = {
/* 213 */ _("Return outside of subroutine"), // convert control functions
/* 214 */ _("File not open"), // control back to
/* 215 */ _("Need tool prepared -Txx- for toolchange"), // if M6 is issued without Txx
-/* 216 */ _("Bug code not g50 or g51"), // convert_adaptive_mode
-/* 217 */ _("Cannot change planes with cutter radius compensation on"),
-/* 218 */ _("Cutter radius compensation allowed only in XY, XZ planes"),
+/* 216 */ _("Cannot change planes with cutter radius compensation on"),
+/* 217 */ _("Cutter radius compensation allowed only in XY, XZ planes"),
-/* 219 */ _("P word missing with G76"),
-/* 220 */ _("I J or K words missing with G76"),
-/* 221 */ _("Cannot move rotary axes with G76"),
+/* 218 */ _("P word missing with G76"),
+/* 219 */ _("I J or K words missing with G76"),
+/* 220 */ _("Cannot move rotary axes with G76"),
-/* 222 */ _("Unknown error"), // dummy
+/* 221 */ _("Unknown error"), // dummy
_("The End")};
// *INDENT-ON*
Index: emc/rs274ngc/rs274ngc_pre.cc
===================================================================
RCS file: /cvs/emc2/src/emc/rs274ngc/rs274ngc_pre.cc,v
retrieving revision 1.29
diff -u -p -r1.29 rs274ngc_pre.cc
--- emc/rs274ngc/rs274ngc_pre.cc 3 Jul 2006 20:03:12 -0000 1.29
+++ emc/rs274ngc/rs274ngc_pre.cc 4 Nov 2006 23:26:17 -0000
@@ -381,6 +381,8 @@ int Interp::init()
//_setup.tool_table set in Interp::synch
_setup.tool_table_index = 1;
//_setup.traverse_rate set in Interp::synch
+ _setup.adaptive_feed = 0;
+ _setup.feed_hold = ON; //enable feed hold
write_g_codes((block_pointer) NULL, &_setup);
write_m_codes((block_pointer) NULL, &_setup);
@@ -391,7 +393,6 @@ int Interp::init()
_setup.defining_sub = 0;
_setup.skipping_o = 0;
_setup.oword_labels = 0;
- _setup.adaptive_feed = 0;
// Synch rest of settings to external world
synch();
Index: emc/rs274ngc/rs274ngc_return.hh
===================================================================
RCS file: /cvs/emc2/src/emc/rs274ngc/rs274ngc_return.hh,v
retrieving revision 1.16
diff -u -p -r1.16 rs274ngc_return.hh
--- emc/rs274ngc/rs274ngc_return.hh 31 Jul 2006 02:59:34 -0000 1.16
+++ emc/rs274ngc/rs274ngc_return.hh 4 Nov 2006 23:26:18 -0000
@@ -232,14 +232,13 @@
#define NCE_RETURN_OUTSIDE_OF_SUBROUTINE 213
#define NCE_FILE_NOT_OPEN 214
#define NCE_TXX_MISSING_FOR_M6 215
-#define NCE_BUG_CODE_NOT_G50_OR_G51 216
-#define NCE_CANNOT_CHANGE_PLANES_WITH_CUTTER_RADIUS_COMP_ON 217
-#define NCE_RADIUS_COMP_ONLY_IN_XY_OR_XZ 218
+#define NCE_CANNOT_CHANGE_PLANES_WITH_CUTTER_RADIUS_COMP_ON 216
+#define NCE_RADIUS_COMP_ONLY_IN_XY_OR_XZ 217
-#define NCE_P_WORD_MISSING_WITH_G76 219
-#define NCE_I_J_OR_K_WORDS_MISSING_WITH_G76 220
-#define NCE_CANNOT_MOVE_ROTARY_AXES_WITH_G76 221
+#define NCE_P_WORD_MISSING_WITH_G76 218
+#define NCE_I_J_OR_K_WORDS_MISSING_WITH_G76 219
+#define NCE_CANNOT_MOVE_ROTARY_AXES_WITH_G76 220
-#define RS274NGC_MAX_ERROR 222
+#define RS274NGC_MAX_ERROR 221
#endif /* RS274NGC_RETURN_H */
Index: emc/task/emccanon.cc
===================================================================
RCS file: /cvs/emc2/src/emc/task/emccanon.cc,v
retrieving revision 1.71
diff -u -p -r1.71 emccanon.cc
--- emc/task/emccanon.cc 24 Oct 2006 20:04:36 -0000 1.71
+++ emc/task/emccanon.cc 4 Nov 2006 23:26:20 -0000
@@ -745,21 +745,6 @@ void STOP_CUTTER_RADIUS_COMPENSATION()
// nothing need be done here
}
-void START_ADAPTIVE_FEED()
-{
- flush_segments();
- EMC_MOTION_ADAPTIVE emcmotAdaptiveMsg;
- emcmotAdaptiveMsg.status = 1;
- interp_list.append(emcmotAdaptiveMsg);
-}
-
-void STOP_ADAPTIVE_FEED()
-{
- flush_segments();
- EMC_MOTION_ADAPTIVE emcmotAdaptiveMsg;
- emcmotAdaptiveMsg.status = 0;
- interp_list.append(emcmotAdaptiveMsg);
-}
void START_SPEED_FEED_SYNCH(double sync)
@@ -1343,35 +1328,69 @@ void COMMENT(char *comment)
// refers to feed rate
void DISABLE_FEED_OVERRIDE()
{
- EMC_TRAJ_SET_FEED_OVERRIDE set_feed_override_msg;
+ EMC_TRAJ_SET_FO_ENABLE set_fo_enable_msg;
+
+ set_fo_enable_msg.mode = 0;
+ interp_list.append(set_fo_enable_msg);
+}
+
+void ENABLE_FEED_OVERRIDE()
+{
+ EMC_TRAJ_SET_FO_ENABLE set_fo_enable_msg;
- set_feed_override_msg.mode = 0;
- interp_list.append(set_feed_override_msg);
+ set_fo_enable_msg.mode = 1;
+ interp_list.append(set_fo_enable_msg);
+}
+
+//refers to adaptive feed override (HAL input, usefull for EDM for example)
+void DISABLE_ADAPTIVE_FEED()
+{
+ flush_segments();
+ EMC_MOTION_ADAPTIVE emcmotAdaptiveMsg;
+ emcmotAdaptiveMsg.status = 0;
+ interp_list.append(emcmotAdaptiveMsg);
+}
+
+void ENABLE_ADAPTIVE_FEED()
+{
+ flush_segments();
+ EMC_MOTION_ADAPTIVE emcmotAdaptiveMsg;
+ emcmotAdaptiveMsg.status = 1;
+ interp_list.append(emcmotAdaptiveMsg);
}
//refers to spindle speed
void DISABLE_SPEED_OVERRIDE()
{
- EMC_TRAJ_SET_SPINDLE_OVERRIDE set_spindle_override_msg;
+ EMC_TRAJ_SET_SO_ENABLE set_so_enable_msg;
- set_spindle_override_msg.mode = 0;
- interp_list.append(set_spindle_override_msg);
+ set_so_enable_msg.mode = 0;
+ interp_list.append(set_so_enable_msg);
}
-void ENABLE_FEED_OVERRIDE()
+
+void ENABLE_SPEED_OVERRIDE()
{
- EMC_TRAJ_SET_FEED_OVERRIDE set_feed_override_msg;
+ EMC_TRAJ_SET_SO_ENABLE set_so_enable_msg;
- set_feed_override_msg.mode = 1;
- interp_list.append(set_feed_override_msg);
+ set_so_enable_msg.mode = 1;
+ interp_list.append(set_so_enable_msg);
}
-void ENABLE_SPEED_OVERRIDE()
+void ENABLE_FEED_HOLD()
+{
+ EMC_TRAJ_SET_FH_ENABLE set_feed_hold_msg;
+
+ set_feed_hold_msg.mode = 1;
+ interp_list.append(set_feed_hold_msg);
+}
+
+void DISABLE_FEED_HOLD()
{
- EMC_TRAJ_SET_SPINDLE_OVERRIDE set_spindle_override_msg;
+ EMC_TRAJ_SET_FH_ENABLE set_feed_hold_msg;
- set_spindle_override_msg.mode = 1;
- interp_list.append(set_spindle_override_msg);
+ set_feed_hold_msg.mode = 0;
+ interp_list.append(set_feed_hold_msg);
}
void FLOOD_OFF()
Index: emc/task/emctaskmain.cc
===================================================================
RCS file: /cvs/emc2/src/emc/task/emctaskmain.cc,v
retrieving revision 1.75
diff -u -p -r1.75 emctaskmain.cc
--- emc/task/emctaskmain.cc 24 Oct 2006 20:04:36 -0000 1.75
+++ emc/task/emctaskmain.cc 4 Nov 2006 23:26:22 -0000
@@ -317,9 +317,7 @@ static EMC_AXIS_LOAD_COMP *axis_load_com
//static EMC_AXIS_SET_STEP_PARAMS *set_step_params_msg;
static EMC_TRAJ_SET_SCALE *emcTrajSetScaleMsg;
-static EMC_TRAJ_SET_FEED_OVERRIDE *emcTrajSetFeedOverrideMsg;
static EMC_TRAJ_SET_SPINDLE_SCALE *emcTrajSetSpindleScaleMsg;
-static EMC_TRAJ_SET_SPINDLE_OVERRIDE *emcTrajSetSpindleOverrideMsg;
static EMC_TRAJ_SET_VELOCITY *emcTrajSetVelocityMsg;
static EMC_TRAJ_SET_ACCELERATION *emcTrajSetAccelerationMsg;
static EMC_TRAJ_LINEAR_MOVE *emcTrajLinearMoveMsg;
@@ -532,8 +530,9 @@ static int emcTaskPlan(void)
case EMC_AXIS_SET_STEP_PARAMS_TYPE:
case EMC_TRAJ_SET_SCALE_TYPE:
case EMC_TRAJ_SET_SPINDLE_SCALE_TYPE:
- case EMC_TRAJ_SET_FEED_OVERRIDE_TYPE:
- case EMC_TRAJ_SET_SPINDLE_OVERRIDE_TYPE:
+ case EMC_TRAJ_SET_FO_ENABLE_TYPE:
+ case EMC_TRAJ_SET_FH_ENABLE_TYPE:
+ case EMC_TRAJ_SET_SO_ENABLE_TYPE:
case EMC_TRAJ_SET_VELOCITY_TYPE:
case EMC_TRAJ_SET_ACCELERATION_TYPE:
case EMC_TASK_INIT_TYPE:
@@ -635,8 +634,9 @@ static int emcTaskPlan(void)
case EMC_TRAJ_ABORT_TYPE:
case EMC_TRAJ_SET_SCALE_TYPE:
case EMC_TRAJ_SET_SPINDLE_SCALE_TYPE:
- case EMC_TRAJ_SET_FEED_OVERRIDE_TYPE:
- case EMC_TRAJ_SET_SPINDLE_OVERRIDE_TYPE:
+ case EMC_TRAJ_SET_FO_ENABLE_TYPE:
+ case EMC_TRAJ_SET_FH_ENABLE_TYPE:
+ case EMC_TRAJ_SET_SO_ENABLE_TYPE:
case EMC_SPINDLE_ON_TYPE:
case EMC_SPINDLE_OFF_TYPE:
case EMC_SPINDLE_BRAKE_RELEASE_TYPE:
@@ -725,8 +725,9 @@ static int emcTaskPlan(void)
case EMC_TRAJ_ABORT_TYPE:
case EMC_TRAJ_SET_SCALE_TYPE:
case EMC_TRAJ_SET_SPINDLE_SCALE_TYPE:
- case EMC_TRAJ_SET_FEED_OVERRIDE_TYPE:
- case EMC_TRAJ_SET_SPINDLE_OVERRIDE_TYPE:
+ case EMC_TRAJ_SET_FO_ENABLE_TYPE:
+ case EMC_TRAJ_SET_FH_ENABLE_TYPE:
+ case EMC_TRAJ_SET_SO_ENABLE_TYPE:
case EMC_SPINDLE_ON_TYPE:
case EMC_SPINDLE_OFF_TYPE:
case EMC_SPINDLE_BRAKE_RELEASE_TYPE:
@@ -818,8 +819,9 @@ static int emcTaskPlan(void)
case EMC_TRAJ_ABORT_TYPE:
case EMC_TRAJ_SET_SCALE_TYPE:
case EMC_TRAJ_SET_SPINDLE_SCALE_TYPE:
- case EMC_TRAJ_SET_FEED_OVERRIDE_TYPE:
- case EMC_TRAJ_SET_SPINDLE_OVERRIDE_TYPE:
+ case EMC_TRAJ_SET_FO_ENABLE_TYPE:
+ case EMC_TRAJ_SET_FH_ENABLE_TYPE:
+ case EMC_TRAJ_SET_SO_ENABLE_TYPE:
case EMC_SPINDLE_INCREASE_TYPE:
case EMC_SPINDLE_DECREASE_TYPE:
case EMC_SPINDLE_CONSTANT_TYPE:
@@ -1006,8 +1008,9 @@ interpret_again:
case EMC_TRAJ_ABORT_TYPE:
case EMC_TRAJ_SET_SCALE_TYPE:
case EMC_TRAJ_SET_SPINDLE_SCALE_TYPE:
- case EMC_TRAJ_SET_FEED_OVERRIDE_TYPE:
- case EMC_TRAJ_SET_SPINDLE_OVERRIDE_TYPE:
+ case EMC_TRAJ_SET_FO_ENABLE_TYPE:
+ case EMC_TRAJ_SET_FH_ENABLE_TYPE:
+ case EMC_TRAJ_SET_SO_ENABLE_TYPE:
case EMC_SPINDLE_ON_TYPE:
case EMC_SPINDLE_OFF_TYPE:
case EMC_SPINDLE_BRAKE_RELEASE_TYPE:
@@ -1080,8 +1083,9 @@ interpret_again:
case EMC_TRAJ_ABORT_TYPE:
case EMC_TRAJ_SET_SCALE_TYPE:
case EMC_TRAJ_SET_SPINDLE_SCALE_TYPE:
- case EMC_TRAJ_SET_FEED_OVERRIDE_TYPE:
- case EMC_TRAJ_SET_SPINDLE_OVERRIDE_TYPE:
+ case EMC_TRAJ_SET_FO_ENABLE_TYPE:
+ case EMC_TRAJ_SET_FH_ENABLE_TYPE:
+ case EMC_TRAJ_SET_SO_ENABLE_TYPE:
case EMC_SPINDLE_INCREASE_TYPE:
case EMC_SPINDLE_DECREASE_TYPE:
case EMC_SPINDLE_CONSTANT_TYPE:
@@ -1173,8 +1177,9 @@ interpret_again:
case EMC_AXIS_SET_STEP_PARAMS_TYPE:
case EMC_TRAJ_SET_SCALE_TYPE:
case EMC_TRAJ_SET_SPINDLE_SCALE_TYPE:
- case EMC_TRAJ_SET_FEED_OVERRIDE_TYPE:
- case EMC_TRAJ_SET_SPINDLE_OVERRIDE_TYPE:
+ case EMC_TRAJ_SET_FO_ENABLE_TYPE:
+ case EMC_TRAJ_SET_FH_ENABLE_TYPE:
+ case EMC_TRAJ_SET_SO_ENABLE_TYPE:
case EMC_SPINDLE_ON_TYPE:
case EMC_SPINDLE_OFF_TYPE:
case EMC_SPINDLE_BRAKE_RELEASE_TYPE:
@@ -1278,8 +1283,9 @@ static int emcTaskCheckPreconditions(NML
case EMC_TRAJ_SET_ACCELERATION_TYPE:
case EMC_TRAJ_SET_TERM_COND_TYPE:
case EMC_TRAJ_SET_SPINDLESYNC_TYPE:
- case EMC_TRAJ_SET_FEED_OVERRIDE_TYPE:
- case EMC_TRAJ_SET_SPINDLE_OVERRIDE_TYPE:
+ case EMC_TRAJ_SET_FO_ENABLE_TYPE:
+ case EMC_TRAJ_SET_FH_ENABLE_TYPE:
+ case EMC_TRAJ_SET_SO_ENABLE_TYPE:
return EMC_TASK_EXEC_WAITING_FOR_IO;
break;
@@ -1529,14 +1535,16 @@ static int emcTaskIssueCommand(NMLmsg *
retval = emcTrajSetSpindleScale(emcTrajSetSpindleScaleMsg->scale);
break;
- case EMC_TRAJ_SET_FEED_OVERRIDE_TYPE:
- emcTrajSetFeedOverrideMsg = (EMC_TRAJ_SET_FEED_OVERRIDE *) cmd;
- retval = emcTrajSetFeedOverride(emcTrajSetFeedOverrideMsg->mode);
+ case EMC_TRAJ_SET_FO_ENABLE_TYPE:
+ retval = emcTrajSetFOEnable(((EMC_TRAJ_SET_FO_ENABLE *) cmd)->mode); // feed override enable/disable
break;
- case EMC_TRAJ_SET_SPINDLE_OVERRIDE_TYPE:
- emcTrajSetSpindleOverrideMsg = (EMC_TRAJ_SET_SPINDLE_OVERRIDE *) cmd;
- retval = emcTrajSetSpindleOverride(emcTrajSetSpindleOverrideMsg->mode);
+ case EMC_TRAJ_SET_FH_ENABLE_TYPE:
+ retval = emcTrajSetFHEnable(((EMC_TRAJ_SET_FH_ENABLE *) cmd)->mode); //feed hold enable/disable
+ break;
+
+ case EMC_TRAJ_SET_SO_ENABLE_TYPE:
+ retval = emcTrajSetSOEnable(((EMC_TRAJ_SET_SO_ENABLE *) cmd)->mode); //spindle speed override enable/disable
break;
case EMC_TRAJ_SET_VELOCITY_TYPE:
@@ -1652,7 +1660,7 @@ static int emcTaskIssueCommand(NMLmsg *
break;
case EMC_MOTION_ADAPTIVE_TYPE:
- retval = emcTrajSetAdaptiveFeed(((EMC_MOTION_ADAPTIVE *) cmd)->status);
+ retval = emcTrajSetAFEnable(((EMC_MOTION_ADAPTIVE *) cmd)->status);
break;
case EMC_SET_DEBUG_TYPE:
@@ -2027,8 +2035,9 @@ static int emcTaskCheckPostconditions(NM
case EMC_TRAJ_CLEAR_PROBE_TRIPPED_FLAG_TYPE:
case EMC_TRAJ_SET_TELEOP_ENABLE_TYPE:
case EMC_TRAJ_SET_TELEOP_VECTOR_TYPE:
- case EMC_TRAJ_SET_FEED_OVERRIDE_TYPE:
- case EMC_TRAJ_SET_SPINDLE_OVERRIDE_TYPE:
+ case EMC_TRAJ_SET_FO_ENABLE_TYPE:
+ case EMC_TRAJ_SET_FH_ENABLE_TYPE:
+ case EMC_TRAJ_SET_SO_ENABLE_TYPE:
return EMC_TASK_EXEC_DONE;
break;
Index: emc/task/taskintf.cc
===================================================================
RCS file: /cvs/emc2/src/emc/task/taskintf.cc,v
retrieving revision 1.57
diff -u -p -r1.57 taskintf.cc
--- emc/task/taskintf.cc 16 Oct 2006 22:23:09 -0000 1.57
+++ emc/task/taskintf.cc 4 Nov 2006 23:26:23 -0000
@@ -776,25 +776,33 @@ int emcTrajSetSpindleScale(double scale)
return usrmotWriteEmcmotCommand(&emcmotCommand);
}
-int emcTrajSetFeedOverride(unsigned char mode)
+int emcTrajSetFOEnable(unsigned char mode)
{
- emcmotCommand.command = EMCMOT_FEED_OVERRIDE;
+ emcmotCommand.command = EMCMOT_FO_ENABLE;
emcmotCommand.mode = mode;
return usrmotWriteEmcmotCommand(&emcmotCommand);
}
-int emcTrajSetSpindleOverride(unsigned char mode)
+int emcTrajSetFHEnable(unsigned char mode)
{
- emcmotCommand.command = EMCMOT_SPINDLE_OVERRIDE;
+ emcmotCommand.command = EMCMOT_FH_ENABLE;
emcmotCommand.mode = mode;
return usrmotWriteEmcmotCommand(&emcmotCommand);
}
-int emcTrajSetAdaptiveFeed(unsigned char enable)
+int emcTrajSetSOEnable(unsigned char mode)
{
- emcmotCommand.command = EMCMOT_ADAPTIVE_FEED;
+ emcmotCommand.command = EMCMOT_SO_ENABLE;
+ emcmotCommand.mode = mode;
+
+ return usrmotWriteEmcmotCommand(&emcmotCommand);
+}
+
+int emcTrajSetAFEnable(unsigned char enable)
+{
+ emcmotCommand.command = EMCMOT_AF_ENABLE;
if ( enable ) {
emcmotCommand.flags = 1;