[AUTOMATIC] [XML] [HAL] [INI] [GENERATORS] [ETHERCAT] [LICHUAN]

More
31 Jan 2026 19:16 - 03 Feb 2026 20:53 #342257 by szolkaa
Hi all,
I’d like to share a set of programs for automatically generating LinuxCNC configuration files for EtherCAT setups.
Also presentation:
From LinuxCNC 2.9.8 Debian13 Installation via EtherCat Master to the First Motor Movement.

Github repository contains:
1.Linux installation and setup
2. XML generator
3. HAL generator
4. INI generator
5. DOS-style to UNIX line ending converter
6. Example configuration for XYZ
7. Example configuration for XYYZ

github.com/szolkaa/Automatic-linuxcnc-co...rators-for-ethercat/
Attachments:
Last edit: 03 Feb 2026 20:53 by szolkaa.
The following user(s) said Thank You: andypugh, tommylight, COFHAL, endian, NWE

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

More
25 Feb 2026 23:24 #343514 by tommylight
Thank you.
Should we make this "sticky"?
We would appreciate feedback on this.

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

More
01 Mar 2026 09:49 #343683 by Eisbaeeer
Hi Szolkaa
I own two Lichuan closed loop ethercat controllers. One with 4 motors, one with 1 motor.
Technical specs:
- Lichuan CL57E-4A (4 x closed loop)
- Lichuan OLCE-57H (1 x closed loop)

I tried your genius configuration tool. By importing the xml I get an error. 
Did you see any chance to get the both controllers running with linuxcnc?
Greetings Lars

root@LinuxCNC:/home/linuxcnc/Downloads# python3 XML_Generator.py 
Exception in Tkinter callback
Traceback (most recent call last):
  File "/usr/lib/python3.13/tkinter/__init__.py", line 2071, in __call__
    return self.func(*args)
           ~~~~~~~~~^^^^^^^
  File "/home/linuxcnc/Downloads/XML_Generator.py", line 149, in load_esi
    self.convert()
    ~~~~~~~~~~~~^^
  File "/home/linuxcnc/Downloads/XML_Generator.py", line 198, in convert
    f'       <pdoEntry idx="{e["idx"]}" subIdx="{int(e["sub"]):02}" '
                                                 ~~~^^^^^^^^^^
ValueError: invalid literal for int() with base 10: '#x0'
Exception in Tkinter callback
Traceback (most recent call last):
  File "/usr/lib/python3.13/tkinter/__init__.py", line 2071, in __call__
    return self.func(*args)
           ~~~~~~~~~^^^^^^^
  File "/home/linuxcnc/Downloads/XML_Generator.py", line 149, in load_esi
    self.convert()
    ~~~~~~~~~~~~^^
  File "/home/linuxcnc/Downloads/XML_Generator.py", line 198, in convert
    f'       <pdoEntry idx="{e["idx"]}" subIdx="{int(e["sub"]):02}" '
                                                 ~~~^^^^^^^^^^
ValueError: invalid literal for int() with base 10: '#x0'
Exception in Tkinter callback
Traceback (most recent call last):
  File "/usr/lib/python3.13/tkinter/__init__.py", line 2071, in __call__
    return self.func(*args)
           ~~~~~~~~~^^^^^^^
  File "/home/linuxcnc/Downloads/XML_Generator.py", line 149, in load_esi
    self.convert()
    ~~~~~~~~~~~~^^
  File "/home/linuxcnc/Downloads/XML_Generator.py", line 198, in convert
    f'       <pdoEntry idx="{e["idx"]}" subIdx="{int(e["sub"]):02}" '
                                                 ~~~^^^^^^^^^^
ValueError: invalid literal for int() with base 10: '#x0'
root@LinuxCNC:/home/linuxcnc/Downloads# 
 


 
Attachments:

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

Time to create page: 0.170 seconds
Powered by Kunena Forum