For the impatient, here are all the commands after installing the OS with a GUI
"The forum always changes the hyperlinks, so when you do the "git" clone commands, type out the full hyperlink"
sudo apt update
sudo apt dist-upgrade
sudo apt install linux-image-rt-amd64
sudo apt install linux-headers-rt-amd64
sudo reboot
uname -a
dpkg --list | grep linux-image
sudo apt remove --purge linux-image-(THE REST OF THE KERNEL NAME FROM GREP)
sudo apt install git build-essential
git clone
github.com/LinuxCNC/linuxcnc.git linuxcnc-dev
cd linuxcnc-dev
git checkout master
cd debian
./configure uspace no-docs
cd ..
dpkg-checkbuilddeps
sudo apt install "
LIST OF DEPS COPIED FROM DPKG-CHECKBUILDDEPS"
dpkg-checkbuilddeps
cd src
./autogen.sh
./configure --with-realtime=uspace --disable-build-documentation-translation
make
sudo make setuid
. ../scripts/rip-environment
linuxcnc
(this will fail and you run the script below to get LCNC working)
~/linuxcnc-dev/lib/python/qtvcp/designer/install_script
2
(YOU CAN CHOOSE 1 OR 2 DEPENDING ON IF YOU WANT TO EDIT OR NOT)
cd ~
git clone
gitlab.com/etherlab.org/ethercat.git ethercat-master
cd ethercat-master
git checkout stable-1.6
./bootstrap
sudo lspci -v
./configure --sysconfdir=/etc/ --disable-8139too --enable-userlib --enable-generic
make all modules
sudo su
make modules_install install
depmod
exit
ip a
sudo pico /etc/ethercat.conf
(FIX YOUR MAC ADDRESS AND DEVICE NAME, THEN SAVE AND EXIT)
sudo systemctl enable ethercat.service
sudo systemctl start ethercat.service
sudo systemctl status ethercat.service
sudo chmod 666 /dev/EtherCAT0
ethercat master
sudo pico /etc/udev/rules.d/99-ethercat.rules
(ADD THIS TO THE ABOVE FILE)
KERNEL=="EtherCAT[0-9]", MODE="0777"
(THEN SAVE AND EXIT PICO)
sudo udevadm control --reload-rules
cd ..
git clone
github.com/linuxcnc-ethercat/linuxcnc-ethercat.git linuxcnc-ethercat
cd linuxcnc-ethercat/src/
sudo pico Makefile
(Now comment out part of lines. Just add the “#” where shown below:)
(At line 83 of the code, comment out “lcec configgen”)
user: lcec_conf lcec_devices
#lcec_configgen
(At line 92 of the code, comment out the whole line)
# cp lcec_configgen $(DESTDIR)/usr/bin/
(At lines 113 - 121 of the code, comment out the whole line)
#lcec_configgen: configgen/*.go configgen/*/*.go
# (cd configgen ; go build lcec_configgen.go)
# cp configgen/lcec_configgen .
#configgen/devicelist: configgen/devicelist.go
# (cd configgen ; go build devicelist.go)
#configgen/drivers/drivers.go: configgen/devicelist lcec_devices
# (cd configgen ; go generate)
(THEN SAVE AND EXIT)
cd ..
make clean
make
make install
sudo pico /etc/ld.so.conf
(ADD THIS TO THE ABOVE “ld.so.conf” FILE)
/usr/local/lib
(THEN SAVE AND EXIT PICO)
sudo su
ldconfig -v
exit
Then you setup your XML and LCNC config and that's it...