Scara with ball spline in Z,C axis

More
5 years 6 months ago #207382 by nhanpham
Hi everyone!
I am new in linuxcnc and I am trying to do a scara robot..
My scara is using ball spline to control Z, C axis.
With ball spline, when the C Axis rotary will do Z-axis move.
This is an issue with scarakins kinematic.
Can you help me fix this?
If you have any ideas, I will be forever grateful!.
thank you very much!!

Please Log in to join the conversation.

More
5 years 6 months ago #207419 by andypugh
The scarkins file is here:
github.com/LinuxCNC/linuxcnc/blob/master...nematics/scarakins.c

You probably need to re-arrange the calculations in the kinematicsForward and kinematicsInverse functions. The rest of the file can probably be left as-is. Do you know C?

scarakins is a simple enough module that you can compile it standalone to suit your purposes.

modify the file then
Code:
sudo halcompile --install scarkins.c
should compile it and install it on your system.

You should probably rename the file, so that next update your kins is not overwritten by the original scarakins. If you do rename the file it is important to update line 204 to match.

Please Log in to join the conversation.

More
5 years 6 months ago #207436 by nhanpham

andypugh wrote: The scarkins file is here:
github.com/LinuxCNC/linuxcnc/blob/master...nematics/scarakins.c

You probably need to re-arrange the calculations in the kinematicsForward and kinematicsInverse functions. The rest of the file can probably be left as-is. Do you know C?

scarakins is a simple enough module that you can compile it standalone to suit your purposes.

modify the file then

Code:
sudo halcompile --install scarkins.c
should compile it and install it on your system.

You should probably rename the file, so that next update your kins is not overwritten by the original scarakins. If you do rename the file it is important to update line 204 to match.


Yes, I have knowledge about C and python
But I'm newbie for scara robot, I don't have knowledge about kinematic for ball spline.
I bought an old scara machine from IAI IX. I'm using linuxcnc to control it.

thank you for your help

Please Log in to join the conversation.

More
5 years 6 months ago #207437 by andypugh

annhandt09 wrote: But I'm newbie for scara robot, I don't have knowledge about kinematic for ball spline.


I don't really understand the problem that you are having, or why it matters that there is a ball spline.

Can you explain exactly what scarkins gets wrong for your machine?

Please Log in to join the conversation.

More
5 years 6 months ago #207444 by nhanpham

andypugh wrote:

annhandt09 wrote: But I'm newbie for scara robot, I don't have knowledge about kinematic for ball spline.


I don't really understand the problem that you are having, or why it matters that there is a ball spline.

Can you explain exactly what scarkins gets wrong for your machine?


Hi,
With ball spline
- Z, C motor control the same vitme.
- When the C motor rotates then the Z-axis is changed
- When the Z motor rotates then the C axis does not change.

ball Spline Video 1
ball Spline Video 2

I added videos to describe how ball spline working

can we need a kinematic for Z and C?

Sorry for my English

thank you for your help

Please Log in to join the conversation.

More
5 years 6 months ago #207446 by andypugh
In this case there is probably no need to edit the kinematics, though that is definitely one way to do it.

You can probably do it it in HAL.

I think that you just pass the C axis position to the C motor and and Z + C to the Z motor. Use the HAL "sum2" component between the motor-pos-cmd output pins and the stepgen/pid input pins of the Z motor.

Please Log in to join the conversation.

More
5 years 6 months ago #207449 by nhanpham

andypugh wrote: In this case there is probably no need to edit the kinematics, though that is definitely one way to do it.

You can probably do it it in HAL.

I think that you just pass the C axis position to the C motor and and Z + C to the Z motor. Use the HAL "sum2" component between the motor-pos-cmd output pins and the stepgen/pid input pins of the Z motor.


it is:

loadrt sum2 count=1
addf sum2.0 servo-thread

setp sum2.0.gain0 1
setp sum2.0.gain1 1

net J2pos sum2.0.in1 <= joint.2.motor-pos-cmd
net J3pos hm2_[HOSTMOT2](BOARD).0.stepgen.03.position-cmd sum2.0.in0 <= joint.3.motor-pos-cmd
net sum2.0.out => hhm2_[HOSTMOT2](BOARD).0.stepgen.02.position-cmd


I will test this in next week

thank you very much

Please Log in to join the conversation.

More
5 years 5 months ago #207528 by newbynobi
Do you have your Scara working?
If so, please post your config, as I got the same problem on a Bosch Scara

Norbert

Please Log in to join the conversation.

More
5 years 5 months ago #207539 by nhanpham

newbynobi wrote: Do you have your Scara working?
If so, please post your config, as I got the same problem on a Bosch Scara

Norbert


hi, I will check it and inform to this topic next week.

Please Log in to join the conversation.

More
5 years 5 months ago #207701 by nhanpham

newbynobi wrote: Do you have your Scara working?
If so, please post your config, as I got the same problem on a Bosch Scara

Norbert


Hi, you can check my config. I am testing this and it's working
Code:
loadrt sum2 count=1 addf sum2.0 servo-thread #set gain for sum2 = in0*gain0 + in1*gain1 setp sum2.0.gain0 1 #gain1 = (gear-cAxis/gear-zAxis) setp sum2.0.gain1 0.066667 #set Joint2 to sum input 0 net J2pos sum2.0.in0 <= joint.2.motor-pos-cmd #set Joint2 to C-Axis and sum input 1 net J3pos hm2_[HOSTMOT2](BOARD).0.stepgen.03.position-cmd sum2.0.in1 <= joint.3.motor-pos-cmd # set SUM to Z-axis net J2posE hm2_[HOSTMOT2](BOARD).0.stepgen.02.position-cmd <= sum2.0.out

Please Log in to join the conversation.

Time to create page: 0.354 seconds
Powered by Kunena Forum