Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

moveTo() does not work #1

Open
wxcvbnbvcxw opened this issue Jun 5, 2017 · 3 comments
Open

moveTo() does not work #1

wxcvbnbvcxw opened this issue Jun 5, 2017 · 3 comments

Comments

@wxcvbnbvcxw
Copy link

Hi, I just recieved my uArm Swift Pro, and would like to use it with your library. I can communicate with the board, do the debug things, but the "moveTo" function does not do anything... nothing moves... Moreover, some errors appear when compiling (conversion from string to char problems, etc... in the libraries).
Am I the only one?
Thanks,
M.

@yuntian1019
Copy link

This firmware is for uArm Swift( not Pro, or please visit: https://github.com/uArm-Developer/SwiftProForArduino), please make sure use the right version.
Please tell us the version of Arduino IDE you used, Arduino 1.6.12 or newer version is needed.

@wxcvbnbvcxw
Copy link
Author

OK, thank you,
I tried to upload Marlin.ino from SwiftProForArduino
a lot of errors when compiling, now the arm moves, but does strange noises an is very jerky.
Moreover, when sending python commands, it seems it "forgets" some instructions...
I use Arduino IDE 1.8.2 on windows 7
Thank you
M.

Here is the message from arduino IDE after compiling:
`In file included from sketch\GroveColorSensor.cpp:1:0:

sketch\GroveColorSensor.h:26:7: warning: ISO C++ forbids declaration of 'init' with no type [-fpermissive]

init();

   ^

sketch\GroveColorSensor.cpp:17:24: warning: ISO C++ forbids declaration of 'init' with no type [-fpermissive]

GroveColorSensor::init()

                    ^

sketch\uArmAPI.cpp: In function 'void getMacAddr()':

sketch\uArmAPI.cpp:101:39: warning: invalid conversion from 'unsigned char*' to 'const char*' [-fpermissive]

char *s = strstr(readBuf, "OK+ADDR:");

                                   ^

In file included from C:\Program Files (x86)\Arduino\hardware\arduino\avr\cores\arduino/Arduino.h:25:0,

             from sketch\uArmAPI.h:13,

             from sketch\uArmAPI.cpp:10:

c:\program files (x86)\arduino\hardware\tools\avr\avr\include\string.h:557:14: note: initializing argument 1 of 'char* strstr(const char*, const char*)'

extern char *strstr(const char *, const char *) ATTR_PURE;

          ^

sketch\uArmAPI.cpp:106:33: warning: invalid conversion from 'unsigned char*' to 'char*' [-fpermissive]

strncpy(mMacStr, s+8, MAC_LEN);

                             ^

In file included from C:\Program Files (x86)\Arduino\hardware\arduino\avr\cores\arduino/Arduino.h:25:0,

             from sketch\uArmAPI.h:13,

             from sketch\uArmAPI.cpp:10:

c:\program files (x86)\arduino\hardware\tools\avr\avr\include\string.h:449:14: note: initializing argument 1 of 'char* strncpy(char*, const char*, size_t)'

extern char *strncpy(char *, const char *, size_t);

          ^

sketch\uArmAPI.cpp: In function 'void init_user_mode()':

sketch\uArmAPI.cpp:258:23: warning: invalid conversion from 'uint8_t {aka unsigned char}' to 'UserMode_t' [-fpermissive]

set_acceleration(mode);

                   ^

In file included from sketch\uArmAPI.cpp:10:0:

sketch\uArmAPI.h:74:6: note: initializing argument 1 of 'void set_acceleration(UserMode_t)'

void set_acceleration(UserMode_t mode);

  ^

sketch\uArmAPI.cpp:261:12: warning: invalid conversion from 'uint8_t {aka unsigned char}' to 'UserMode_t' [-fpermissive]

user_mode = mode;

        ^

sketch\uArmAPI.cpp: In function 'bool setBtName(char*)':

sketch\uArmAPI.cpp:414:37: warning: invalid conversion from 'unsigned char*' to 'const char*' [-fpermissive]

char *s = strstr(readBuf, "OK+Set:");

                                 ^

In file included from C:\Program Files (x86)\Arduino\hardware\arduino\avr\cores\arduino/Arduino.h:25:0,

             from sketch\uArmAPI.h:13,

             from sketch\uArmAPI.cpp:10:

c:\program files (x86)\arduino\hardware\tools\avr\avr\include\string.h:557:14: note: initializing argument 1 of 'char* strstr(const char*, const char*)'

extern char *strstr(const char *, const char *) ATTR_PURE;

          ^

sketch\uArmDebug.cpp: In function 'int msprintf(char*, char*, ...)':

sketch\uArmDebug.cpp:42:24: warning: second parameter of 'va_start' not last named argument [-Wvarargs]

va_start(argv, count);

                    ^

sketch\uArmDebug.cpp: In function 'void mprint(char*, ...)':

sketch\uArmDebug.cpp:136:24: warning: second parameter of 'va_start' not last named argument [-Wvarargs]

va_start(argv, count);

                    ^

In file included from sketch\uArmGrove.cpp:11:0:

sketch\GroveColorSensor.h:26:7: warning: ISO C++ forbids declaration of 'init' with no type [-fpermissive]

init();

   ^

sketch\uArmGrove.cpp: In function 'void GestureReport()':

sketch\uArmGrove.cpp:127:87: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]

msprintf(result, "@%d N%d V%d\r\n", REPORT_TYPE_GROVE, GROVE_GESTURE_SERSOR, gesture);

                                                                                   ^

sketch\uArmGrove.cpp: In function 'void GroveColorReport()':

sketch\uArmGrove.cpp:144:101: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]

msprintf(result, "@%d N%d R%d G%d B%d\r\n", REPORT_TYPE_GROVE, GROVE_COLOR_SENSOR, red, green, blue);

                                                                                                 ^

sketch\uArmGrove.cpp: In function 'void UltrasonicReport()':

sketch\uArmGrove.cpp:156:104: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]

msprintf(result, "@%d N%d V%d\r\n", REPORT_TYPE_GROVE, GROVE_ULTRASONIC, ultrasonic.RangeInCentimeters);

                                                                                                    ^

sketch\uArmService.cpp: In member function 'void uArmService::powerDetect()':

sketch\uArmService.cpp:701:42: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]

                                      ^

sketch\uArmService.cpp: In member function 'void uArmService::tipDetect()':

sketch\uArmService.cpp:717:43: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]

}

                                       ^

sketch\uArmService.cpp: At global scope:

sketch\uArmService.cpp:29:20: warning: inline function 'void set_current_to_destination()' used but never defined

extern inline void set_current_to_destination();

                ^

sketch\uArmSwift.cpp: In function 'float get_current_height()':

sketch\uArmSwift.cpp:194:3: warning: return-statement with no value, in function returning 'float' [-fpermissive]

return ;

^

sketch\uArmSwift.cpp: In function 'void reportButtonEvent(unsigned char, unsigned char)':

sketch\uArmSwift.cpp:328:52: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]

reportString(result);

                                                ^

sketch\uArmSwift.cpp: In function 'void reportPos()':

sketch\uArmSwift.cpp:358:92: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]

                                                                                        ^

sketch\uArmSwift.cpp: In function 'uint8_t uarm_gcode_M2211(char*)':

sketch\uArmSwift.cpp:586:30: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]

break;

                          ^

sketch\uArmSwift.cpp:592:32: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]

break;

                            ^

sketch\uArmSwift.cpp:598:32: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]

break;

                            ^

sketch\uArmSwift.cpp: In function 'void uarm_gcode_M2212()':

sketch\uArmSwift.cpp:655:9: warning: return-statement with a value, in function returning 'void' [-fpermissive]

}

     ^

sketch\uArmSwift.cpp: In function 'uint8_t uarm_gcode_M2220(char*)':

sketch\uArmSwift.cpp:717:77: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]

                                                                         ^

sketch\uArmSwift.cpp: In function 'uint8_t uarm_gcode_M2221(char*)':

sketch\uArmSwift.cpp:761:76: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]

                                                                        ^

sketch\uArmSwift.cpp: In function 'void uarm_gcode_M2300()':

sketch\uArmSwift.cpp:927:22: warning: invalid conversion from 'uint8_t {aka unsigned char}' to 'GroveType' [-fpermissive]

}

                  ^

In file included from sketch\Marlin.h:60:0,

             from sketch\uArmSwift.h:14,

             from sketch\uArmSwift.cpp:10:

sketch\uArmGrove.h:27:6: note: initializing argument 1 of 'void initGroveModule(GroveType)'

void initGroveModule(GroveType type);

  ^

sketch\uArmSwift.cpp: In function 'void uarm_gcode_M2301()':

sketch\uArmSwift.cpp:953:41: warning: invalid conversion from 'uint8_t {aka unsigned char}' to 'GroveType' [-fpermissive]

}

                                     ^

In file included from sketch\Marlin.h:60:0,

             from sketch\uArmSwift.h:14,

             from sketch\uArmSwift.cpp:10:

sketch\uArmGrove.h:29:6: note: initializing argument 1 of 'void setGroveModuleReportInterval(GroveType, long int)'

void setGroveModuleReportInterval(GroveType type, long interval);

  ^

sketch\uArmSwift.cpp: In function 'void uarm_gcode_M2400()':

sketch\uArmSwift.cpp:963:21: warning: invalid conversion from 'uint8_t {aka unsigned char}' to 'UserMode_t' [-fpermissive]

update_current_pos();

                 ^

In file included from sketch\Marlin.h:48:0,

             from sketch\uArmSwift.h:14,

             from sketch\uArmSwift.cpp:10:

sketch\uArmAPI.h:69:6: note: initializing argument 1 of 'void set_user_mode(UserMode_t)'

void set_user_mode(UserMode_t mode);

  ^

sketch\uArmSwift.cpp: In function 'uint8_t uarm_gcode_P2200(char*)':

sketch\uArmSwift.cpp:1067:76: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]

                                                                        ^

sketch\uArmSwift.cpp: In function 'uint8_t uarm_gcode_P2201(char*)':

sketch\uArmSwift.cpp:1074:36: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]

                                ^

sketch\uArmSwift.cpp: In function 'uint8_t uarm_gcode_P2202(char*)':

sketch\uArmSwift.cpp:1081:53: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]

                                                 ^

sketch\uArmSwift.cpp: In function 'uint8_t uarm_gcode_P2203(char*)':

sketch\uArmSwift.cpp:1090:31: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]

                           ^

sketch\uArmSwift.cpp: In function 'uint8_t uarm_gcode_P2204(char*)':

sketch\uArmSwift.cpp:1100:31: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]

                           ^

sketch\uArmSwift.cpp: In function 'uint8_t uarm_gcode_P2205(char*)':

sketch\uArmSwift.cpp:1111:33: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]

                             ^

sketch\uArmSwift.cpp: In function 'uint8_t uarm_gcode_P2206(char*)':

sketch\uArmSwift.cpp:1136:34: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]

                              ^

sketch\uArmSwift.cpp: In function 'uint8_t uarm_gcode_P2220(char*)':

sketch\uArmSwift.cpp:1143:109: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]

                                                                                                         ^

sketch\uArmSwift.cpp: In function 'uint8_t uarm_gcode_P2221(char*)':

sketch\uArmSwift.cpp:1154:76: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]

                                                                        ^

sketch\uArmSwift.cpp: In function 'uint8_t uarm_gcode_P2231(char*)':

sketch\uArmSwift.cpp:1161:40: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]

                                    ^

sketch\uArmSwift.cpp: In function 'uint8_t uarm_gcode_P2232(char*)':

sketch\uArmSwift.cpp:1168:43: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]

                                       ^

sketch\uArmSwift.cpp: In function 'uint8_t uarm_gcode_P2233(char*)':

sketch\uArmSwift.cpp:1175:33: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]

                             ^

sketch\uArmSwift.cpp: In function 'uint8_t uarm_gcode_P2234(char*)':

sketch\uArmSwift.cpp:1182:48: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]

                                            ^

sketch\uArmSwift.cpp: In function 'uint8_t uarm_gcode_P2240(char*)':

sketch\uArmSwift.cpp:1201:43: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]

                                       ^

sketch\uArmSwift.cpp: In function 'uint8_t uarm_gcode_P2241(char*)':

sketch\uArmSwift.cpp:1219:42: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]

                                      ^

sketch\uArmSwift.cpp: In function 'uint8_t uarm_gcode_P2242(char*)':

sketch\uArmSwift.cpp:1234:61: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]

return E_OK;

                                                         ^

sketch\uArmSwift.cpp: In function 'uint8_t uarm_gcode_P2400(char*)':

sketch\uArmSwift.cpp:1249:40: warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings]`

Any idea?
Thanks

@yuntian1019
Copy link

I see. You can simply close it by click File -> Preferences , set 'Compiler warnings' to 'None', we'll fix it in the next version. Hardware problem Please fill in the Customer Feedback Form http://www.mikecrm.com/cesaXd.
Thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants