halcompile 5axiskins.c throws 'syntax error in VERSION script'

More
27 Jul 2023 15:57 #276381 by chowderhead
As usual, I'm in over my head. I'm trying to write custom kinematics by modifying 5axiskins as I thought it might be a good template to work from. I want duplicate axes (e.g., XYYZ) with the Z-joint being a scissor lift. Problem is, when I run halcompile -c 5axiskins, I get the following:

Compiling realtime 5axiskins.c
Linking 5axiskins.so
/usr/bin/ld:5axiskins.ver:2: syntax error in VERSION script
collect2: error: ld returned 1 exit status
make: *** [/usr/share/linuxcnc/Makefile.modinc:123: 5axiskins.so] Error 1

Don't know if this helps diagnosis:
uname -a
Linux jimac 6.1.0-10-rt-amd64 #1 SMP PREEMPT_RT Debian 6.1.38-1 (2023-07-14) x86_64 GNU/Linux

Installed linuxcnc-uspace and linuxcnc-uspace-dev via apt.

Thanks!

Please Log in or Create an account to join the conversation.

More
27 Jul 2023 16:10 #276383 by Aciera

I'm trying to write custom kinematics by modifying 5axiskins as I thought it might be a good template to work from.

The recommended way to build custom kinematics is to modify the 'userkins.comp' template:
4.1. Kinematics module using the userkins.comp templateAnother way to create a custom kinematics module is to adapt the HAL component [i]userkins[/i]. This template component can be modified locally by a user and can be built using halcompile.See the userkins man pages for more information.Note that to create switchable kinematic modules the required modifications are somewhat more complicated.See [i]millturn.comp[/i] as an example of a switchable kinematic module that was created using the [i]userkins.comp[/i] template.
as copied from here linuxcnc.org/docs/devel/html/motion/kinematics.html

'userkins.comp' should be located in the folder '/src/hal/components'
The following user(s) said Thank You: chowderhead

Please Log in or Create an account to join the conversation.

More
27 Jul 2023 21:27 #276403 by chowderhead
Thank you, Aciera. I've successfully compiled and installed the modified userkins component (attached) and added it to the KINS section of ini. Unfortunately, I get 'zissorkins.so: undefined symbol: position_to_mapped_joints' upon starting linuxcnc. As near as I can tell, kinematics.h (included in the component) contains that function.

Appreciate the help.
Attachments:

Please Log in or Create an account to join the conversation.

More
28 Jul 2023 06:20 #276436 by Aciera
I would suggest to drop the mapping of the joints and just assign the joints in the code like in the template (ie use j[0], j[1] and so on).

Please Log in or Create an account to join the conversation.

More
01 Aug 2023 21:17 - 01 Aug 2023 22:21 #276744 by chowderhead
Thanks again, for the advise, but I wanted to maintain joint mapping, so slashed and hacked until I got it working. Since I'm not worth a sh*t with C++, I copied the required functions from kins_utils.c.

Have a follow-on question: With non-linear joint:axis, what's the relationship between .ini [AXIS] MAX_VELOCITY and [JOINT] MAX_VELOCITY? It seems they would no longer be one-to-one, but LCNC complains if [AXIS] exceeds [JOINT]. Here I go again...
Last edit: 01 Aug 2023 22:21 by chowderhead. Reason: chowderhead

Please Log in or Create an account to join the conversation.

More
02 Aug 2023 07:47 #276767 by Aciera

so slashed and hacked until I got it working. Since I'm not worth a sh*t with C++, I copied the required functions from kins_utils.c.

interesting, do you mind sharing your kinematic comp?

Please Log in or Create an account to join the conversation.

More
02 Aug 2023 16:42 #276783 by chowderhead
Sure, there are two versions, one a quadratic fit to the scissor lift motion (zissorkins.c), the other a geometric solution (zissorkins2.c, which a much smarter friend helped me with). The quadratic fit works fine, the geometric solution was just finished this morning and is untested, but does compile.
Attachments:
The following user(s) said Thank You: Aciera

Please Log in or Create an account to join the conversation.

Time to create page: 0.402 seconds
Powered by Kunena Forum