openDog Dog Robot #11 | Kinematics: Pitch Roll & Yaw | James Bruton
HTML-код
- Опубликовано: 3 окт 2024
- You can get your openDog merchandise from: teespring.com/...
Part 11 of my openDog open source hardware & software Dog Robot. It's now time to derive and calculate the next part of the inverse-kinematic model for the robot so we can make it perform useful movements around each foot. This time we're dealing with Pitch, Yaw, and Roll, which are calculated in terms of the XYZ moves so all six axis work together simultaneously.
My open source robot dog project. It includes everything from 3D printing to coding, including a lot of CNC cutting and installing all the electronics myself.
If you want your very own four-legged friend to play fetch with and go on long walks then this is the perfect project for you. This way a dog can literally just be for Christmas. The full CAD is available at the link below for anyone that’s keen to build their own.
github.com/XRo...
① GENIUS
No MacArthur grant yet. But while I’m still waiting by the phone for that call, maybe you might patronise me with your Patreon-age. Or, if you’re all out of digital cash just comment on one of my hilarious Instagram pics, pop me a Tweet or generally yell in my direction.
Patreon: / xrobots
Instagram: / xrobotsuk
Facebook: / xrobotsuk
Twitter: / xrobotsuk
Huge thanks to my patrons, without whom my standard of living would drastically decline. Like, inside out Farm Foods bag decline. Plus a very special shoutout to Aleph Objects, Inc who keep me in LulzBot 3D printers and support me via Patreon. www.lulzbot.com/
Why not join my community, who are mostly made up of actual geniuses. There’s a Facebook group and everything: / community
② XROBOTS
Former toy designer, current RUclips maker and general robotics, electrical and mechanical engineer, I’m a fan of doing it yourself and innovation by trial and error. My channel is where I share some of my useful and not-so-useful inventions, designs and maker advice. Iron Man is my go-to cosplay, and 3D printing can solve most issues - broken bolts, missing parts, world hunger, you name it.
XRobots is the community around my content where you can get in touch, share tips and advice, and more build FAQs, schematics and designs are also available.
③ MUSIC AND SFX
The majority of the music and SFX used in my videos is from Epidemic Sound share.epidemics...
my knees sound like that some mornings maybe i need an extra 15mm on my feet too
Please get to giving the poor thing some feet lol.
Please can you make a little waggy tail? (With varying speeds for different happiness levels obvs) its awesome!
YES.
No
lol nice nickname BEGONE TH....
I think that would be in a further stage when you slave off the arduino 's to an SPC with bigger iron ;).
ruclips.net/video/b4SzoxszRb4/видео.html
This is bloody nifty, ive been following this project ( even before I subscribed ), I help out at a local MakerSpace here, and ive used your video's to prove a common miss conception with how Math is super important, even before code ( which ever language your looking at using ), Trig Geometry and Algebra ( mainly linear ) as shown in robotics here and OpenGL / Vulcan 3D games or the new area's of augmented reality.
Well done on the fantastic explanation area's, covered beyond 100% I think, would be great if Schools / Colleges used this as source materials for computer science / engineering courses.
please make some feet before the next video james as it makes me cringe hearing that cracking and thinking something is going to break and youll have to dismantle stuff to repair it. Excellent work and excellent video, love this project and i think we can all see that opendog is going to have the best locomotion of any Xrobot yet!
I guess pitch and roll are good for keeping the body level on uneven ground or hills
Agreed. Also for climbing up and down.
Or when he starts kicking it like in the Boston Dynamics videos.
Of course. That's what it'll need to run away from humans when it inevitably develops strong AI.
Why haven't you printed some slightly longer feet to remove that cracking noise? Great work so far, but it does seem like a very simple obvious solution for checking that you model is correct
Can you please add some big googely eyes on the two circles please asap
An ir sensor would be better
@@merxellus1456 sensors in good time. Wibbley wibbley eyes are important.
Stuff to scare kids is more entertaining and even they'd agree too until the dog makes a threatening tinny bark synth noise and warns kids off fizzy drinks and McDonalds haha!
@@reggiep75 get the guy that does the furby organ to add flamethrowers.
remember in school when everyone was saying trigonometry is not useful in the real world.... This video. Sat here nodding and not understanding but enjoying this series sooooo much
lol
Never played attention in class but triangles are pretty logical so they can be solved with a bit of brain power.
maths requires a good blood supply to the top of the head, most people lack that so they cant do math, its got nothing to do with 'studying'
Gf do you have any evidence of this? I’ve never heard this theory before. Might explain a few things so...
yes i read it in some medical journal, where they identified which part of the brain is active during different situations. Three years ago I started to have trouble with math, i have a masters in mechanical engineering from 10 years ago, they did a spect scan on my brain and said the top of my brain is poorly oxygenated. That was 3 years ago,now I can't do any basic stuff my sister does in high school. The top of my head is numb too. I believe what they wrote in that journal.
Great work, orientation angles make the robot look much more alive! It is probably worth having a look at rotation matrices for this type of calculations. If in the future, the dog's feet will no longer be on one flat horizontal plane, then working everything out with Pythagoras is going to be a lot of work. With rotation matrices this becomes quite easy. Check Wikipedia or some free online course or RUclips videos on robotics/rotation matrices. Once you have the equations with the rotation matrices, it will be easy to simplify to Arduino code.
Further I have a slight doubt about the calculations presented when multiple tilts are combined. E.g. when the robot is already in an azimuth-tilted position, the additional angles needed for additional roll-tilting and additional pitch-tilting will be different than in the case of a non-azimuth-tilted robot. Consider a large azimuthal-tilt and try to imagine what is needed for making it pitch in addition. BTW I show a bit Pybullet modeling on my channel, if there is interest I can do a bit more on rotation matrices.
do videos about that pls.
I would imagine at some point of adding a bigger Iron SBC with Linux running ROS www.ros.org, would be the way to go.
Huh...
Basically the first thing you need is to define world-coordinates with an x_w, an y_w and z_w direction. This can be some chosen point in the room and 3 orthogonal directions e.g. north, west and up. Then you define robot-coordinates with an x_r, an y_r and z_r direction. This can be some chosen fixed-point on the robot-body e.g. center of gravity or some mid-point of the body and 3 orthogonal directions aligned with the robot body e.g. x_r points in the direction of the long metal bars, y_r points sideways aligned with the body and z_r points upwards from the body. These directions stay aligned with the body as the body moves. Now you can find a transformation function such that when you input some world-position into the function is outputs the robot coordinates of that point. These transformation functions depend on the translation (horizontal and vertical shifts of the robot-point w.r.t the world-point) and orientation (pitch roll azimuth). Once you have these transformation functions (and the inverse transformation function which are very similar to the forward transformations), all the calculations become much easier. E.g. say you want to rotate the robot in pitch and azimuthal direction (ang_p,ang_z), then you compute the transformation function for (ang_p,ang_z). You know the foot stays at the same world coords, so you transform the world-foot coords to robot-foot coords. Once you know the desired foot position in robot-coords it because quite simpel to compute the three motor positions needed to bring the foot to that position. Then you do the same for the other feet. Hope this makes sense. When I have time I will make a few slides for a small video.
@@richardbloemenkamp8532 Richard Bloemenkamp now that's a lot of useful information! Please, make that video happen! Where can I learn more of all of this? I also got curious about how he made the calculation of multiple angles tilting
The angle of the dangle of the triangle, is relative to the dip of the hip.
This is by far your best best project, i can't wait to see it walk!!
brilliant one mate....cant wait for it to actually start walking.....brilliant
I love this project ✔️🤩
Love this project, but am scared of that cracking sound.
he said that its because the feet aren't the right legnth
I know, but it still scares me 😉
It shouldn't bethat hard to finally give the robot appropriately long feet after so many episodes. That stress on its knees doesn't sound good and it could create problems in the future.
I was originally very frustrated that you stopped with the exoskeleton, but this dog project is getting downright impressive. Keep up the Fantastic work though I do hope you get back to the exoskeleton.
I'd like to do another ExoSuit, but it'll be a completely new build with metal in
@@jamesbruton Fair enough. It is your exosuits that originally turned me on to your Channel. I'm very fascinated by them. And the way you do feedback from the person inside the suit and everything is all very intelligent and a lot better than anything else I had seen. I've been wanting to build one that's essentially dumb that just responds to how you move inside it.
Watching the video wearing my #OpenDog t-shirt! The hype is real :)
thanks for that!
Awesome work James!I see others have pointed out that Pitch and Roll are good for climbing up and down stairs and walking on uneven terrain. Also, if you get to a behavior module stage, you could program it to walk and set on its stand, or get off on its own or do other behaviors. (like sit?)
You should replace you boolean side and front with an enum of RIGHT and LEFT. Using `side == RIGHT && end == FRONT` will make your code a lot more readable than `side == 1 && front == 1`.
Awesome work as always!
This series is incredible.
You make amazing stuff! This project is very impressive!
Practical suggestion for pitch and roll: If you install something to detect level on the body, then program it to alter pitch/roll as needed if the level is off by more than a certain amount, it can self correct when moving over an unlevel surface like a slope and keep its body over its center of gravity. Otherwise, if it moves across a slope, with its body at a right angle to the surface, it's off balance and could fall over.
Hope this helps,
this is just amazing. thanks for making these videos. i'm hooked to this series.
Hey James! I have a little suggestion. What if you made like a super simplified version of the open dog for the tshirts and mugs? The way it's currently printed looks good up front, but far away it look like a jumble of lines and colors. I would say... something like a front view with what seems to be like the eyes, removing all the cabling and simplifiying the actuators. Also, personally I would buy one tshirt where you have like an exploded view of the robot wrapped around the body. I know... It would be a real jumble that way... but you know what I mean, the beauty of monochrome exploded models is unparalleled and no one can object to that. :D
Maybe, the graphics I have are doing fairly well though.
I won't say they don't, that was just my opinion, and I have to say that it's the best looking and working enthusiast robot I have ever seen.
knees cracking-- "Open Old Dog"!!
Would it jump if you went as low as you can on the y axis and then went full speed on all motors to the highest position?
It might, but I probably need to speed the motors up, also deal with how it lands ;-)
Could be expensive if it lands upside down
No. He's using screw driven linear actuators...they're far too slow for that. Hydraulic or pneumatic actuators would've been a better choice, also for the shock buffering they provide. The shocks from jumping (or attempting to) would slowly ruin the actuators he's using.
Would also be super cool to see some sort of ML model controlling this thing, train it on a computer with limb lengths/constraints and let it learn how to walk before trying it on the actual hardware. Afaik that's how BD has obtained a lot of the natural looking movements with their bots.
@@Fennecbutt Well the motors can be sped up a lot, but the shock from landing would probably kill the poor thing's knees
Hey James, it seems like there's a lot of points in your code that involve statements like: if(side == 0) {a = b+c} else {a = b-c}. It occurs to me that if you wanted to you could slim these down quite a bit by storing side as -1/+1 instead of 0/1. Then you'd have just "a = b + c*(front)" in one line instead of a whole conditional statement. Probably wouldn't work for all motion axes, but you could still do conditionals for those by swapping if(side==0) for if(side == -1)
I'm going to buck the trend and suggest you some how give it shorter feet....and maybe attach microphones directly to the creaking bits :D
you really like that "15mm longer" excuse
It's the excuse I use as well...
love this series!
thanks!
Hi James, absolutely love this! If you have any more projects like in the future, I'd be happy to sponsor the 3D printing. I tried catching you at the TCT but the crowd was a bit insane. Looking forward to seeing more!
Oh my god! I just saw that OpenDog has a face and now I can't unsee... The yellow hip bearings are the eyes, the yellow handles on top are the ears, the cavity between the hip actuators and the body is the mouth....
Check my profile picture!!
Keep up the good work James!
you really should add those feet on soon I can hear opendog getting arthritis...
Lol😂
Nice project. Glad to see that it progress fast. May be in the future you could add one or two robotic arms, like in boston dynamic robot.
Love it... but I should have paid more attention in Trig.
holyshit. the movements are so fluent.
Awesome work James! These O-drives have some real potential.
I guess you could further parameterize the centres of rotations for yaw, roll and pitch so the origin doesn't have to be in the centre of the trunk.
An accelerometer/gyro could be added to help damp oscillations and resonance.
I want to build a midsize solar tracker - I have a couple of spare bldc drone motors, but I guess odrives might be a bit overkill for something that only needs to move mm per hour. However they could be useful for tracking fast moving objects with a camera or dish antenna such as satellites or remote model aircraft.
So many possibilities, so little time!
Im just looking forward to the 'walking' along with some ruddy feet applied LOL
WOW ...I curious what You could do if YOU had Boston Dynamics budget ???
probably employ people better than me to build it
He'd be building the Atlas assault mech.
Yep, it's pretty basic stuff
Surely the components would be higher end and the materials may include lighter composites and things but when it comes down to it the people that work on the Boston dynamics robots have PhD’s in robotics and handle much heavier math and control systems calculating. James is just an amazing example of how to start and finish a scaled down version of these robotics which is so much more fun and understandable for common people like us here on RUclips. Thank goodness for amazing people like James!
It would have better processors than Arduino, more memory, deeper programming libraries such as ROS, and more expensive motors. More sensors, probably LIDAR so it could perform navigation using Monte Carlo Localization. And GPS for outdoor navigation.
This should be the course for geometry in school . Then it would be really interesting . Is it Soo difficult to print some proper feet ? Those cracking sounds are not nice
just left space for Force Sensitive Resistors pretty sure.. for confirmed feedback of when each foot is making contact with ground, to be implemented later on.
@@ojsh_ How do you check for the concentration of midichlorians in a resistor?
TiagoTiago Whatever you do, don't put it in sand. It hates sand.
Cant wait for more
I love the movement the project has already but I can't help thinking 'Once everything is complete with new feet, AI and other good stuff, how fast can we get that supreme monster chasing kids for a laugh!?'
I do suspect my dreams will remain dreams due to motor limitations.
Very impressive job you made here ! I'm impatient to see the next steps ! ;)
I know that you want to use the missing leg length for mounting some sort of "foot sensor" but what about adding a "blade" type foot to help the dog use the momentum energies more effectively?
At low speed this wont really matter but at a "gallop" it should make dog able to move quite fast without expending too much energy by absorbing and then releasing the energy at the foot level.
Just a thought...
Nice work, thanks for sharing...
Complaint sections or joints introduce a lot of unknowns - there's some discussion about this coming up in part 13 though
Nice work!
When you are done with the dog, I'd build one at 2x size and ride it to work.
For the feet, could you use load cells in each one for feedback? I'm pretty sure you can get load cells in fairly high weight capacities..
Are you still homing axes one by one? - surely you could do multiple axes simultaneously for quicker startup
I am for now so I can check them easily. Once I've sorted out the proper metal encoder mounts (my lathe has just arrived) and calibrated the Z index offset on the ODrives it'll be a much quicker process.
just print another set of temporary feet with an extra 15mm? Won't take an evening and would help prove out all your kinematics. Or move the feet caps down the leg 15mm and retighten?
yes
wow! awesome work!have you thought of also printing the correct length feet! i guess its time fir mode 3 (walking)! great work!
Personally, I think you need to print new temporary feet with the 15mm adjustment as it sounds like you're going to destroy those plastic joints pretty soon.
Or at least set a temporary value in your firmware to subtract that 15mm so the don't put that strain on the joints.
Wonderful series and exciting project!
5:20 Pitch would also be useful for stairs, right?
I'd love something like this, so long as it can carry a reasonable weight and negotiate uneven terrain. I'd take it with me camping to carry supplies and/or transport hunted animals easier.
Even boston has a hard time doing that Boy
Now make it four times the size, out of shiny brass and cogs, billowing out steam, and ride it round like the majestic knight-inventer you are
"So if I put it's bum in the air.." Oh, okay. So it's shaking it butt as us now. You've given it the ability to sass.
"So that's really quite dynamic." But is it.. Boston Dynamic?
I you want to puppeteer it, using an IMU in the remote might be much easier than using two three-axis joysticks. Especially when you add individual leg movement controls for walking.
This is amazing, dont normally comment but im super impressed great work
thanks!
Absolute amazing what you are able to create. Whole robot teams are taking years in what you do in your spare time in a month or two :) The job offers you must get in each month :) I am really hoping you get back to the humanoid building. maybe team up with a silicon creator and get us our real humanoid robot because at the current speed the world is taking way too long to get good humanoids out. There are first attempts to combine the real doll sexdoll combined with some robot technics in the face and that is a start but I am sure you can do way way better. I don't need a sex-bot but a good looking help around the house which I can switch of at the end of day would be nice. Thank you in advance :)
its getting that "organic movement" look that is so distinctive of Boston Dynamics. Can't wait to see how far you take this! Will you be giving it any AI?
Well we'll get it walking first and then we'll see.
Very, very impressive. And I agree to the fluent movement beeing very satisfying. But please, replace those feet to have the correct length!
may be worth inserting 15 mm lengths of aluminium extrusion into the bottom of the 3d-printed shoes and refasting them to the lower legs if the foot sensors are not next on the list
That is very groovy. Ever consider installing a midifile into its movement? A series of dance steps that go through the individual robots extremities synced to the individual limbs with tilts while keeping balances and such, as a diagnostic testing mode. After that, give it a few guitar or drums or keyboard etc abilities with proper fingers with spacial and distance and pressure sensors that can read the frets in relation to how the robot is wearing the guitar, as how the Fretlight guitar can determine note positions on the neck and strumming or fingerpicking could occur, though using robotics with super fast and adjustable motor ramping curves, for vibrato levels etc per note played. I can see how this would work! Hmm...entirely possible.
I've yet to make a robotic arm, though have the parts for the imoov hand thing already printed, minus getting it into working order. Built a cnc machine once and acquired 6 more in various readiness, some just need to order belts, and 5 3d printers. And a cement one is a project in the works, and a mowing bot platform.
Thanks for helping to inspire with your examples.
Remain groovy!
#iGROOV
you clever so n so..well done looks fab
How long do you think it can run for when it starts walking?(run as in battery drain duration not motion run)
Couldn't you fit 15 mm spacers on the end of the feet extrusions and slide the flex "paws" over the top? You could thread the round channels on the end and bolt the spacer on for better stability.
yes
Nice work and progress! But I would recommend checking out real rotation kinematics. It can be simplified a lot by using a rotation matrix solving all 3 rotations at ones.
Once you got the rotation movements in it looked very alive.
Do you really work in the Arduino IDE? I mean, for short sketches this is very straightforward, but for this size of the code, I would recommend using a proper editor like vs code
Bro this is awesome but come on it needs a tail😂👌👍
im in the middle of building a 30 DOF its hands and fingers work as well :P
Thank you so much for this series! I've have wanted to build a small robot inspired by Boston Dynamic's dogs but have been overwhelmed where to start. This video series has so effectively rationalized the design and programming that I've finally started to work on some designs (Thingiverse:3145690) myself. Through working on the 9g Nano design I realized that my servo actuators would not be enough for anything larger so I thought of a way to build a slightly larger version using 3D printed ball screw actuators, rather than servos, which I'm really excited to finish and release. Again thank you.
Well you'll have to check out my next video which is about encoder driven brushed DC motors and lead screws!
Will definitely continue to follow. I have PID experience in arduino but recently discovered that there is a PID library that I plan to couple with PJRC's encoder library.
Hello James, why don't you just make those temporary feet 15mm longer? Still empty for the time be but at least they would match the maths.
Thanks
it's coming
@@jamesbruton thanks. I am very eager to see thar going! That poor thing!
X robotics should hire you, just briljant!! I’m a big fan James;)
I'm so uncomfortable with James attempting to program his robot even though the lower legs are 5 cm too short due to not having the final feet. It makes the knees creak when it moves and just makes me wonder why James doesn't have the lower leg length defined as a constant.
Because the upper and lower leg lengths are the same which is assumed in the code.
So cool! Very well done, you're so damn clever. Really inspiring
So good.
Just out of curiosity, how much weight do you think it could take on its back?
it already weighs 40Kg, but the motor and actuators seem more than strong enough
I wish you would make some new temporary footpads of the proper length.
Very smooth hope you can make the walking as smooth as the stretching
Would pitch be useful for "leaning in" to turns if you get it running?
Damn man, this is super-impressive - good work!
Are you gonna add any sensors and make it be able to walk somewhere on its own and not just on flat land, but rough land to
yes
for some reason this is your most lifelike robot. the movements look really organic to the point it's a bit creepy.
at this point, it really needs some giant goggly eyes
I might legit decide to make this for my senior design next year. I'll just add an arm on top to change it up a little.
+1 on the '50mm longer feet asap' train. so much beautiful trig going on, shame to not see the full benefit realised! Also, this project is looking awesome!
Ojsh _ 15mm not 50mm
@@GeeTheBuilder Oh yeah that makes more sense - 50mm didn't seem right, cheers
(though OpenDog on clown stilts could also be fun to see)
This series makes me far too happy.
I couldn't stop smiling when you demonstrated simultaneous translation and rotation!
You should lead some kind of Object Oriented Programing course!
well my code is pretty hacky so there are better people to do that
nice
You would save a lot of time and explaining with a matrix multiplication.
I want to make the explanation easy for people to understand...
And you're right, I guess most people here understand trigonometry. I just want to spread the beauty of linear algebra :)
Once you get into it, it's way easier than keeping track of all the triangles.
You should forward calculate it as a way to verify you got all the math right. So basically using the angles you generated for the joints work out where in space the feet are going to be, then use pythagoras to work out the distances between each pair of feet. If everything is correct those distances should never change (aside from rounding error).
Also I think this would all be simpler with matricies. You build up a matrix for the translation of the body, another for the rotation, smoosh them together with a multiply. Then run the 4 ground contact points through them and you will get those 4 points relative to the center line of the robot. Then some trig to work out how to position the legs so they span those pairs (attach and ground) of points.
Oh and you should really extend those feet, cause the joint noises could also be a sign that something is wrong somewhere in the math.
Which number is attack mode?
Use float instead of double.
Atmega chips as I know can`t handle correct double type.
Also for UART telemetry better to use binary raw data packet instead of string representation.
In this case you can save some time (ms). Your project has a lot of trigonometry which is sometimes hard for 8-bit Atmega.
That's a damn fancy coffee table :0
Are you going for a 2-legged waling gait, or 3?
I would imagine, if 2 then the roll and side movement ability would help in dynamically balancing the bot while in the walking gait. Need some accelerometers there for feedback...
Compliance in the servo controllers would be helpful as usual. I have done this in the past by running *force-feedback* at the lowest level of loop control then *position control* on top of that. Essentially the compliance acts as a buffer for when the bot encounters a hard obstacle and helps to keep the motors from overloading. With compliance you would be able to push down on the bot by hand and it would react to this by lowering its stance in order to keep the force loops in balance. On top of those 2 is typically a rate control or some type of trapezoidal envelope for orchestrating a large move (it looks like the speed of the servos is doing some aspect of joint speed limiting but does the high level code know how fast the joints can actually move and accommodate this?)
Looks good so far. I imagine someone will, at some point, contribute a code update to wrap all of the kinematics up into a set of matrices (linear math) as well as the rotational translations (are you using Euler for this)?
Cheers,
- Eddy
That last rotation axis reminds me of the AT-AT on Hoth when it steps around and takes out a snowspeeder
3d print it some shoes to make up for the 15mm?
looking forward to seeing it walking :)
I'm not sure if it's the camera angle but it looked like the long threaded rods on the shoulders might be bending in some of the moves
The whole assembly is pivoting that the rods are attached to.