Asked — Edited
Resolved Resolved by Steve G!

Autoposition Speed Question

Lately I have been doing a lot with the Autopositioner. One is having JD sit on a seat and get up again. The seat is about 43mm high which is just right for JD to sit on with the knee servos at right angles to the feet and the upper leg servos at right angles to the knees so as to form the perfect seated posture. The sitting on the seat operation is only basically one frame and goes very smoothly. The standing from the seat is more complicated since JD has to maintain balance as he stands, therefore has several steps.

My problem is that the first step in which he rises part way in the overall action goes as fast as it can no matter what I try. I have set each speed setting in each frame of the action to 4 to try to slow things down, but it stays the same. I have also tried using the script to set the speed for all the servos, but still way too fast. I have even added an extra frame at the start which is just like the last frame of the sitting down operation so it starts in the same position as it had in the last when JD sat down. I only moved the arms out in preparation for standing. That one runs nice and slowly but the very next frame goes at top speed still.

This is how the frames look in the Action Editor: Stand From Seat0(Delay: 25, Steps: 3, Speed: 4, Script: False) Stand From Seat1(Delay: 25, Steps: 3, Speed: 4, Script: False) Stand From Seat2(Delay: 25, Steps: 3, Speed: 4, Script: False) Stand From Seat3(Delay: 25, Steps: 3, Speed: 4, Script: False) Stand From Seat4(Delay: 25, Steps: 3, Speed: 4, Script: False)

Any suggestions? Yes, I have gone through the tutorial. Several times. And tried looking through the posts, but there are 94 of them!


ARC Pro

Upgrade to ARC Pro

Experience the transformation – subscribe to Synthiam ARC Pro and watch your robot evolve into a marvel of innovation and intelligence.

#1  

Have the first frame being JD in the sitting position. This would have no movement for the first frame as he is already there. From there, I would think that your timings would work well.

#2  

@d.cochran Thank you for your reply. That is what the first frame (Stand From Seat0) is. It is a clone of the last frame of the sitting action. The only modification I made to it was to have the arms spread apart and raise somewhat. And that frame works properly with the arms going at a nice slow pace. The very next frame, however, goes at full speed. I have to hold down the feet so Skippy doesn't fall over. Basically the standing action works properly, just way too fast.

PRO
Synthiam
#3  

There are question marks beside each option. The speed setting adjusts the speed of a servo between positions. As you have been informed, the Ezb or computer does not know the position of a servo, it only knows the position that it told the servo to move. If the servo is still moving because the speed is set slow, then it will still skip to the next frame. That's what is happening.

Hover your mouse cursor over the blue question marks to see what the options do.

I would recommend setting a value of 1 for steps and a value of 50 for delay. That will make that action move much slower. You can increase the delay if you need it slower.

You can adjust the speed after to smooth the movement between positions.

Also use the PAUSE frame often. It will help you pause between frames and let the servos catch up.

#4  

@DJ Sures Thank you for your response. I'm confused though (yeah I know, big surprise :D). When I hover over the question mark next to the "Transition To" button in the frame setups in Autopositioner, I get exactly the same message as when I hover over the "Jump To" button question mark. So that's not much help.

Also, what is a "Pause Frame?" I see no such frame in my list of frames in the AutoPosition component (with movement). I derived all my stuff from the original JD project available in the cloud. Is this something I have to create? Can't find any reference to it in the manual concerning the AutoPosition topic either. Nor does that section address the Transition To or the Jump To buttons or how to use them.

I did as suggested and set 1 and 50 but when going from my first frame to the second the robot jumps instantly to the second frame. This is also the case when I do it manually. That is to say, I click on the first frame and the robot sits down nicely. It should be at a known position then. When then click on the second frame of my frame set, it goes instantly to the new position.

