v2.9 and not the perpendicularity of X and Y

More
20 Nov 2025 19:47 - 22 Nov 2025 10:06 #338823 by abs32
SOLVED  -
 matrixkins
is a standard technique for correcting the curvature of the portal in the LinuxCNC 2.10 kernel (and above). The issue of mutual correction of XYZ coordinates is resolved by specifying correction coefficients. However, this component is provided for single-engine machines, i.e. XYZ schemes. To use this software correction, changes must be made to the ini machine configuration files. Hal file does not require correction. MAN does not give these examples, см. github.com/LinuxCNC/linuxcnc/blob/master...ents/matrixkins.comp. However, in the ini file 
instead of -
KINEMATICS = trivkins coordinates=XYZ
set -
KINEMATICS=matrixkins
then explicitly specify non-zero correction factors, for example -
halcmd setp matrixkins.C_yx -0.00252427184466  

You will find the coefficient values and the transformation matrix in MAN.
The halcmd setp matrixkins.C_yx correction command -0.00252427184466 can be executed in the terminal (not while the machine is moving!), i.e. the parameter can be changed on the fly.

In case you have a multi-engine XXYZ configuration, etc., you need to change the source code of the matrixkins component (github.com/LinuxCNC/linuxcnc/blob/master...ents/matrixkins.comp), similar to www.forum.linuxcnc.org/38-general-linuxc...xyyz?start=20#338894

+ sudo halcompile --install matrixkins.comp


 
Last edit: 22 Nov 2025 10:06 by abs32.

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

More
20 Nov 2025 19:57 #338825 by abs32
ln -s /usr/lib/linuxcnc/modules/maxkins.so /usr/lib/linuxcnc/modules/matrixkins.so
# ll /usr/lib/linuxcnc/modules/ma*
-rw-r--r-- 1 root root 15240 окт 23 01:43 /usr/lib/linuxcnc/modules/maj3.so
-rw-r--r-- 1 root root 15680 окт 23 01:43 /usr/lib/linuxcnc/modules/match8.so
-rw-r--r-- 1 root root 14800 окт 23 01:43 /usr/lib/linuxcnc/modules/matrix_kb.so
lrwxrwxrwx 1 root root 36 ноя 20 22:52 /usr/lib/linuxcnc/modules/matrixkins.so -> /usr/lib/linuxcnc/modules/maxkins.so
-rw-r--r-- 1 root root 15512 окт 23 01:43 /usr/lib/linuxcnc/modules/max31855.so
-rw-r--r-- 1 root root 14704 окт 23 01:43 /usr/lib/linuxcnc/modules/maxkins.so

Start = abort,
=============
Debug file information:
Note: Using POSIX realtime
4.hal:16: /usr/bin/rtapi_app exited without becoming ready
4.hal:16: insmod for matrixkins failed, returned -1
1358
Stopping realtime threads
Unloading hal components
maxkins: not loaded
<commandline>:0: exit value: 255
<commandline>:0: rmmod failed, returned -1
<commandline>:0: unloadrt failed

ЧЯДНТ? What I Do Wrong?

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

More
21 Nov 2025 08:30 #338865 by Aciera
Appologies, it seems that 'matrixkins' is not in version 2.9 but in version 2.10.

you'll want to remove the link to 'maxkins'
lrwxrwxrwx 1 root root 36 ноя 20 22:52 /usr/lib/linuxcnc/modules/matrixkins.so -> /usr/lib/linuxcnc/modules/maxkins.so


It should be possible to install 'matrixkins' using the 'halcompile' tool, this will require the linuxcnc-dev package though. To check if 'halcompile' is installed try
halcompile -h

if that works you can copy the contents from here:
github.com/LinuxCNC/linuxcnc/blob/master...ents/matrixkins.comp
to a file named 'matrixkins.comp', Then navigate to the location of the file in terminal and install it with:
sudo halcompile --install matrixkins.comp

If halcompile is not installed you would need to install the 'linuxcnc-dev' package:
sudo apt install linuxcnc-dev

NOTE though that I am generally unfamiliar with deb installs as I usually work with locally built installations so I'm not sure if installing 'linuxcnc-dev' will have any consequences to your current installation.

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

