From c23811aff1dcde2fb9f2ae3679ff151243286d82 Mon Sep 17 00:00:00 2001 From: Ron Sluiter Date: Wed, 13 Jan 2010 17:38:38 +0000 Subject: [PATCH] Bug fix patch for this error message; "drvMM3000:motor_init() - invalid RC response = dc" on the last axis. --- motorApp/NewportSrc/drvMM3000.cc | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/motorApp/NewportSrc/drvMM3000.cc b/motorApp/NewportSrc/drvMM3000.cc index 198a20ad..a694c548 100644 --- a/motorApp/NewportSrc/drvMM3000.cc +++ b/motorApp/NewportSrc/drvMM3000.cc @@ -647,16 +647,16 @@ STATIC int motor_init() /* The return string will tell us how many axes this controller has */ for (total_axis = 0; bufptr != NULL; total_axis++) { - if (strcmp(bufptr, "unused") == 0) + if (strncmp(bufptr, "unused", 6) == 0) { cntrl->type[total_axis] = UNUSED; bufptr = NULL; } else { - if (strcmp(bufptr, "stepper1.5M") == 0) + if (strncmp(bufptr, "stepper1.5M",11) == 0) cntrl->type[total_axis] = STEPPER; - else if (strcmp(bufptr, "dc") == 0) + else if (strncmp(bufptr, "dc", 2) == 0) cntrl->type[total_axis] = DC; else errlogPrintf("drvMM3000:motor_init() - invalid RC response = %s\n",