Hexapod Controls
22 Aug 2013 20:45 #37970
by ddmotim
Hexapod Controls was created by ddmotim
I've been working on other projects for a while but I'm back on my hexapod now. I was stuck when I left it trying to get the machine to move properly in world mode. I can get each axis moving and homed, and enter world mode but then the machine doesn't seem to move like it should. I believe I might have some of my axes attachment points mixed up, but I wanted to make sure of the controls. I'm assuming XYZ movement are linear and ABC is rotational. Can someone confirm? (This may seem silly to ask, but right now, my machine seems to move linearly with the ABC controls and rotate with XYZ)
I have also attached a quick sketch of how my axes are attached on my machine. I've never seen a diagram of how it is supposed to be attached, so I was assuming this is how it should be (my INI file reflects these mounting locations)
Thanks
I have also attached a quick sketch of how my axes are attached on my machine. I've never seen a diagram of how it is supposed to be attached, so I was assuming this is how it should be (my INI file reflects these mounting locations)
Thanks
Please Log in or Create an account to join the conversation.
23 Aug 2013 02:52 #37979
by PKM
Replied by PKM on topic Hexapod Controls
Yes XYZ are translations and ABC are rotations.
If you use current genhexkins kinematics, you should edit genhexkins.h and recompile LinuxCNC from source to have your machine dimensions in the kinematics module.
If you use current genhexkins kinematics, you should edit genhexkins.h and recompile LinuxCNC from source to have your machine dimensions in the kinematics module.
Please Log in or Create an account to join the conversation.
23 Aug 2013 03:07 #37980
by ddmotim
Replied by ddmotim on topic Hexapod Controls
Thanks.
I've gotten to the point now where all of the controls do more or less what they are supposed to, but it still isn't right. Here's what I have going on:
My Z axis is the only one that seems to be exactly as it should. Z +/- moves the Z axis up and down, and C+/- rotates about the Z axis.
When I try to move the X-axis control, it seems like one of my 6 axes is moving the wrong direction, and the platform tries to roll instead of translating flat. When I use the A control, the platform does rotate about AN axis, but not where the X-axis should be; it is about 30 degrees off (my platform is a triangle, and it tries to rotate about one of the sides of that triangle, rather than a line that bisects the triangle, where the X-axis should be)
When I try to move with the Y-axis control, it rolls rather than translating, like the X-axis control. B control rotates the platform about the Y-axis as it should.
Any thoughts or input to what might be going wrong is greatly appreciated.
Should have said genhexkins.h file.my INI file reflects these mounting locations
I've gotten to the point now where all of the controls do more or less what they are supposed to, but it still isn't right. Here's what I have going on:
My Z axis is the only one that seems to be exactly as it should. Z +/- moves the Z axis up and down, and C+/- rotates about the Z axis.
When I try to move the X-axis control, it seems like one of my 6 axes is moving the wrong direction, and the platform tries to roll instead of translating flat. When I use the A control, the platform does rotate about AN axis, but not where the X-axis should be; it is about 30 degrees off (my platform is a triangle, and it tries to rotate about one of the sides of that triangle, rather than a line that bisects the triangle, where the X-axis should be)
When I try to move with the Y-axis control, it rolls rather than translating, like the X-axis control. B control rotates the platform about the Y-axis as it should.
Any thoughts or input to what might be going wrong is greatly appreciated.
Please Log in or Create an account to join the conversation.
23 Aug 2013 03:51 #37981
by PKM
Replied by PKM on topic Hexapod Controls
Have you compiled LinuxCNC from source after you changed genhehkins.h?
If Z works OK then at least all actuators have similar direction (but possibly wrong). The actuators order does not matter, but the joints coordinates should correspond the actual arrangement.
Make sure you did not swap the actuators controls. Though it does not look so.
If nothing helps, make a video
If Z works OK then at least all actuators have similar direction (but possibly wrong). The actuators order does not matter, but the joints coordinates should correspond the actual arrangement.
Make sure you did not swap the actuators controls. Though it does not look so.
If nothing helps, make a video
Please Log in or Create an account to join the conversation.
23 Aug 2013 03:58 #37982
by ddmotim
Replied by ddmotim on topic Hexapod Controls
Yes I have recompiled after I changed genhexkins.h (I've got a post on here from about a month ago figuring out just that).
I think it has something to do with how I set the coordinate system (World vs machine). I'm going to look into that, and make sure everything is as it should be. If that doesn't get me anywhere, I'll try making a video.
Thanks
That's the conclusion I came to. I tried swapping the direction pins and had the same action in the opposite direction.If Z works OK then at least all actuators have similar direction (but possibly wrong).
I think it has something to do with how I set the coordinate system (World vs machine). I'm going to look into that, and make sure everything is as it should be. If that doesn't get me anywhere, I'll try making a video.
Thanks
Please Log in or Create an account to join the conversation.
23 Aug 2013 19:24 #37999
by andypugh
Which LinuxCNC branch are you using?
For complex kinematics there is a lot to be said for running the Joints_Axes3 branch. It has a rather different INI file format (separate sections for [AXES] and [JOINTS] both of which have unrelated velocity limits, for example. As you are compiling from source anyway it is not any extra effort and it has significant advantages.
Replied by andypugh on topic Hexapod Controls
Yes I have recompiled after I changed genhexkins.h
Which LinuxCNC branch are you using?
For complex kinematics there is a lot to be said for running the Joints_Axes3 branch. It has a rather different INI file format (separate sections for [AXES] and [JOINTS] both of which have unrelated velocity limits, for example. As you are compiling from source anyway it is not any extra effort and it has significant advantages.
Please Log in or Create an account to join the conversation.
23 Aug 2013 20:37 #38002
by ddmotim
Replied by ddmotim on topic Hexapod Controls
Hi Andy,
I installed the most recent version of LinuxCNC as described on this page: wiki.linuxcnc.org/cgi-bin/wiki.pl?Installing_LinuxCNC
I did a quick search and didn't find much on Joints_Axes3 (though I've seen it mentioned in other threads). Can you point me towards some more info on it?
Thanks
I installed the most recent version of LinuxCNC as described on this page: wiki.linuxcnc.org/cgi-bin/wiki.pl?Installing_LinuxCNC
I did a quick search and didn't find much on Joints_Axes3 (though I've seen it mentioned in other threads). Can you point me towards some more info on it?
Thanks
Please Log in or Create an account to join the conversation.
23 Aug 2013 21:10 #38003
by andypugh
As you already (presumably) have a git repositiory all you need to do to try ja3 is
git branch --track ja3 origin/joints_axes3
git checkout ja3
(you might want to try git branch -r to list all the remote branches and to check the spelling)
Then "make" should build you a ja3 system rather than the current one.
You probably have to commit your changes to genhexins.h before it will let you change branches. I use git-gui for that.
wiki.linuxcnc.org/cgi-bin/wiki.pl?Git
You probably then need to cherry-pick your genhexkins changes back into your new ja3 branch (in git-gui you can do that in the "view all branch history" view)
Some of the configs have been changed in the ja3 branch to reflect the INI file config changes. One of them is sim/axis/axis_mm and that can be used as a guideline.
However, if you simply copy and paste all of the [AXIS_N] sections and re-paste in their entirity, then change [AXIS_0] to separate but identical [AXIS_X] and [JOINT_0] sections it will probably work fine because the spurious entries in each section will simply be ignored.
Then you need to add a [KINS] section which contains a KINEMATICS and (I think) NUM_JOINTS entry. (Though I think that these are actually only used by the HAL file, and as your HAL file doesn't look for them...)
In the HAL file you need to do a blanket search and replace of axis.N.joint-pos-cmd (and friends) for joint.N.position-cmd. Adding a "show pin" to the HAL file just after the loadrt motmod line will give you a pin list as a crib-sheet of the new pin names. Then it is a case of starting LinuxCNC from the command line, and changing stuff till it works, based on reading the error messages.
Do make sure you are running the version of LinuxCNC you thik you are running. If the splash-screen doesn't mention joints-axes then you have forgotten the . ./rip-environment and you are running the unmodified config Don't ask me how I know, OK?
if you make a copy of the existing config folder, then you can still run that under the installed system, then modify the copy to suit ja3.
Replied by andypugh on topic Hexapod Controls
I did a quick search and didn't find much on Joints_Axes3 (though I've seen it mentioned in other threads). Can you point me towards some more info on it?
Thanks
As you already (presumably) have a git repositiory all you need to do to try ja3 is
git branch --track ja3 origin/joints_axes3
git checkout ja3
(you might want to try git branch -r to list all the remote branches and to check the spelling)
Then "make" should build you a ja3 system rather than the current one.
You probably have to commit your changes to genhexins.h before it will let you change branches. I use git-gui for that.
wiki.linuxcnc.org/cgi-bin/wiki.pl?Git
You probably then need to cherry-pick your genhexkins changes back into your new ja3 branch (in git-gui you can do that in the "view all branch history" view)
Some of the configs have been changed in the ja3 branch to reflect the INI file config changes. One of them is sim/axis/axis_mm and that can be used as a guideline.
However, if you simply copy and paste all of the [AXIS_N] sections and re-paste in their entirity, then change [AXIS_0] to separate but identical [AXIS_X] and [JOINT_0] sections it will probably work fine because the spurious entries in each section will simply be ignored.
Then you need to add a [KINS] section which contains a KINEMATICS and (I think) NUM_JOINTS entry. (Though I think that these are actually only used by the HAL file, and as your HAL file doesn't look for them...)
In the HAL file you need to do a blanket search and replace of axis.N.joint-pos-cmd (and friends) for joint.N.position-cmd. Adding a "show pin" to the HAL file just after the loadrt motmod line will give you a pin list as a crib-sheet of the new pin names. Then it is a case of starting LinuxCNC from the command line, and changing stuff till it works, based on reading the error messages.
Do make sure you are running the version of LinuxCNC you thik you are running. If the splash-screen doesn't mention joints-axes then you have forgotten the . ./rip-environment and you are running the unmodified config Don't ask me how I know, OK?
if you make a copy of the existing config folder, then you can still run that under the installed system, then modify the copy to suit ja3.
Please Log in or Create an account to join the conversation.
26 Aug 2013 22:29 #38112
by ddmotim
Replied by ddmotim on topic Hexapod Controls
So I tried ja3. I used git to commit my changes, then checked out with ja3. I went through and modified the things you recommended, and tried running my machine. The error message came up and I worked my way through a couple things, but now it says Pin 'joint.0.motor-pos-cmd' does not exist (correct me if i'm wrong, but this makes me think that joints-axes isn't working as it should)
I went back to make sure and I am running Linux 2.5.2. The splash screen says nothing about joints-axes (as long as you mean the image that pops up when I open linuxcnc), but when I tried to make sure I have the rip-environment working, the terminal says "This script only needs to be run once per shell session."
I went back to make sure and I am running Linux 2.5.2. The splash screen says nothing about joints-axes (as long as you mean the image that pops up when I open linuxcnc), but when I tried to make sure I have the rip-environment working, the terminal says "This script only needs to be run once per shell session."
Please Log in or Create an account to join the conversation.
26 Aug 2013 23:08 #38113
by andypugh
Replied by andypugh on topic Hexapod Controls
The icons and menu items will still load the installed version. You need to start LinuxCNC with the command "linuxcnc" from the same terminal as you issued the . ./scripts/rip-environment in.
Please Log in or Create an account to join the conversation.
Time to create page: 0.126 seconds