RoboClaw 2x5A Motor Controller - Library Issues

I have recently purchased a RoboClaw 2x5A Motor Controller and after installing the Arduino library that comes with it, I am struggling to get any code at all to compile. When trying to compile any example codes at all, I get this error message:

C:\Program Files (x86)\Arduino\libraries\RoboClaw\RoboClaw.cpp: In member function 'uint16_t RoboClaw::ReadError(uint8_t, bool*)': C:\Program Files (x86)\Arduino\libraries\RoboClaw\RoboClaw.cpp:505:7: error: declaration of 'bool valid' shadows a parameter bool valid; ^ C:\Program Files (x86)\Arduino\libraries\RoboClaw\RoboClaw.cpp:506:48: error: 'read2' was not declared in this scope uint16_t value = read2(address,GETERROR,&valid); ^ Error compiling.

Any ideas what to do?

Clearly it would help if you provided a link to the offending library...

Apologies Mark, meant to add the library but forgot.

Motor Controller -> ZIP File for Library ->

Hope this helps :)

They've released a broken lilbrary that doesn't compille - perhaps you should tell them!

Anyway its a simple fix:

In RoboClaw.cpp there is a method ReadError, which obviously write-only code (never compiled):

change this:

uint16_t RoboClaw::ReadError(uint8_t address,bool *valid){
 bool valid;
 uint16_t value = read2(address,GETERROR,&valid);
 return value;

to this:

uint16_t RoboClaw::ReadError(uint8_t address,bool *valid)
  return Read2 (address, GETERROR, valid);

Cut and paste this over the broken version...

I've already sent them an email! Thanks Mark that's great, fixed the problem completely :)

I'm now at the point of uploading code to the Arduino, but nothing seems to be making my motor turn at all. I've got everything wired up as shown in the user manual... Any suggestions? There's so little information out there about these motor controllers!

Do you mean the document called "datasheet"?

Which example? Have you checked all the connections on the block of logic inputs/jumpers make sense? Which option for 5V power have you chosen? Are the jumpers set for that choice?

Yeah that's right, and I've checked all of the connections and that its on the right settings and modes etc and it still doesn't work... I've chosen to power the controller's logic from the Arduino's 5V line with separate power for the motor. Everything seems to be set exactly how it is needed but just isn't working :(

Check again, use a multimeter, not just your eyes, eyes cannot see voltage.