Servo controller with Traxxas XL-5

I need help getting XL-5 to work with Serial Controller. Have had it working with other vendor’s servo controller. The module is good. It will power up with the other module. Have written 2D servo software control software. Works with Futaba servo, have been working with servo controllers for three years. Was hunting servo controller that could be reset from computer, has anyone built this combination before?

XL-5 will not power on and stay operational. Have changed out battery configuration. Used similar configuration with other product but still no go. Any one have any ideas?

Very odd, I’ve had no problems using the Pololu micro serial servo controller with a Novak Super Rooster ESC (different brand, but a similar speed controller to your XL-5, and quite powerful, but I wasn’t pushing it anywhere near it’s full potential). Sounds like a power or noise problem, especially since your servo works just fine with it.

Which of the Pololu servo controllers are you using?

Can you describe the failure behavior? For example, does it work fine at low speeds then stop working when you try to drive a motor faster, or under a higher load? What if you connect the XL-5 to a very small, low-power motor instead?

When you say you changed the battery configuration, what power connections have you tried, and what battery pack are you using?

And out of curiosity, what was the other vendor’s servo controller that this all worked with?

Sorry to answer with more questions, I know how frustrating it is when something simple should just work, but doesn’t.

On the separate matter of resetting the servo controller from your computer, I don’t know of any servo controllers that have a completely straightforward way to do this, but if you’re up for a little more soldering and programming you could hook up one of the unused serial handshaking lines, DTR or RTS (from your computer’s point of view), to the reset pin of your servo controller through a transistor for level shifting and possibly inverting the voltage. Alternatively, this would be really easy to do with a USB to Serial Adapter.

-Adam

I found the problem.

The VB4 program I wrote did not set the BCD length properly. I wrote a C++ program that listed the BCD return codes properly.

I am running the robot on B-Wireless and I did not check the fundmentals. You have to set the DCB structure length properly so that the structure is properly init’d. I went back to basics and found that the error. Below is code that I hope will help others save the 90 days that I lost hunting a coding error.

Adam


/*******************************************************************/
/*                                                                 */
/*                                                                 */
/*                                                                 */
/*******************************************************************/
#include <stdio.h>
#include <windows.h>

DWORD hComm = 0;
HANDLE hCom = NULL;
long lSecurity = 0;
DCB dcb;
DWORD dwError;
BOOL fSuccess;


int main (int argc, char *argv[])
{

	if(argv[1] == NULL)
	{
		argv[1] = "COM2";

	}


//	'usename = "\\.\COM4"

		hCom = CreateFile(argv[1]
			, GENERIC_READ | GENERIC_WRITE
			, NULL
			, lSecurity
			, OPEN_EXISTING
			, FILE_ATTRIBUTE_NORMAL | FILE_FLAG_RANDOM_ACCESS
			, NULL);

		
		if (hCom == INVALID_HANDLE_VALUE) {
			dwError = GetLastError();
			printf("COMM Open Error %i\n",dwError);
			printf("\n");
			return(1);
		}

		fSuccess = GetCommState(hCom, &dcb);

		printf("\n");
		printf("COMM port %s\n\n",argv[1]);
		printf("========================\n");
		printf("BaudRate %i\n",dcb.BaudRate);
		printf("fBinary %i\n",dcb.fBinary);
		printf("fParity %i\n",dcb.fParity);
		printf("ByteSize %i\n",dcb.ByteSize);
		printf("Parity %i\n",dcb.Parity);
		printf("StopBits %i\n",dcb.StopBits);
		printf("\n");
		printf("fOutxCtsFlow %i\n",dcb.fOutxCtsFlow);
        printf("fOutxDsrFlow %i\n",dcb.fOutxDsrFlow);
		printf("fDtrControl %i\n",dcb.fDtrControl);
		printf("fRtsControl %i\n",dcb.fRtsControl);
		printf("\n");
		printf("fDsrSensitivity %i\n",dcb.fDsrSensitivity);
		printf("fTXContinueOnXoff %i\n",dcb.fTXContinueOnXoff);
		printf("fOutX %i\n",dcb.fOutX);
		printf("fInX %i\n",dcb.fInX);
		printf("fErrorChar %i\n",dcb.fErrorChar);
		printf("fNull %i\n",dcb.fNull);
		printf("fRtsControl %i\n",dcb.fRtsControl);
		printf("fAbortOnError %i\n",dcb.fAbortOnError);
		printf("XonLim %i\n",dcb.XonLim);
		printf("XoffLim %i\n",dcb.XoffLim);
		printf("XonChar %i\n",dcb.XonChar);
		printf("XoffChar %i\n",dcb.XoffChar);
		printf("ErrorChar %i\n",dcb.ErrorChar);
		printf("EofChar %i\n",dcb.EofChar);
		printf("EvtChar %i\n",dcb.EvtChar);
		printf("wReserved1 %i\n",dcb.wReserved1);
		printf("==================================\n");
		printf("\n");
 
		CloseHandle(hCom);


	return 0;

}