Lynxmotion SES V2 Hexapod Robot

That’s great news Kurt. It stands and sits without an issue I take it. So progress for Spidey :slight_smile: Wish I could have seen that. Ok - what’s next you would like me to get in trouble with… hehe

Not going to put words into @kurte’s mouth but it is all done from within his LSSTestServos sketch: LSS_Test_sketches/LSSTestServos.ino at master · KurtE/LSS_Test_sketches (github.com).

No need for a PS4 - its all menu driven. Its would be the ‘i’ option:
Serial.println("i - Cycle Low/Med/High Stance");
Its based on the one leg stance stuff that Kurt and I worked on with getting synched up with leg orientation in the last couple of posts. Based on that @kurte transfered the one leg settings to other 5 legs I guess - haven’t looked at the changes yet.

As to whether it will work with the Teensy board design you distributed, I don’t see why not. Sure @kurte would agree.

@cbenson ( @cyberpalin )

As you mentioned, it simply moves all 6 legs through a couple of positions. Sort of like sit down, stand up, on your tippy toes and back down…

Now to do a little experimenting, like change Mikes check if the servos are done code to all of the legs.
Also maybe experiment with different options, like setup to do more of a complete leg cycle where we set up some intermediate points.

And then experiment with some different experiments, like can it go through something like 20 or or more steps with no pauses and move in a smooth continuous motion,

And try it a few different ways to see what works best.

But now enjoying a nice sunny day!

Yes as you said with the positions = pretty much matches what I believe @dialfonzo posted for low/med/high stance.

That delay(450) after the servos move seem pretty much to ensure that the checkStatus will come back with all a “6 - hold” result. Played around with it enough anything less seems to get you into a loop with checking status. But enjoy.

If I knew could decipher enough of the gait engine that is in github respository I would just make a mini-version to incorporate into the example sketch for testing especially with the servo timings etc. But that is a big chunk of code and too many moving pieces - but who knows or might just leave it there.

Thanks for setting me straight on servo orientation and getting a common set-up (1 - correct servo orientation for left and right sides and 2 - 0 position for setting up the leg).

Enjoy the rest of your nice sunny day @kurte, still cloudy here but at least its not cold.

@kurte We can pick up a generic PS4 remote or two for testing. We have not had the discussion internally regarding where what type of controller to choose for all SES V2 robots, but happy to have the material for testing if that’s where the test / sample code is going.

@Xan @cyberpalin @cmackenzie (and others) do you have a PS4 remote & Bluetooth already?

Already have several variations of the PS4 type remotes that I use for testing. 2 PS4 clones and 1 DS4. So would not need any additional ones. Thank you though.

Right now, though, the only version of the PS4 remote that seems to work with USBHost_t36 is the DS4. The PS4 clones that @kurte and I have are still a work in progress to get them to connect via Bluetooth. If you look at the last several posts of T3.6 USB Host - Bluetooth - Page 38 (pjrc.com) you will see where @kurte has been trying to resolve the connection issue.

@kurte can probably add more to this.

I’m seeing quite a lot of angle / dimensions drawings.
Wondering if you guys need any CAD dimensions of anything ?

@cbenson As @cyberpalin mentioned, the two of us have been working on supporting some of the different clones.

For awhile now we have had real PS4 controllers working working with the Teensy 4.xs as well as with the T3.6. But as these are relatively expensive (but the price of one of the servos), thought it would be interesting to try out and hopefully some of the clones. It is interesting just how different each of the different clones are on how they handle the communications, especially the different handshaking.

I believe I have one made by Voyee working, but will need to integrate that in. Some of the others are requiring us to implement some additional Bluetooth capabilities to make them work. Which is a WIP. Note some of these work on for Arduino Host Shield 2 hardware so we have other code bases to look at that help to resolve some of the issues. With some of these it does not work on either, but they appear to work on Linux, so then we need to capture their communications using something like WireShark and then try to figure out what they are doing differently…

The bright news is solving some of these issues, may also help us support some of the other controllers such as the switch and Xbox One… But will see over time.

