BotBoarduino+SSC32U

Hi,
I have a problem with BotBoarduino and SSC32U. After I have recharged 6V battery of the SSC32U shield (logic and servo power), the servos move around their range altough I have setted a park position to the servos by BotBoarduino. I have read this in letsmakerobots.com/node/46686:

In order to help more, we would need to see your code. A simple serial command sent to the SSC-32U would look like Serial.print("#1P1500");
Note that you need to also have the correct baud rate set on the SSC-32U which would be the same as what you set in the Arduino configuration void setup()

Thanks for your reply. This is my code to set servos:

//Serial to control arm
int rxPin = 4;
int txPin = 2;
SoftwareSerial armSerial(rxPin, txPin); //arm uses pins 2 for TX and 4 for RX
//Arm park position
int parkPos[MAX_ARM_SERVO];
/* Servo names/numbers */
/* Base servo HS-485HB */
#define BAS_SERVO 0
/* Shoulder Servo HS-5745-MG */
#define SHL_SERVO 1
/* Elbow Servo HS-5745-MG */
#define ELB_SERVO 2
/* Wrist servo HS-645MG */
#define WRI_SERVO 3
/* Wrist rotate servo HS-485HB */
#define WRO_SERVO 4
/* Gripper servo HS-422 */
#define GRI_SERVO 5
#define ARM_SERVO_SPEED 500
#define MAX_ARM_SERVO 6
//Set bounds for each servo
int setBounds(int servo, int minPos, int maxPos) {
  if (servo >= 0 && servo < MAX_ARM_SERVO) {
    servoMaxPos[servo] = maxPos;
    servoMinPos[servo] = minPos;

    return 0;
  }
  return 1;
}
//Set parking position
void setParkPos() {
  parkPos[0] = 1440;
  parkPos[1] = 1900;
  parkPos[2] = 2400;
  parkPos[3] = 1775;
  parkPos[4] = 1500;
  parkPos[5] = 1500;
}
void armPark() {
  String command = "";
  for (int i = 0; i < MAX_ARM_SERVO - 1; i++) {
    command = "";
    command += "#";
    command += i;
    command += "P";
    command += parkPos*;
    command += "S";
    command += ARM_SERVO_SPEED;
    armSerial.println(command);
  }
}

void armSetup() {
  pinMode(rxPin, INPUT);
  pinMode(txPin, OUTPUT);
  armSerial.begin(115200);
  setBounds( BAS_SERVO, 900, 2100 );
  setBounds( SHL_SERVO, 700, 2300 );
  setBounds( ELB_SERVO, 900, 2400 );
  setBounds( WRI_SERVO, 600, 2400 );
  setBounds( WRO_SERVO, 600, 2400 );
  setBounds( GRI_SERVO, 600, 2400 );
  setParkPos();
  armPark();
  Serial.println("Arm setup OK!");
}
void setup()
{
  Serial.begin( 115200 );
  Serial.println("Starting LynxMotion...");
  Serial.println("Arm setup...");
  armSetup();
  Serial.println("Ready to drive System");
}

void loop()
{
  systemDrive();
}

In systemDrive(), I read value from a server connect to BotBoarduino by Wifi shield. My issue appears when I start system after I have recharged 6V battery that power up SSC32U shield.
I hope you help me.
Regards, Stefano.*

Appreciated. Can you try a much easier setup, like just one serial command on one line just to see if the SSC-32U receives the correct command?
What is the end result of your current code? Do the servos move? Also would like to confirm you have common ground between the two boards?

The servos move when I send command from botboarduino and boards have common ground. When I recharge 6V battery (connected to VS1), servos move strangely and shake.
Thanks

Can you check the actual voltage of the 6V (fully charged) battery? It might be that it’s close to 7V and the servos cannot tolerate it. Can you include some photos of your setup?

Hi, thanks for your reply. The battery pack is a lynxmotion product (lynxmotion.com/p-426-60-volt … -pack.aspx).
When fully charged has it higher voltage than 6V?
This is my setup (I write it because I can’t send photos):

  • I have connected a 6V battery pack to SSC32U VS1 port;
  • I have connected a 12V battery pack to a Sabertooth RC servo controller that powers also BotBoarduino;
  • BotBoarduino and SSC32U are connected by a serial connection (tx,rx,gnd SSC32U pins);
    Is it right?

You can see the connections here (including optional PS2). Take note of the jumpers:

Thank you. In my configuration, I have a rover with a robot arm. How can I power sabertooth controller rc servo? I have connected 12V battery to the controller and it powers the botboarduino.

The connections for the rover / Sabertooth (you’ll need to combine both setups):

Thank you. I try to send command from LynxTerm, but the arm jerk and shake. So, I think it doesn’t a setup problem. What is it?

We’d need to see clear photos of your setup (perhaps even a video) to provide a preliminary diagnosis.

I do not know these two numbers mean 616 and 31416,help me

Unfortunately we are not in a position to teach the nuances of the Phoenix code.
We present it as functional code to make the hexapod robots work.