What is the proper start position for the Sted-E-Man walker to prevent damage?

  • Thread starter Thread starter wolram
  • Start date Start date
  • Tags Tags
    Code
Click For Summary

Discussion Overview

The discussion revolves around the proper start position for the Sted-E-Man walker to prevent damage during initialization. Participants are examining the code used to control the servos that position the walker's legs, focusing on potential errors and the sequence of operations necessary to avoid clashes between the feet.

Discussion Character

  • Technical explanation
  • Debate/contested
  • Mathematical reasoning

Main Points Raised

  • Some participants suggest that the current code may lead to the feet clashing if the servo positions are not correctly initialized.
  • One participant points out that only the Left_Foot.Operate is set in the Start_Pos routine, raising questions about the initialization of other servos.
  • Another participant mentions that the servos work independently in other setups, indicating that the issue may lie in the coordination of multiple servos in this code.
  • There are concerns about the timing of the delays used in the code, with questions about whether they are in hundredths or thousandths of a second, which could affect servo movements.
  • Some participants recommend simplifying the code to test individual servo movements before integrating all four servos.
  • One participant suggests increasing the delay times significantly to observe the movements more clearly and identify any issues.
  • Another participant notes that the servos do not complete their movements properly and that the right hip moves simultaneously with the left, complicating troubleshooting.

Areas of Agreement / Disagreement

Participants express differing views on the source of the problem, with no consensus on the exact cause of the issues with the servo movements. Some agree on the need for a proper start sequence, while others focus on the timing and coordination of the servos.

Contextual Notes

There are unresolved questions regarding the timing units used in the code and the specific initialization sequence for the servos. Participants have not reached a definitive conclusion about the best approach to prevent damage to the walker.

Who May Find This Useful

This discussion may be useful for individuals working with robotic servo control, particularly those interested in initialization sequences and troubleshooting coordination issues in robotic movements.

wolram
Gold Member
Dearly Missed
Messages
4,411
Reaction score
551
Please can anyone see an error.

'##############################################################################
'Start Position: The Sted-E-Man needs a strat sequence to set the legs in the
'correct position. Unless the servo positions are known, the feet could clash
'on first start-up or reset and cause damage to the walker.
'##############################################################################

Dim Left_Hip As New oServo 'Left hip servo set
Dim Right_Hip As New oServo 'Right hip servo set
Dim Right_Foot As New oServo 'Right foot servo set
Dim Left_Foot As New oServo 'Left foot servo set
'******************************************************************************

Sub Main()
'###############################################################
'This is the first routine that is entered on start up or reset.
'###############################################################
Left_Hip.IOLine = 14 'Left Hip servo IOLine
Left_Hip.Center = 27 'Center position
Left_Hip.Operate = CVTrue 'Servo object turns on

Right_Hip.IOLine = 12 'Right Hip servo IOLine
Right_Hip.Center = 27 'Center position
Right_Hip.Operate = CVTrue 'Servo object turns on

Right_Foot.IOLine = 10 'Right foot servo IOLine
Right_Foot.Center = 30 'Center position
Right_Foot.Operate = CVTrue 'Servo object turns on

Left_Foot.IOLine = 8 'Left foot servo IOLine
Left_Foot.Center = 28 'Center position
'Left_Foot.Operate = CVTrue 'Servo oject turns onCall Start_Pos 'Call the start position for all servos
oopic.delay = 300 '3 second delay for Sted-E-Man positioning
End Sub
'******************************************************************************

Sub Start_Pos()
'################################################################
'A routine to set the start position is needed otherwise the
'Sted-E-Man's feet could clash damaging the robot.
'################################################################
Right_Foot.Value = 0 'Move Right Foot outwards full
oopic.delay = 200 '2 second delay
Left_Foot.Operate = CVTrue 'Servo oject turns on
Left_Foot.value = 56 'Move Left Foot outwards full
oopic.delay = 200 '2 second delay
Left_Hip.Value = 27 'Move the Hip servos to start
oopic.delay = 200 '2 second delay
Right_hip.Value = 10 'position
oopic.delay = 200 '2 second delay

'Right_Foot.Value = 30 'Move Right foot to start position
'Left_Foot.Value = 28 'Move left foot to start position

End Sub
'**************************************************************
 
Technology news on Phys.org
wolram said:
Please can anyone see an error.
I see an error, but not in the code.:rolleyes:
Perhaps you could tell us where it's going awry. Any error messages you'd care to share?
 
I see an error... but I will bite my toung, it has nothing to do with the code.
 
Just shooting in the dark until I get more info:

In your Start_Pos, you set Left_Foot.Operate , but I don't see any .Operate sets for any other servos.
 
DaveC426913 said:
I see an error, but not in the code.:rolleyes:
Perhaps you could tell us where it's going awry. Any error messages you'd care to share?

This code is supposed to activate 4 servoes to a start possition, but they just
go crazy, there are no error messages.
the servoes work ok independantly, this from another set up code used to find
center values that are then transferred into this one.
 
