did anyone success install linuxcnc-ethercat on rpi4?

More
5 years 7 months ago #203768 by thang
Nice guys, Linuxcnc-ethercat now is built, I will start test it on my driver and write a short tutorial

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

More
5 years 7 months ago - 5 years 7 months ago #204011 by thang
Here is a short tutorial to install linuxcnc ethercat, thank Hakan and Grotius for making my life easier :laugh:

1. Installing linuxcnc image:
Code:
Download official image: www.linuxcnc.org/iso/linuxcnc-2.8.1-pi4.zip Flash SD card. setting up system

2. Installing etherlab master
Code:
sudo apt-get update sudo apt-get dist-upgrade sudo apt-get install bison flex libssl-dev sudo apt-get install linux-headers-4.19.71-rt24-v7l+ sudo wget -P /usr/include/tools/ https://raw.githubusercontent.com/raspberrypi/linux/rpi-4.19.y/tools/include/tools/be_byteshift.h sudo wget -P /usr/include/tools/ https://raw.githubusercontent.com/raspberrypi/linux/rpi-4.19.y/tools/include/tools/le_byteshift.h cd /usr/src/linux-headers-4.19.71-rt24-v7l+/ sudo make -i modules_prepare sudo apt install -y build-essential libtool automake tree dkms git mercurial cd mkdir ethercat cd ethercat git clone http://github.com/icshwi/etherlabmaster make init echo "ENABLE_CYCLES = NO" > configure/CONFIG_OPTIONS.local make build make install echo "ETHERCAT_MASTER0=eth0" > ethercatmaster.local make dkms_add make dkms_build make dkms_install make setup # Reboot or start manually by sudo systemctl start ethercat # Checking ethercat sudo systemctl status ethercat.service

3. Installing linuxcnc-ethercat
Code:
sudo apt-get install linuxcnc-uspace-dev sudo ln -s /opt/etherlab/include/*.h /usr/include/linuxcnc/ sudo ln -s /opt/etherlab/lib/lib* /usr/lib/ git clone http://github.com/sittner/linuxcnc-ethercat.git cd linuxcnc-ethercat make

4. You are now can use lcec_conf and lcec.so in linuxcnc-ethercat/src folder
Code:
Copy lcec_conf to config folder Copy lcec.so to usr/lib/linuxcnc/modules

5. If you are using linuxcnc-dev
Code:
git clone github.com/grotius-cnc/linuxcnc-ethercat # Set your includepath in the /configure.mk file to point to halcompile cd linxucnc-ethercat make make install

Reference: forum.linuxcnc.org/10-advanced-configura...at-on-raspberry-pi-4
Last edit: 5 years 7 months ago by thang. Reason: Insert reference link
The following user(s) said Thank You: tommylight

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

More
4 years 10 months ago #229941 by virencq
One question remains, can we use EtherCat (For Servo drives) along with GPIO's (for Inputs/outputs). Mainly for cost savings.

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

More
4 years 10 months ago #229954 by rodw
Yes you can. The pin function needs to be correctly set for the purpose.

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

Time to create page: 0.065 seconds
Powered by Kunena Forum