Older version of visual C++?

Hello everyone,

I Just got a maestro 6 ch and some servos, I Tried the pololu application and they worked fine. However, I working in a distributed environment where we are using Visual c++ 6.0 on windows xp, So can anybody tell me what is the best option to create a simple console program to control de servos, I have checked the examples but I can not make it work since those are made for a newest version of c++.


I like Code::Blocks for program development on a PC. It is free and kept up to date.
Development of a simple console program is trivial. Try it out!


Have you tried running the command-line utility UscCmd? The UscCmd should be on your computer if you installed the Maestro Control Center and can be invoked directly from a Command Prompt (just run “usccmd” at a Command Prompt to get a help screen). For more information, see the “Writing PC Software to Control the Maestro” section in the Maestro Servo Controller User’s Guide.

- Amanda

hi, Amanda, the code of UscCmd is on C# and also has references to DLL that I not sure how to include in this older version of visual c++ (6.0). I know that is kind of awkward to use an old version of Visual C++ but the thing is I starting here and for some reason I do not know, thus people do not want to upgrade the environment. I tried call UscCmd from my c++ code and works but the response is slow.

i found a thread about libusb in the forum, but for a console application I think that I might use the windows libraries instead to make it easy, as a first step I just want to send the position of one servo, then I can extend the code to move 5 or 6 in different sequences according other sensors. any other suggestion?

Each time you run UscCmd, there is overhead from using the .NET framework and from initializing the USB communication.

Our USB SDK examples use .NET so they are not going to be easily transferable to Visual C++ 6.0. While it is probably possible to use low-level Windows APIs (SetupAPI and WinUSB) to communicate via the Maestro’s native USB interface, it is probably going to be difficult. Another approach you could consider is using the virtual COM port and the Maestro serial protocol. You can try starting with the code in MaestroSerialExampleCWindows.zip in the “Windows C” section of the Maestro User’s Guide, but it might use functions that are not available in Visual C++ 6.0.

- Amanda

Hi, Amanda I used the C code as you mention before and worked well for one servo, now I’m trying to move 4 servos at the same time but when I set the target all the servos move like they are trembling and never reach the final position.

I have used the pololu control center to check this behavior, and if i have active the 4 servos and manually move one with the slider some times this makes other servos to move also. sometimes is just a small movement but other times is like the tremble again.

Any suggestion?

It sounds like a power issue. What are you using to power your servos? I suspect your power supply is not able to source enough current for all four servos in your setup. As a general rule, your power supply should be able to handle at least 1 A for each standard size servo you have connected.

- Amanda

ok, I will change it and check it. Thanks again.