More
21 Nov 2025 08:49 #338866 by abs32
Thanks for the tips. I deleted sl. Linuxcnc-dev, of course, is installed.
======
# halcompile -h
halcompile: Build, compile, and install LinuxCNC HAL components
///

halcompile --install matrixkins.comp
Traceback (most recent call last):
File "/usr/bin/halcompile", line 1553, in <module>
main()
File "/usr/bin/halcompile", line 1523, in main
process(f, mode, outfile)
File "/usr/bin/halcompile", line 1363, in process
a, b = parse(filename)
^^^^^^^^^^^^^^^
File "/usr/bin/halcompile", line 434, in parse
f = open(filename).read()
^^^^^^^^^^^^^^
FileNotFoundError: [Errno 2] No such file or directory: 'matrixkins.comp'

find / -name matrixkins.comp
is null

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

More
21 Nov 2025 09:17 #338868 by Aciera
Did you get 'matrixkins.comp' from the github page as linked in my last post?

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

More
21 Nov 2025 09:21 - 21 Nov 2025 09:21 #338870 by abs32
pardone, -
wget github.com/LinuxCNC/linuxcnc/blob/master...ents/matrixkins.comp
--2025-11-21 12:20:08-- github.com/LinuxCNC/linuxcnc/blob/master...ents/matrixkins.comp
Распознаётся github.com (github.com)… 140.82.121.3
Подключение к github.com (github.com)|140.82.121.3|:443... соединение установлено.
HTTP-запрос отправлен. Ожидание ответа… 200 OK

halcompile --install matrixkins.comp
Traceback (most recent call last):
File "/usr/bin/halcompile", line 1553, in <module>
main()
File "/usr/bin/halcompile", line 1523, in main
process(f, mode, outfile)
File "/usr/bin/halcompile", line 1363, in process
a, b = parse(filename)
^^^^^^^^^^^^^^^
File "/usr/bin/halcompile", line 441, in parse
a, b = f.split("\n;;\n", 1)
^^^^
ValueError: not enough values to unpack (expected 2, got 1)
Last edit: 21 Nov 2025 09:21 by abs32.

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

More
21 Nov 2025 09:25 #338871 by Aciera
Try copy/pasting the contents of the file:
raw.githubusercontent.com/LinuxCNC/linux...ents/matrixkins.comp

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

More
21 Nov 2025 09:42 - 21 Nov 2025 09:43 #338872 by abs32
Thank you, of course, I'm a hat and stupidly downloaded the html page. We have advanced

halcompile --install matrixkins.comp
Compiling realtime matrixkins.c
Linking matrixkins.so
cp matrixkins.so /usr/lib/linuxcnc/modules/

start abort -
4.hal:22: parameter or pin 'matrixkins.C_xy' not found

4.hal file -
setp matrixkins.C_xy 0  # Skew Y axis towards X axis
setp matrixkins.C_xx 1  # X axis scale
setp matrixkins.C_xz 0  # Skew Z axis towards X axis
setp matrixkins.C_yx 0  # Skew X axis towards Y axis
setp matrixkins.C_yy 1  # Y axis scale
setp matrixkins.C_yz 0  # Skew Z axis towards Y axis
setp matrixkins.C_zx 0  # Skew X axis towards Z axis
setp matrixkins.C_zy 0  # Skew Y axis towards Z axis
setp matrixkins.C_zz 1  # Z axis scale
Last edit: 21 Nov 2025 09:43 by abs32.

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

More
21 Nov 2025 09:52 #338873 by Aciera
Comment out or remove all lines with 'matrixkins' and try to start the config, if it starts open the 'show hal configuration' tool and check if 'matrixkins' has been loaded and the parameters have been created:
 
Attachments:

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

More
21 Nov 2025 10:09 #338874 by abs32
Bravo, thank you!
The interface immediately changed - before home, a choice of individual motors is now available!
There was an error in the perception of the hal file configuration when I tried to write down the parameters
setp matrixkins.C_xy 0

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

Time to create page: 0.104 seconds
Powered by Kunena Forum