I set the Delay to 200 and then I could finally see what was happening. When I click the second step of my stand from seat action (after clicking the first frame first), the robot jumps instantly about half way then goes slowly the rest of the way. Does that every time. Click first frame, sits nicely, click second frame jumps half way then slowly the rest. I have even waited a couple of min. between first and second frame and it still does the same thing. Also, if I then click the third frame after the second, that, and subsequent frames, execute slowly as they should. I even tried going from clicking the first frame to clicking the third frames. Same thing fast about half way up, then slowly the rest of the way.

I just tried creating another frame which is just like the first but only moves the arm servos a little then tried clicking that one as the second frame instead. worked fine, nice and slow then clicked the old second frame and the same thing.

I'm at a loss how to get that second frame to move slow right from the beginning. It's as if the program loses it's position from the clicking of the first frame to the clicking of the second.

United Kingdom
#5  

@WBS.

Hey buddy. The "Pause" frame is automaticly generated and appears at the end of your "Frames" list as highlighted below...

User-inserted image

Inset that I between your frames in the "Action" window on the right.

As for the speed issue, I don't know this is what you are using, and if it is and already tried it I apologise, but are you using the "Edit" tab in the "Action" page...

User-inserted image

If not, click on to highlight the frame you want to change and click "Edit". From there you can adjust the individual servo speed in the frame. I can't be much more help right now as I'm in a train heading home and writing this on my phone using some old screen shots, but hopefully it might help. It might be an idea to post the project link in this thread so we can take a look at it.

#6  

@Steve G Thanks very much for taking the time to post from your cell phone. The image you included is interesting. Apparently it must have come from an AutoPosition component with nothing else in it. I've been using the Autoposition With Movement component that came with the JD project from the cloud. It comes pre-loaded with many Actions and their associated Frames. It's that one I've been using all along. So when I go to the same area in it as shown in your image, the column with the frames is loaded with frames from all the actions that are listed in the leftmost column. Still, nowhere in the Frames column is there a Pause Frame.

I guess the one in the image is of the type from an Autoposition Without Movement kind of Autopositioner component and has no frames in it except the ones for the ones associated with the only action shown. Basically the result of an Action created in newly added AutoPosition component. As I recall the manual says you can have as many of them as you need.

Yes, I did try using the Edit function to place delays and slower speed commands in between the frames, as well as, before the first frame even but it didn't help the problem, which makes it all the stranger. They did make things slower and with greater delay but there was still that full speed jerk at the beginning of the second Frame.

Anyway, I'm going to try one of the AutoPosition Without Movement components next and see what happens doing it that way. Maybe there is a difference in the two types of AutoPosition components besides just the movement controls.

Thanks again.

#7  

Well, as I was exporting the frames and actions needed to import into a fresh Autiposition control, I noticed there IS a Pause frame listed in the choices of frames shown. Going back, I see it is also listed in the frames shown in the "Actions" tab section. I have been looking for it in the "Frames" tab section (makes sense don't you think?) and it is NOT shown there. Apparently there is a subtle difference in that the Frames tab section is only for those frames generated by the user, while the frames shown in the Action tab area also show automatically generated frames, like the Pause frame. Anyway that's why I never saw the Pause frame before. I was only concerned about editing my action in the Action section and never saw the Pause frame there elsewhere in the list.

United Kingdom
#8  

No problem. It's a 4 hour train ride so I've got some time on my hands, and it beats looking at the scenery whizzing past , lol.

Quote:

I did try using the Edit function to place delays and slower speed commands in between the frames, as well as, before the first frame even but it didn't help the problem

Using the same "Edit" method I mentioned, have you tried changing the speed of the second frame that's causing the issue itself? Yeah the frames tab is as you say, where a users frames are created, and the same proses was used to create the already existing frames that came with the project. There's nothing else I can think of at the moment (I have my laptop with me, but the battery died), so if you do post your project link as it stands at the moment with the changes you've made so far, I'll have a look when I get home, unless some one else beats me to it.

Auto position is something I don't use very much and haven't used it for a while so I'm a bit rusty with it, but I'll see if I can figure something out.

PRO
Synthiam
#9  

Every control has a ? Question mark next to the X close button. Press that on the Auto Position and you will receive a manual page for that control. The video explains how it works and even how to create frames. It explains that a frame is a single position and an action consists of frames. It's a common model used since the 1920's with cartoons and eventually moved its way into computer animations in the 80's.

User-inserted image

Here is a direct link to the help page for the Auto Position control: https://synthiam.com/Tutorials/Help.aspx?id=180

I would advise watching the videos to see how the frames are created and added to an action. What will matter most to your tests is creating actions. Start by creating frames and setting the delay/steps for testing manually in the Frames tab. Once you have the frames working as planned, create an action that uses each frame. You can tweak the Steps/Delay/Speed of reach frame only when assigned to an action. All explained in the videos and manual page :)

