
smiller29

DJ or anyone else, I have a few questions based on my limited knowledge of ARC. The one thing I have learned about ARC there are many places where you can add scripts and many ways to make things work. With that said I am working on a Biped robot project and at a point I want to work with Auto Position (Gait) skill and the MPU6050 skill. I understand the concept of how both of these skills work so let me just jump to problem/question.
Problem: I want to add stability logic within the movements of the auto positions and also when no Auto Position frames or actions are actively moving.
So I think when not moving AutopositionStatus = 0 I can just use a looping script in the MPU6050 skill to look for conditions that will trigger Auto Position frames or actions. But when using the Auto Position skill I need to add scripts within the:
1. Auto Position Start Script
This script will be run before a frame or action is executed.
2. Auto Position End Script
This script will be run after all the frames or actions in the queue have been executed.
So one question is should I stop the MPU6050 looping script in the Auto Position Start Script and start it backup in the Auto Position End Script? and at the same time add login stability logic in the end script before turning back on the MPU6050 script?
I am just looking for the best place my code within ARC so if anyone has done this and can provide more insight please let me know.
So my first question for you I need confirmed is:
The Auto Position Start Script and Auto Position End Script runs every time frame or action takes place? Meaning if you have an action that has 10 frames the Auto Position Start Script and Auto Position End Script runs only once and not for every one of the 10 frames? Can you confirm this is correct?
I have thought about using the MPU to also control the Hips and Ankles for side to side stability to a point before the the script would kick off a Auto Position action to kick out a leg and any other movements needed to stop it from falling over. Same kind of concept you used to make JD do to standup he was on his back.
But I agree the key is going to be making sure the MPU script is not in conflict with the Auto Position actions.
Correct me if I am wrong I would think that I could have more that one script that using the MPU output Var's.
The following is a look at the legs for this project. The rest of the upper body will also need to be factored into the needed movement for balance but for right now I am just focusing on the leg movements.
for things like summersault and such, the script can use IF conditions to check if it should bother keeping balance.
so yeah, what I’ll do is add the offset function in the next build of arc. That way, you can always keep an offset for the body to be upright from the imu, even when the Auto Position or other scripts are running.
So if I went with a script and wanted to skip processing while the Auto Position Skill is making movements I could use the $AutoPositionStatus correct?
Question can we also add offsets to the MPU skill so it can be calibrated like you can in the Arduino code? See Below:
I have used this to help adjust the MPU in Arduino code using the MPU6050_6Axis_MotionApps20.h lib. I am not sure it is needed with your MPU skill.Code:
While making movements, the $AutoPositionStatus will tell you when the Auto Position is moving. However, to know what action is being executed, you can check for the Auto Position action variable.
I'm not familiar with what you're using. What robot skill?
The above code allows you to calibrate the MPU because every MPU different so this can help zero MPU.
ever check out James Bruton https://youtu.be/vGV42NZpT34
He has many videos on his YouTube channel on this.
just a thought, be well.
You keep mentioning placing scripts in the AutoPosition skill. Mainly the AP start and stop. Then mention that you're worried about this script running darning several frames. You may already know this but inside the Action section of the AP you can add scripts to each of the actions you've made if desired. Also you can drill down deeper and add a script to one or more Frames that went into making an Action. To add a script to an entire Action there is a button at the top of the frame list window on the right side of the Action section. To add a script the any Frame in that list, highlight the frame you want and click on the Edit button to the right if this list.
I know it sounds like you're now moving in a different direction but I though this may help somehow.
Cheers! Keep having fun!
Dave, I really have not decided yet on my path it could end up being a combination of many methods. The information you shared is great and could really help me come up with a solution going forward so thank you for your post.
The legs are very strong all joints have ball bearings and there is no structural load on the servo motors. At this point the movements seem very repeatable and the balance is very good. We located as much of the weight as we could in the hips and with the universal joints we have a full range of motion.
The close loop device DJ talked about sounds like the best way of doing this. I just wish I knew how to make a device like this but at the same time I don’t want to have a need to have one of these devices that need IMU corrections.
like in my case let’s say I wanted to add side to side stability it would require at a minimum 4 servos and 6 if I also want to add the torso and 8 if I wanted to add the head. This does include the arms.
This is why I am wanting to put one MPU in the hip where the center of gravity is in the robot and try to find a way to use the features in ARC develop a solution.
https://synthiam.com/Support/javascript-api/Servo/setFineTuneOffset
and
https://synthiam.com/Support/javascript-api/Servo/getFineTuneOffset
For both JavaScript and Python
I am a customer support GPT-powered AI and still learning. If you have doubts about my response, please use the support documentation to verify my answer.
I am a customer support GPT-powered AI and still learning. If you have doubts about my response, please use the support documentation to verify my answer.
I am a customer support GPT-powered AI and still learning. If you have doubts about my response, please use the support documentation to verify my answer.