When you power on the PS2, please have the USB cable removed from the SSC-32U.
Also, the PS2 receiver looks like it’s a V1 whereas the remote is a V3. Are you certain the two came together?
Yep im sure.
Before you turn on the PS2 transmitter, please have the USB cable removed from the SSC-32U.
Two checks:
- Verify that indeed the Rx from the BBduino is going to the Tx of the SSC-32U and vice-versa
- Check that the pinout in the sample code for the PS2 corresponds to the pins used on the BBduino.
The version of the PS2 you have may not in fact need the level shifter, though it should work anyway. We’ll look into this if none of the above work.
Ok cool. I’ll get to that as soon as i can.
Just in case, would you happen to know the correct pin-out for the V1 reciever?
Ok i uploaded the firmware using the sample code you linked me to. I have the botboarduinos TX going to the SSC-32 Rx and botboarduino Rx going to the SSC-32’s Tx. Gnd to Gnd.
I also have the level shifter connected to the Botboarduino according to the sample code.
Im getting power to everything the SSC-32 has the servos calibrated using the servo sequencer.
I have turned on the Controller and then turned on the bot and then tried with the bot on first then turning on the Controller.
Still no motion. The green lights on both the controller and the RX stay flashing.
Therefore we have narrowed down that the issue is with either the remote control, the level shifter or the connections between the level shifter and the BotBoarduino
Did you check that your connections between the level shifter and the BotBoarduino match those in the sample code?
#ifdef __BOTBOARDUINO__
#define SOUND_PIN 5 // Botboarduino JR pin number
#define PS2_DAT 8
#define PS2_CMD 7
#define PS2_SEL 6 // On the PS2 receiver this pin may be called ATT (attention)
#define PS2_CLK 9
Look at the silkscreen on the level shifter and trace the wires to see that each goes to the correct pins above.
I took the RX apart and checked that everything matched my burnt out torobot RX and its right.
Heres a pic of the level shifter.
I also traced everything in the lynxmotion and everything is correct. I can try wiring up to the Botboard directly but im afraid it will blow if i hook it up to the 5v and i dont see a 3v out.
Yes everything wired matches the code.
also the RX had some kind of dry powdery crud on it when i opened it up.
Ok im one step closer and starting to get a lil excited!!!
I went ahead removed the level shifter from the RX and straight wired the controller to the board using a couple servo wires and a couple extensions. I checked the female port on the right side of the board and its pushing 2.89v instead of 3.3v but it works.
Now when i turn them on and hit a control the legs move and everything but it swept the legs back and down like in the two pics.
Here is my config
//====================================================================
//Project Lynxmotion Phoenix
//Description:
// This is the hardware configuration file for the Hex Robot.
//
// This version of the Configuration file is set up to run on the
// Lynxmotion BotboardDuino board, which is similiar to the Arduino Duemilanove
//
// This version of configuration file assumes that the servos will be controlled
// by a Lynxmotion Servo controller SSC-32 and the user is using a Lynxmotion
// PS2 to control the robot.
//
//Date: March 18, 2012
//Programmer: Kurt (aka KurtE)
//
//NEW IN V1.1 (2013-05-17)
// - Support for Arduino Pro Mini on Bot Board (originally for Basic Atom Pro)
//NEW IN V1.0
// - First Release
//
//====================================================================
//==================================================================================================================================
//==================================================================================================================================
//==================================================================================================================================
//[CONDITIONAL COMPILING] - COMMENT IF NOT WANTED
// Define other optional compnents to be included or not...
//comment if terminal monitor is not required
#define OPT_TERMINAL_MONITOR
//uncomment the board you want to use
#define __BOTBOARDUINO__ //botboarduino board
//#define __BOTBOARD_ARDUINOPROMINI__ //arduino pro mini on botboard (originally for BasicAtomPro)
//====================================================================
#ifdef OPT_TERMINAL_MONITOR // turning off terminal monitor will turn these off as well...
#define OPT_SSC_FORWARDER // only useful if terminal monitor is enabled
#define OPT_FIND_SERVO_OFFSETS // Only useful if terminal monitor is enabled
#endif
#define OPT_GPPLAYER
// Which type of control(s) do you want to compile in
#define DBGSerial Serial
#if defined(UBRR1H)
#define SSCSerial Serial1
#else
#endif
#define USEPS2
//==================================================================================================================================
//==================================================================================================================================
//==================================================================================================================================
// CHR-3
//==================================================================================================================================
#define USE_SSC32
//#define cSSC_BINARYMODE 1 // Define if your SSC-32 card supports binary mode.
//[SERIAL CONNECTIONS]
// Warning I will undefine some components as the non-megas don't have enough memory...
//#undef OPT_FIND_SERVO_OFFSETS
#define cSSC_BAUD 38400 //SSC32 BAUD rate
//--------------------------------------------------------------------
//[Botboarduino Pin Numbers]
#ifdef __BOTBOARDUINO__
#define SOUND_PIN 5 // Botboarduino JR pin number
#define PS2_DAT 8
#define PS2_CMD 7
#define PS2_SEL 6 // On the PS2 receiver this pin may be called ATT (attention)
#define PS2_CLK 9
// If we are using a SSC-32 then:
// If were are running on an Arduino Mega we will use one of the hardware serial port, default to Serial1 above.
// If on Non mega, if the IO pins are set to 0, we will overload the hardware Serial port
// Else we will user SoftwareSerial to talk to the SSC-32
#define cSSC_OUT 12 //Output pin for Botboard - Input of SSC32 (Yellow)
#define cSSC_IN 13 //Input pin for Botboard - Output of SSC32 (Blue)
#endif
#ifdef __BOTBOARD_ARDUINOPROMINI__
#define SOUND_PIN 11 // Bot Board JR pin number (with Arduino Pro Mini plugged)
#define PS2_DAT 14
#define PS2_CMD 15
#define PS2_SEL 16
#define PS2_CLK 17
// If we are using a SSC-32 then:
// If were are running on an Arduino Mega we will use one of the hardware serial port, default to Serial1 above.
// If on Non mega, if the IO pins are set to 0, we will overload the hardware Serial port
// Else we will user SoftwareSerial to talk to the SSC-32
#define cSSC_OUT 10 //Output pin for Botboard - Input of SSC32 (Yellow)
#define cSSC_IN 9 //Input pin for Botboard - Output of SSC32 (Blue)
#endif
//====================================================================
//[SSC PIN NUMBERS]
#define cRRCoxaPin 0 //Rear Right leg Hip Horizontal
#define cRRFemurPin 1 //Rear Right leg Hip Vertical
#define cRRTibiaPin 2 //Rear Right leg Knee
//#define cRRTarsPin 3 // Tar
#define cRMCoxaPin 4 //Middle Right leg Hip Horizontal
#define cRMFemurPin 5 //Middle Right leg Hip Vertical
#define cRMTibiaPin 6 //Middle Right leg Knee
//#define cRMTarsPin 7 // Tar
#define cRFCoxaPin 8 //Front Right leg Hip Horizontal
#define cRFFemurPin 9 //Front Right leg Hip Vertical
#define cRFTibiaPin 10 //Front Right leg Knee
//#define cRFTarsPin 11 // Tar
#define cLRCoxaPin 16 //Rear Left leg Hip Horizontal
#define cLRFemurPin 17 //Rear Left leg Hip Vertical
#define cLRTibiaPin 18 //Rear Left leg Knee
//#define cLRTarsPin 19 // Tar
#define cLMCoxaPin 20 //Middle Left leg Hip Horizontal
#define cLMFemurPin 21 //Middle Left leg Hip Vertical
#define cLMTibiaPin 22 //Middle Left leg Knee
//#define cLMTarsPin 23 // Tar
#define cLFCoxaPin 24 //Front Left leg Hip Horizontal
#define cLFFemurPin 25 //Front Left leg Hip Vertical
#define cLFTibiaPin 26 //Front Left leg Knee
//#define cLFTarsPin 27 // Tar
//--------------------------------------------------------------------
//[MIN/MAX ANGLES]
#define cRRCoxaMin1 -650 //Mechanical limits of the Right Rear Leg
#define cRRCoxaMax1 650
#define cRRFemurMin1 -1050
#define cRRFemurMax1 750
#define cRRTibiaMin1 -530
#define cRRTibiaMax1 900
//#define cRRTarsMin1 -1300 //4DOF ONLY - In theory the kinematics can reach about -160 deg
//#define cRRTarsMax1 500 //4DOF ONLY - The kinematics will never exceed 23 deg though..
#define cRMCoxaMin1 -650 //Mechanical limits of the Right Middle Leg
#define cRMCoxaMax1 650
#define cRMFemurMin1 -1050
#define cRMFemurMax1 750
#define cRMTibiaMin1 -530
#define cRMTibiaMax1 900
//#define cRMTarsMin1 -1300 //4DOF ONLY - In theory the kinematics can reach about -160 deg
//#define cRMTarsMax1 500 //4DOF ONLY - The kinematics will never exceed 23 deg though..
#define cRFCoxaMin1 -650 //Mechanical limits of the Right Front Leg
#define cRFCoxaMax1 650
#define cRFFemurMin1 -1050
#define cRFFemurMax1 750
#define cRFTibiaMin1 -530
#define cRFTibiaMax1 900
//#define cRFTarsMin1 -1300 //4DOF ONLY - In theory the kinematics can reach about -160 deg
//#define cRFTarsMax1 500 //4DOF ONLY - The kinematics will never exceed 23 deg though..
#define cLRCoxaMin1 -650 //Mechanical limits of the Left Rear Leg
#define cLRCoxaMax1 650
#define cLRFemurMin1 -1050
#define cLRFemurMax1 750
#define cLRTibiaMin1 -530
#define cLRTibiaMax1 900
//#define cLRTarsMin1 -1300 //4DOF ONLY - In theory the kinematics can reach about -160 deg
//#define cLRTarsMax1 500 //4DOF ONLY - The kinematics will never exceed 23 deg though..
#define cLMCoxaMin1 -650 //Mechanical limits of the Left Middle Leg
#define cLMCoxaMax1 650
#define cLMFemurMin1 -1050
#define cLMFemurMax1 750
#define cLMTibiaMin1 -530
#define cLMTibiaMax1 900
//#define cLMTarsMin1 -1300 //4DOF ONLY - In theory the kinematics can reach about -160 deg
//#define cLMTarsMax1 500 //4DOF ONLY - The kinematics will never exceed 23 deg though..
#define cLFCoxaMin1 -650 //Mechanical limits of the Left Front Leg
#define cLFCoxaMax1 650
#define cLFFemurMin1 -1050
#define cLFFemurMax1 750
#define cLFTibiaMin1 -530
#define cLFTibiaMax1 900
//#define cLFTarsMin1 -1300 //4DOF ONLY - In theory the kinematics can reach about -160 deg
//#define cLFTarsMax1 500 //4DOF ONLY - The kinematics will never exceed 23 deg though..
//--------------------------------------------------------------------
//[LEG DIMENSIONS]
//Universal dimensions for each leg in mm
#define cXXCoxaLength 12 // This is for CH3-R with Type 3 legs
#define cXXFemurLength 32
#define cXXTibiaLength 50
//#define cXXTarsLength 85 // 4DOF only...
#define cRRCoxaLength cXXCoxaLength //Right Rear leg
#define cRRFemurLength cXXFemurLength
#define cRRTibiaLength cXXTibiaLength
//#define cRRTarsLength cXXTarsLength //4DOF ONLY
#define cRMCoxaLength cXXCoxaLength //Right middle leg
#define cRMFemurLength cXXFemurLength
#define cRMTibiaLength cXXTibiaLength
//#define cRMTarsLength cXXTarsLength //4DOF ONLY
#define cRFCoxaLength cXXCoxaLength //Rigth front leg
#define cRFFemurLength cXXFemurLength
#define cRFTibiaLength cXXTibiaLength
//#define cRFTarsLength cXXTarsLength //4DOF ONLY
#define cLRCoxaLength cXXCoxaLength //Left Rear leg
#define cLRFemurLength cXXFemurLength
#define cLRTibiaLength cXXTibiaLength
//#define cLRTarsLength cXXTarsLength //4DOF ONLY
#define cLMCoxaLength cXXCoxaLength //Left middle leg
#define cLMFemurLength cXXFemurLength
#define cLMTibiaLength cXXTibiaLength
//#define cLMTarsLength cXXTarsLength //4DOF ONLY
#define cLFCoxaLength cXXCoxaLength //Left front leg
#define cLFFemurLength cXXFemurLength
#define cLFTibiaLength cXXTibiaLength
//#define cLFTarsLength cXXTarsLength //4DOF ONLY
//--------------------------------------------------------------------
//[BODY DIMENSIONS]
#define cRRCoxaAngle1 -600 //Default Coxa setup angle, decimals = 1
#define cRMCoxaAngle1 0 //Default Coxa setup angle, decimals = 1
#define cRFCoxaAngle1 600 //Default Coxa setup angle, decimals = 1
#define cLRCoxaAngle1 -600 //Default Coxa setup angle, decimals = 1
#define cLMCoxaAngle1 0 //Default Coxa setup angle, decimals = 1
#define cLFCoxaAngle1 600 //Default Coxa setup angle, decimals = 1
#define cRROffsetX -41 //Distance X from center of the body to the Right Rear coxa
#define cRROffsetZ 51 //Distance Z from center of the body to the Right Rear coxa
#define cRMOffsetX -51 //Distance X from center of the body to the Right Middle coxa
#define cRMOffsetZ 0 //Distance Z from center of the body to the Right Middle coxa
#define cRFOffsetX -41 //Distance X from center of the body to the Right Front coxa
#define cRFOffsetZ -51 //Distance Z from center of the body to the Right Front coxa
#define cLROffsetX 41 //Distance X from center of the body to the Left Rear coxa
#define cLROffsetZ 51 //Distance Z from center of the body to the Left Rear coxa
#define cLMOffsetX 51 //Distance X from center of the body to the Left Middle coxa
#define cLMOffsetZ 0 //Distance Z from center of the body to the Left Middle coxa
#define cLFOffsetX 41 //Distance X from center of the body to the Left Front coxa
#define cLFOffsetZ -51 //Distance Z from center of the body to the Left Front coxa
//--------------------------------------------------------------------
//[START POSITIONS FEET]
#define cHexInitXZ 80
#define CHexInitXZCos60 40 // COS(60) = .5
#define CHexInitXZSin60 69 // sin(60) = .866
#define CHexInitY 80 //30
#define cRRInitPosX CHexInitXZCos60 //Start positions of the Right Rear leg
#define cRRInitPosY CHexInitY
#define cRRInitPosZ CHexInitXZSin60
#define cRMInitPosX cHexInitXZ //Start positions of the Right Middle leg
#define cRMInitPosY CHexInitY
#define cRMInitPosZ 0
#define cRFInitPosX CHexInitXZCos60 //Start positions of the Right Front leg
#define cRFInitPosY CHexInitY
#define cRFInitPosZ -CHexInitXZSin60
#define cLRInitPosX CHexInitXZCos60 //Start positions of the Left Rear leg
#define cLRInitPosY CHexInitY
#define cLRInitPosZ CHexInitXZSin60
#define cLMInitPosX cHexInitXZ //Start positions of the Left Middle leg
#define cLMInitPosY CHexInitY
#define cLMInitPosZ 0
#define cLFInitPosX CHexInitXZCos60 //Start positions of the Left Front leg
#define cLFInitPosY CHexInitY
#define cLFInitPosZ -CHexInitXZSin60
//--------------------------------------------------------------------
//[Tars factors used in formula to calc Tarsus angle relative to the ground]
//#define cTarsConst 720 //4DOF ONLY
//#define cTarsMulti 2 //4DOF ONLY
//#define cTarsFactorA 70 //4DOF ONLY
//#define cTarsFactorB 60 //4DOF ONLY
//#define cTarsFactorC 50 //4DOF ONLY
am i missing anything
The position the robot went to is based on the way the servos were mounted. You will need to remove the servo horn and likely replace them in the correct position.
You’ll get it
Here is how my legs are set up. But the servos are right side up like a Phoenix.
The orientation / configuration of the servos is very important. For example if the walking algorithm sends a pulse to move from a forward position (500ms for example) to 2500ms (example) and you have the servo installed backwards, then the robot leg may move in the wrong direction. Can you take a similar photo or two showing how your leg is set up?
Np be an hour or so before i get back
Heres a pic from the front showing the leg positions at 1500.
Heres a top view of the hex centered at 1500
As you indicated, this configuration is opposite what is used on the phoenix code.
If order to get it walking like that, you’ll need to reverse some of the servos or change the code.
Ok i think i might have confused you. The leg segment pic i posted on page five was to show how i had the leg positioned at 1500 neutral. When i said it was upside down i meant compared to the servos on a phoenix.
Heres a better pic of mine showing the set up, just like the phoenix but smaller.
i1254.photobucket.com/albums/hh601/Duhjoker1/Quadruped/6B08EAF3-EB1D-4BB5-AD0B-AF03CAE3FCA2_zps62vxdkdg.jpg