OK, strip it down to the bare bones.
Get one servo making one move.
Get another servo making a move.
Throw away everything else until you have a maximum of two movements coordinated.

Question: the time units you are using: you sure they are 100ths of a second? If they are 1000ths of a second, then each of your delays are only fractions of a second.
 
DaveC426913 said:
OK, strip it down to the bare bones.
Get one servo making one move.
Get another servo making a move.
Throw away everything else until you have a maximum of two movements coordinated.
Question: the time units you are using: you sure they are 100ths of a second? If they are 1000ths of a second, then each of your delays are only fractions of a second.
Thanks for the help Dave, i can get 2 servoes to work, left foot,left hip as they
should, and the same for right foot, hip, it is only when i try to get all 4 to work
together, the delays are seconds.
this is the latest code i tried.

Sub Start_Pos()
'################################################################
'A routine to set the start position is needed otherwise the
'Sted-E-Man's feet could clash damaging the robot.
'################################################################
Right_Foot.Value = 0 'Move Right Foot outwards full
Left_Foot.value = 56 'Move Left Foot outwards full
oopic.delay = 50 'small 0.5 second delay
Left_Hip.Value = 27 'Move the Hip servos to start
Right_hip.Value = 10 'position
oopic.delay = 100 '1 second delay

'Right_Foot.Value = 30 'Move Right foot to start position
'Left_Foot.Value = 28 'Move left foot to start position

End Sub
 
Set your delays to, like, 5 seconds. Give your eyes & brain time to watch the action and see what it's doing. (eg. Is it really going randomly haywire? Or is it just one move that's out of place? What is the first move that is not as it should be?)
 
DaveC426913 said:
Set your delays to, like, 5 seconds. Give your eyes & brain time to watch the action and see what it's doing. (eg. Is it really going randomly haywire? Or is it just one move that's out of place? What is the first move that is not as it should be?)

It seems random, the servoes do not complete a full movement and the right
hip moves at the same time as the left, it is difficult to to fault find, as any
clashes can damage the gears in the servoes, so i have switch it off quick.
I have changed the output IO lines, thinking it could be a hardwear problem
but it is the same, i have cleared the EPROM and stated from scratch with
no joy.
 
  • #10
wolram said:
Please can anyone see an error.

'##############################################################################
'Start Position: The Sted-E-Man needs a strat sequence to set the legs in the
'correct position. Unless the servo positions are known, the feet could clash
'on first start-up or reset and cause damage to the walker.
'##############################################################################

Dim Left_Hip As New oServo 'Left hip servo set
Dim Right_Hip As New oServo 'Right hip servo set
Dim Right_Foot As New oServo 'Right foot servo set
Dim Left_Foot As New oServo 'Left foot servo set
'******************************************************************************

Sub Main()
'###############################################################
'This is the first routine that is entered on start up or reset.
'###############################################################
Left_Hip.IOLine = 14 'Left Hip servo IOLine
Left_Hip.Center = 27 'Center position
Left_Hip.Operate = CVTrue 'Servo object turns on

Right_Hip.IOLine = 12 'Right Hip servo IOLine
Right_Hip.Center = 27 'Center position
Right_Hip.Operate = CVTrue 'Servo object turns on

Right_Foot.IOLine = 10 'Right foot servo IOLine
Right_Foot.Center = 30 'Center position
Right_Foot.Operate = CVTrue 'Servo object turns on

Left_Foot.IOLine = 8 'Left foot servo IOLine
Left_Foot.Center = 28 'Center position
'Left_Foot.Operate = CVTrue 'Servo oject turns on


Call Start_Pos 'Call the start position for all servos
oopic.delay = 300 '3 second delay for Sted-E-Man positioning
End Sub
'******************************************************************************

Sub Start_Pos()
'################################################################
'A routine to set the start position is needed otherwise the
'Sted-E-Man's feet could clash damaging the robot.
'################################################################
Right_Foot.Value = 0 'Move Right Foot outwards full
oopic.delay = 200 '2 second delay
Left_Foot.Operate = CVTrue 'Servo oject turns on
Left_Foot.value = 56 'Move Left Foot outwards full
oopic.delay = 200 '2 second delay
Left_Hip.Value = 27 'Move the Hip servos to start
oopic.delay = 200 '2 second delay
Right_hip.Value = 10 'position
oopic.delay = 200 '2 second delay

'Right_Foot.Value = 30 'Move Right foot to start position
'Left_Foot.Value = 28 'Move left foot to start position

End Sub
'**************************************************************

You don't show the code for "servos" or "man positioning"

but in the last sub start_position you set Right_foot.value 2 times? you cannot set the variable more than ONE time!

Code runs a million billlion zillion lines per second, but a motor is very slow by comparison. One has 'value' with uppercase another with lowercase. in basic it should be okay? but its a dangerous habit.

Start by setting the items only one time. You may want to initialize each component one by one, checking limit switches slowly and if they don't work, throw an error which turns every motor off.

An init routine will take time to make/debug but start there
 
  • #11
Thankyou brad, i will work through it moer carefully.
 

Similar threads

  • · Replies 1 ·
Replies
1
Views
11K