In the mean time, if having a reasonably priced controller is impeding anyone’s progress on this project, There are several cheap PS3 clones that work. And in my code base will setup to detect if I am using a PS3 or a PS4 and choose different table or tables, such that it will be able to detect for example if the user pressed the R1 button on either controller…

More details on what Bluetooth devices we have worked on is up in the first message of the PJRC thread that cyberpalin linked to in previous message.

[quote=“dialfonzo, post:774, topic:62511, full:true”]
I’m seeing quite a lot of angle / dimensions drawings.
Wondering if you guys need any CAD dimensions of anything ?
[/quote]!

I have been using these 2 drawings to get dimensions that I believe you posted last year, guess I would just like to confirm that they are still good and out of curiosity what are the thicknesses of the top and bottom plates?


1 Like

@kurte - @zenta
Here we go again with an indirect axis questions :slight_smile: Going the hex_cfg.h file and trying to update for Spidey (yes I nicknamed the hexapod) and seeing this for body dimensions:

//--------------------------------------------------------------------
//[BODY DIMENSIONS]
#define cRRCoxaAngle   -34   //Default Coxa setup angle, 34.280877 degs from center line? atan-1(60.6/88.9)
#define cRMCoxaAngle    0      //Default Coxa setup angle
#define cRFCoxaAngle    34      //Default Coxa setup angle
#define cLRCoxaAngle    -34   //Default Coxa setup angle
#define cLMCoxaAngle    0      //Default Coxa setup angle
#define cLFCoxaAngle    34      //Default Coxa setup angle

#define cRROffsetX      -73    //Distance X from center of the body to the Right Rear coxa
#define cRROffsetZ      105     //Distance Z from center of the body to the Right Rear coxa

#define cRMOffsetX      -113    //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      -73     //Distance X from center of the body to the Right Front coxa
#define cRFOffsetZ      -105    //Distance Z from center of the body to the Right Front coxa

So whats x and z direction on the body. Looks like you have some strange axis notation, help in understanding. Can take a guess but…

I always use my custom build XBEE controller which Kurt and Zenta also (use to) have. I think we all have slightly different types since we all improved/changed them to our needs :slight_smile:

I do have some old PS2 and Wii controllers laying around but no PS4/XBOX.

Hi @cyberpalin,

I agree, the coordinates should be re-arranged in the new version.
But here is a quick sketch that might help.

Thanks that pretty much answers the question so far.

1 Like

Oh and these are the 0 angles for the servos. Make sure all servos are calibrated like this.

I hope it helps! :slight_smile:

Hi @kurte and @cyberpalin.

Updated IDE and Teensy driver didn’t help much.
I’m able to upload code to the Teensy when it’s powered from USB only (using the J5V jumper).
The moment I power it through Kurt’s T41_SimpleLSS board Win10 on my machine doesn’t recognize the T41 (removed the J5V jumper, doesn’t work with either). Windows claim there must be something wrong with the device connected to the USB port. I do measure correct 5v voltage on T41-Vin.
Btw, shouldn’t there be any light/LED on the T41 board that indicate it’s powered? I get no lights at all.

I’ve no idea what to try next.

@Xan You’ve swapped the X and Z. Z is forward/backward. X is left to right.

Hi @zenta - if you get a chance you might send photos of the top and bottom of the board. Maybe there is a solder issue? Like a solder bridge?

If you connect up USB to the board and have not cut the VIN/VUSB connection on the bottom of the teensy it should power up the teensy. If you cut that trace than it should power up if you connect VIN to VUSB using shunt

And I know you know the drill, of try to remove everything connected to it to see if that helps.

Try holding down the program button for like 20-30 seconds until program led on the teensy blinks and it should reprogram it with default program shipped with it, then try programming it with blink and see if it will blink…

But so far it is sounding like something wrong on your board. The one that @dialfonzo shipped me worked. I screwed up on telling him which QWIIC connectors to use, so unsoldered the ones he put on and replaced with the ones that match the pattern I put on the boards.