Remember, an action is a series of frames.

There are also blue question marks beside each option for you to read about. Hope that helps!

#10  

Thank you all once again for trying to assist me on this problem.

@DJSures I do know about creating Frames and linking Frames via Actions. I also know about tweaking the frames as desired, as well as, adding scripts into the frames group in an Action. I've done all that in several variations.

The buttons to which I referred in my previous post were the Jump To and the Transition To buttons in the Frames screen. I included a screen shot below to insure we both know which window I mean. I also know about the question marks to the right of the buttons. Problem is, when I hover over those question marks, the popup text says the same thing for both. Additionally, clicking them doesn't do anything.

User-inserted image

I have previously read the information in the link you provided, thank you, but none of that says anything about those buttons. Nor do the videos (the first of which is seriously out of date as far as the screen layout is concerned) say anything about them or how to properly use them. Nor is there any information in the ARC Manual.

I created a a project called "Sit-Stand Test." It is a bare bones project with an AutoPosition(without movement) control, a connect control, and a standard JD Init Script. The AutoPosition control contains the two actions needed to perform the actions for sitting and standing, as well as, their related Frames, and a "Calibrate" Frame for setting to the calibrate position as needed. That's all. I removed the scripts I had placed in the actions and the frames and anything extra that I tried so to make it as basic as possible. In this way I hoped to eliminate any other influences on the Actions I am trying to get to work.

Please note, the actions presume JD is backed up to an approx 55mm high seat upon which he is going to sit. That height corresponds to the position he would assume with his knees and upper body leg servos at somewhat under 180 and above 0 on the respective upper leg servos. Additionally, the knee servos are at corresponding angles such that JD sits properly on the seat given it's height.

At first I went with 90 and 0 degrees assuming the servos would start there for standing up. What I noticed when I slowed everything way down was that he actually went down more than that, causing the upper leg servos to travel even farther than the last saved position. So the pot setting on the servo would not have matched the last saved position stored in the ARC program and it would jump some to catch up (I presume). But the amount it jumps far exceeds the small difference. Anyway, raising the seat such that he made contact well before the 180/0 point should have taken care of that.

I still have the sudden surge in speed problem as he goes through the reverse order of sitting frames. He sits fine though.

Besides the questions at the beginning of this post, I have a question on adding scripts to the frames in the action sequence. When do these scripts actually run. The documentation says they run with the frame execution. But does that mean they run before the frame execution starts or after? For example, if I put a sleep instruction in that frame script, does the sleep start execution before or after the frame servo movement instruction is sent out? I tried putting a 6 second sleep in each of the frame's script boxes but only the first one had any effect. I don't quite get that either.

Anyway, it's still giving me that surge of speed thing upon going through the stand up actions. I'm going to put this project on the cloud if anyone wants to give it a try. Note the seat must be fairly close to 55mm in height to match the settings in the Frames I created for this. Mostly concerning Frame6 (Sit On Seat6).

Thanks

United Kingdom
#11  

@WBS.

Hey dude. I had a quick look at your "bare bones" project you put in the cloud this morning before I had to go out. I just used a single servo and started to try both actions, then every frame and did discover something. In the frames "Sit on seat 5" and "Sit on seat 6", the servo connected to port D17 is set to 0 (zero). I don't know if you were aware, but step 0 on a servo is no longer a holding position, it's a servo release (this was changed with an ARC update a few months back). So the min and max positions on a servo are now "1" to "180" with 0 being "Servo Release".

