How to use Micro Maestro 6-Channel USB Servo Controller?

We have bought the mentioned Servo Controller and have connected it to a power source and one servo. Using the Maestro Control Center we can set the Position of the servo and the servo moves. But we do not know, how to send commands via USB from a Ubuntu System using C++.

How can we move the servo without using the Maestro Control Center?

Hello,

Please look through the User’s Guide, especially the sections on the serial interface and writing PC software to control the Maestro. Basically, you can send commands to the Maestro’s virtual serial port or use the native USB interface.

The serial port method is the easiest, but if you want to use native USB, we provide C# example code for using the USB interface that uses the libusb library to interface to the device - you could use that code basically as documentation when writing your own code to use libusb in C++, or find a way to access our C# classes from C++.

-Paul

After thinking about the Problem we found out that it is very simple to control the Micro Maestro via C++ (using the UscCmd was the great idea):

        int nr, pos;
        cin>>nr;
        cin>>pos;
	string str="/home/linux/maestro_linux/./UscCmd --servo "+doubletostr(nr)+","+doubletostr(pos);	
	system(str.c_str());

doubletostr() is defined as follows:

string doubletostr(double value)
{
	string result;
	ostringstream outstr;
	outstr<<value;
	result=outstr.str();
	return result;
}

And that works fine! So next time if anyone asks you, you can send him the few code-lines.