Let me know if you see something or again post photos and will take a look.

Oops :scream:
You are completely right! Thanks for the correction!

@zenta - @xan
From that and looking at the hex_cfg file this looks like the body axes:

Yep - check out the discussion @kurte and I had a couple of days ago on assembly left vs right servos.

Following @kurte’s assembly recommendations for the femur and tibia) I set up appropriate offsets in LSS config for each servo as well well as setting the gyre. For the right front servo set them up as:
#define RF_COXA_MaxSpeed 600
#define RF_COXA_Gyre LSS_GyreCounterClockwise
#define RF_COXA_Offset 0

#define RF_FEMUR_MaxSpeed  600
#define RF_FEMUR_Gyre      LSS_GyreCounterClockwise
#define RF_FEMUR_Offset    -104

#define RF_TIBIA_MaxSpeed  600
#define RF_TIBIA_Gyre      LSS_GyreCounterClockwise
#define RF_TIBIA_Offset    -137

This makes match what you see. Not sure what @kurte did in the latest all leg version. Didn’t get a chance to look at it yet.

1 Like

I just sort of duplicated your stuff, but in table form:

//====================================
//set MJS RF config Gait Test Values
// and Mucked up by KJE ;)
//====================================
typedef struct {
  uint8_t         id;
  LSS_ConfigGyre  gyre;
  int16_t         offset;
  int16_t         max_speed;
} servo_info_t;
typedef struct {
  const char    *leg_name;
  servo_info_t  coxa;
  servo_info_t  femur;
  servo_info_t  tibia;
} leg_info_t;

leg_info_t legs[] = {
  {"Left Front",  {LF_COXA, LSS_GyreCounterClockwise, 0, 600}, {LF_FEMUR, LSS_GyreClockwise, -104, 600}, {LF_TIBIA, LSS_GyreClockwise, -137, 600}},
  {"Left Middle", {LM_COXA, LSS_GyreCounterClockwise, 0, 600}, {LM_FEMUR, LSS_GyreClockwise, -104, 600}, {LM_TIBIA, LSS_GyreClockwise, -137, 600}},
  {"Left Rear",   {LF_COXA, LSS_GyreCounterClockwise, 0, 600}, {LR_FEMUR, LSS_GyreClockwise, -104, 600}, {LR_TIBIA, LSS_GyreClockwise, -137, 600}},

  {"Right Front",  {RF_COXA, LSS_GyreCounterClockwise, 0, 600}, {RF_FEMUR, LSS_GyreCounterClockwise, -104, 600}, {RF_TIBIA, LSS_GyreCounterClockwise, -137, 600}},
  {"Right Middle", {RM_COXA, LSS_GyreCounterClockwise, 0, 600}, {RM_FEMUR, LSS_GyreCounterClockwise, -104, 600}, {RM_TIBIA, LSS_GyreCounterClockwise, -137, 600}},
  {"Right Rear",   {RF_COXA, LSS_GyreCounterClockwise, 0, 600}, {RR_FEMUR, LSS_GyreCounterClockwise, -104, 600}, {RR_TIBIA, LSS_GyreCounterClockwise, -137, 600}}
};
#define COUNT_LEGS (sizeof(legs)/sizeof(legs[0]))


#define RF_COXA_MaxSpeed  600
#define RF_COXA_Gyre      LSS_GyreCounterClockwise
#define RF_COXA_Offset      0

#define RF_FEMUR_MaxSpeed  600
#define RF_FEMUR_Gyre      LSS_GyreCounterClockwise
#define RF_FEMUR_Offset    -104

#define RF_TIBIA_MaxSpeed  600
#define RF_TIBIA_Gyre      LSS_GyreCounterClockwise
#define RF_TIBIA_Offset    -137

//Time delays for Gait MoveT commands
uint16_t delay1 = 450;
uint16_t servo_move_time = 250;

And then changed your two functions ‘c’ and ‘i’ to do all of the legs.