So in the sit down action, D17 runs the routine up to frame "Sit in Seat 4" where D17 is set at 60, then 5 and 6 run which release the servo. So when the "Stand from Seat" action is run, 6 and 5 do nothing, then frame 4 essentially resets the servo which is why it moves at full speed (surge of power) for that frame, then is at the speed you set it at after that. So, as the MythBusters say... "There's your problem!, well at least, a problem. So revisit the "Sit on seat 5" and "6" frames and adjust D17 to the positions you need it to be and try again. I don't know if this will fix your whole issue, but it is something that need addressing and hopefully it will help. ;)

Steve.

PRO
Synthiam
#12  

i updated the help on the next ARC release

Transition To If RealTime Update is UNCHECKED, then pressing this button will transition the servos positions to the current selected frame positions at the Delay and Steps value selected

Jump To If RealTime Update is UNCHECKED, then pressing this button will immediately move the servos to the position of the selected frame.

#13  

DJ, you beat me by 3 minutes. I just booted up my Roli and robot PC to verify that I was correctly remembering this functionality before answering.....

Alan

#14  

@Steve G Thank you very much for taking the time to look at the project. That servo being set to zero was a holdover from when I had JD sitting on a seat that was 40mm high (too low). When I changed to a higher seat, I changed the servo positions to non-max settings. All EXCEPT that one that is. So that is a mistake. It should not have been 0. Nonetheless, I do believe you are right. That IS the problem, In more ways than one, When I moved it off of 0 to even just 1, JD jumped up a great deal (had it set to Realtime Update) . In fact from there on, JD would not go to the correct position even when I put him in the calibrate position. I had to reboot JD to get it to act normal again. I had encountered that before but didn't know what was causing it. I do now. Setting a servo to 0 even once will screw up everything from then on. At least in this case anyway. That one servo going to the wrong position was even physically holding back it's counterpart on the other leg. Hence the accompanying loud buzzing.

I had no idea zero was a release point. Makes a world of difference. Thank you sooo much for that bit of info. I'm going to take down the test project and have a go at it with that in mind. No doubt I will get very different results. Can't at the moment since demands of life call. I'll post the results when I do. Thanks again, you've been of immense help.

@DJSures Thank you for the clarification on those buttons. I see what they do now.

United Kingdom
#15  

@WBS.

No problem at all. I hope that helps in you getting the frames acting the way you want. Keep us posted on your progress when you get around to it. Fingers crossed.

#16  

@SteveG I finally got back to fully testing out the non-zero settings of the servos on my sit-stand operations and am happy to report that all works properly now, thanks to you. Now I can move ahead with what I really wanted that action for; a way to allow JD to charge himself by sitting on charging station, connecting electrodes on the back of the upper leg servos. Well, when I finish the massive reprogramming I've been doing with the rock paper scissors game you came up with. That has led to my coming up with a system of script programming which removes ALL scripting commands from the individual phrase's script area in the Speech Recognition window and places them in separate script files instead. Far easier to maintain that way. Makes them searchable and allows them to be ordered as desired as well. But that's another thread, actually. I suspect you've moved on to more games by now.

Thanks again!

United Kingdom
#17  

@WBS.

That's great news. Really pleased to hear the problem is solved. I'm loving the idea of the sitting down to charge routine. That's sounds like a cool idea which I bet others will be interested in. Off topic slightly, the "massive" changes to RPS sounds interesting. I have been working of a first draft quiz game that I've just posted on the other thread that might interest you, and hopefully others too.

Anyway, I'm happy JD is all good now and I'm glad I could help.

Steve.

#18  

This whole thread clearly demonstrates the outstanding support provided by the Community. Waaaaaaay Awesome!

EZ-Robot ROCKS!

Ron