- Posts: 11
- Thank you received: 0
Stuck with installation of Eathercat-Master
10 years 3 months ago #78014
by mfalcon
Stuck with installation of Eathercat-Master was created by mfalcon
hello everyone
I am new in the world of linuxcnc , and I have a limited experience with linux too. I tried several different ways to install eathercat-master software, but all went in vain. I posted my problem here because it seems to me to be caused by my limited experience in installation these packages, not because the nature of ethercat itself.
I found different methods to install eathercat master:
1) wiki.linuxcnc.org/cgi-bin/wiki.pl?EtherCatDriver
in this link it mentions 2 methods:
the first method :
Installation
If you are using the current LinuxCNC Distribution (LCNC 2.6 Debian Wheezy based at time of writing) the installation is pretty simple:
create a file "/etc/apt/sources.list.d/linuxcnc-mds.list":
deb repo.modusoft.de/linuxcnc/wheezy ./
# sudo apt-get update
# sudo apt-get install linuxcnc-ethercat
the result that I get is that " repo.modusoft.de/linuxcnc/wheezy ./" no more exist and gives 502 error.
the second method is:
# git clone github.com/sittner/linuxcnc-ethercat.git linuxcnc-ethercat
# cd linuxcnc-ethercat
(these two lines work well)
and do a
# make
the result that I get when I do make: configure.mk:8: *** halcompile/comp executable not found or set. Stop.
make: *** [config.mk] Error 2
there is a not in the end of method 2 that I could not understand too:
You need etherlabmaster-dev (from the repos mentioned above) and linuxcnc-dev to be installed for this.
2) here another method github.com/sittner/ec-debianize
# ./configure -a
# cd ..
# dpkg-checkbuilddeps
# dpkg-buildpackage
the result that I get: the terminal refuses the -a with configure, and when I remove -a and I the first line without it, I get this error in the end of the command output :
configure: error: Failed to find Linux sources. Use --with-linux-dir!
I do not know if it was better to publish this topic in hal component forum, but it seems to me that these erronous results are caused by missing commands/packages that I am not aware about.
thanks
Note: I forgot to mention that my linuxcnc is based of RT-Preemption patch.
I am new in the world of linuxcnc , and I have a limited experience with linux too. I tried several different ways to install eathercat-master software, but all went in vain. I posted my problem here because it seems to me to be caused by my limited experience in installation these packages, not because the nature of ethercat itself.
I found different methods to install eathercat master:
1) wiki.linuxcnc.org/cgi-bin/wiki.pl?EtherCatDriver
in this link it mentions 2 methods:
the first method :
Installation
If you are using the current LinuxCNC Distribution (LCNC 2.6 Debian Wheezy based at time of writing) the installation is pretty simple:
create a file "/etc/apt/sources.list.d/linuxcnc-mds.list":
deb repo.modusoft.de/linuxcnc/wheezy ./
# sudo apt-get update
# sudo apt-get install linuxcnc-ethercat
the result that I get is that " repo.modusoft.de/linuxcnc/wheezy ./" no more exist and gives 502 error.
the second method is:
# git clone github.com/sittner/linuxcnc-ethercat.git linuxcnc-ethercat
# cd linuxcnc-ethercat
(these two lines work well)
and do a
# make
the result that I get when I do make: configure.mk:8: *** halcompile/comp executable not found or set. Stop.
make: *** [config.mk] Error 2
there is a not in the end of method 2 that I could not understand too:
You need etherlabmaster-dev (from the repos mentioned above) and linuxcnc-dev to be installed for this.
2) here another method github.com/sittner/ec-debianize
# ./configure -a
# cd ..
# dpkg-checkbuilddeps
# dpkg-buildpackage
the result that I get: the terminal refuses the -a with configure, and when I remove -a and I the first line without it, I get this error in the end of the command output :
configure: error: Failed to find Linux sources. Use --with-linux-dir!
I do not know if it was better to publish this topic in hal component forum, but it seems to me that these erronous results are caused by missing commands/packages that I am not aware about.
thanks
Note: I forgot to mention that my linuxcnc is based of RT-Preemption patch.
Please Log in to join the conversation.
- tommylight
-
- Offline
- Administrator
-
Less
More
- Posts: 22010
- Thank you received: 3
10 years 3 months ago #78087
by tommylight
Replied by tommylight on topic Stuck with installation of Eathercat-Master
I am not sure, but i think you also need to copy the linuxcnc git master to your computer, so check the wiki and find the "run in place" how to, or how to pull a git version of linuxcnc.
Please Log in to join the conversation.
10 years 2 months ago #78323
by Cpk_Rbt
Replied by Cpk_Rbt on topic Stuck with installation of Eathercat-Master
There are two different things that need to be installed. The IgH EtherCAT Master and sittner's EtherCAT HAL Driver.
IgH Etherlab EtherCAT Master
1. Download Etherlab Ethercat from the website www.etherlab.org/en/ethercat/
2. Extract the tarball
3. Run the configuration tool and build (omit the --enable-r8169 if not using the Realtek 8169 driver)
4. Become root
5. Install the software
6. Install the system service
7. Check HWaddr of network device
8. Edit EtherCAT master config to use the MAC address of your chosen network device
9. Add your MAC address
10. Edit the DEVICE_MODULES line, adding the r8169 device (again, omit if not using the Realtek 8169 driver)
11. Update Configuration
12. Give normal users read access to EtherCAT character devices
13. Make the master executable
14. Start the master service
15. Operation can be observed by viewing the Syslog messages
LinuxCNC EtherCAT HAL Driver
1. Download the latest version from github
2. Install etherlabmaster-dev
3. Open the git directory
4. Build
5. Copy the built binary to the ethercat directory
IgH Etherlab EtherCAT Master
1. Download Etherlab Ethercat from the website www.etherlab.org/en/ethercat/
2. Extract the tarball
Code:
tar xjf ethercat-1.5.2.tar.bz2
cd ethercat-1.5.2/
Code:
./configure --enable-r8169
make all modules
Code:
sudo su
Code:
make modules_install install
depmod
Code:
mkdir /etc/sysconfig/
cp /opt/etherlab/etc/sysconfig/ethercat /etc/sysconfig/ethercat
ln -s /opt/etherlab/etc/init.d/ethercat /etc/init.d/ethercat
Code:
ifconfig
Code:
sudo nano /etc/default/ethercat
Code:
MASTER0_DEVICE="00:00:00:00:00:00"
Code:
DEVICE_MODULES=”r8169”
Code:
sudo update-ethercat-config
Code:
echo KERNEL==\"EtherCAT[0-9]*\", MODE=\"0664\" > /etc/udev/rules.d/99-EtherCAT.rules
Code:
chmod +x /opt/etherlab/etc/init.d/ethercat
Code:
/etc/init.d/ethercat start
Code:
dmesg
LinuxCNC EtherCAT HAL Driver
1. Download the latest version from github
Code:
cd && git clone https://github.com/sittner/linuxcnc-ethercat.git
Code:
sudo apt-get install etherlabmaster-dev
Code:
cd linuxcnc-ethercat/src
Code:
make
sudo make install
Code:
sudo cp lcec_conf /usr/bin/
Please Log in to join the conversation.
10 years 1 month ago #79837
by steva
Replied by steva on topic Stuck with installation of Eathercat-Master
Hello Everyone,
I successfully installed all to point 4 (build hal driver)
Terminal gives me the following text:
etv@etv:~/linuxcnc-ethercat/src$ make
make[1]: Entering directory `/home/etv/linuxcnc-ethercat/src'
make[1]: Warning: File `lcec_conf' has modification time 2.4e+04 s in the future
make[1]: Nothing to be done for `all'.
make[1]: warning: Clock skew detected. Your build may be incomplete.
make[1]: Leaving directory `/home/etv/linuxcnc-ethercat/src'
make[1]: Entering directory `/home/etv/linuxcnc-ethercat/src'
make EXTRA_CFLAGS="-Os -g -I. -I/usr/realtime-3.4-9-rtai-686-pae/include -I. -I/usr/realtime-3.4-9-rtai-686-pae/include -I/usr/include/i386-linux-gnu -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=0 -fno-math-errno -funsafe-math-optimizations -fno-rounding-math -fno-signaling-nans -fcx-limited-range -mhard-float -DRTAI=3 -fno-fast-math -mieee-fp -fno-unsafe-math-optimizations -DRTAPI -D_GNU_SOURCE -Drealtime -D__MODULE__ -I/usr/include/linuxcnc -Wframe-larger-than=2560" KBUILD_EXTRA_SYMBOLS="/usr/realtime-3.4-9-rtai-686-pae/modules/linuxcnc/Module.symvers /usr/realtime-3.4-9-rtai-686-pae/modules/ethercat/Module.symvers" -C /usr/src/linux-headers-3.4-9-rtai-686-pae SUBDIRS=`pwd` CC=gcc V=0 modules
make[2]: Entering directory `/usr/src/linux-headers-3.4-9-rtai-686-pae'
CC [M] /home/etv/linuxcnc-ethercat/src/lcec_main.o
/home/etv/linuxcnc-ethercat/src/lcec_main.c: In function ‘lcec_request_lock’:
/home/etv/linuxcnc-ethercat/src/lcec_main.c:913:3: error: implicit declaration of function ‘rtapi_mutex_get’ [-Werror=implicit-function-declaration]
/home/etv/linuxcnc-ethercat/src/lcec_main.c: In function ‘lcec_release_lock’:
/home/etv/linuxcnc-ethercat/src/lcec_main.c:918:3: error: implicit declaration of function ‘rtapi_mutex_give’ [-Werror=implicit-function-declaration]
cc1: some warnings being treated as errors
make[5]: *** [/home/etv/linuxcnc-ethercat/src/lcec_main.o] Error 1
make[4]: *** [_module_/home/etv/linuxcnc-ethercat/src] Error 2
make[3]: *** [sub-make] Error 2
make[2]: *** [all] Error 2
make[2]: Leaving directory `/usr/src/linux-headers-3.4-9-rtai-686-pae'
make[1]: *** [lcec.ko] Error 2
make[1]: Leaving directory `/home/etv/linuxcnc-ethercat/src'
make: *** [all] Error 2
etv@etv:~/linuxcnc-ethercat/src$
Any ideas what the problem is?
I successfully installed all to point 4 (build hal driver)
Terminal gives me the following text:
etv@etv:~/linuxcnc-ethercat/src$ make
make[1]: Entering directory `/home/etv/linuxcnc-ethercat/src'
make[1]: Warning: File `lcec_conf' has modification time 2.4e+04 s in the future
make[1]: Nothing to be done for `all'.
make[1]: warning: Clock skew detected. Your build may be incomplete.
make[1]: Leaving directory `/home/etv/linuxcnc-ethercat/src'
make[1]: Entering directory `/home/etv/linuxcnc-ethercat/src'
make EXTRA_CFLAGS="-Os -g -I. -I/usr/realtime-3.4-9-rtai-686-pae/include -I. -I/usr/realtime-3.4-9-rtai-686-pae/include -I/usr/include/i386-linux-gnu -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=0 -fno-math-errno -funsafe-math-optimizations -fno-rounding-math -fno-signaling-nans -fcx-limited-range -mhard-float -DRTAI=3 -fno-fast-math -mieee-fp -fno-unsafe-math-optimizations -DRTAPI -D_GNU_SOURCE -Drealtime -D__MODULE__ -I/usr/include/linuxcnc -Wframe-larger-than=2560" KBUILD_EXTRA_SYMBOLS="/usr/realtime-3.4-9-rtai-686-pae/modules/linuxcnc/Module.symvers /usr/realtime-3.4-9-rtai-686-pae/modules/ethercat/Module.symvers" -C /usr/src/linux-headers-3.4-9-rtai-686-pae SUBDIRS=`pwd` CC=gcc V=0 modules
make[2]: Entering directory `/usr/src/linux-headers-3.4-9-rtai-686-pae'
CC [M] /home/etv/linuxcnc-ethercat/src/lcec_main.o
/home/etv/linuxcnc-ethercat/src/lcec_main.c: In function ‘lcec_request_lock’:
/home/etv/linuxcnc-ethercat/src/lcec_main.c:913:3: error: implicit declaration of function ‘rtapi_mutex_get’ [-Werror=implicit-function-declaration]
/home/etv/linuxcnc-ethercat/src/lcec_main.c: In function ‘lcec_release_lock’:
/home/etv/linuxcnc-ethercat/src/lcec_main.c:918:3: error: implicit declaration of function ‘rtapi_mutex_give’ [-Werror=implicit-function-declaration]
cc1: some warnings being treated as errors
make[5]: *** [/home/etv/linuxcnc-ethercat/src/lcec_main.o] Error 1
make[4]: *** [_module_/home/etv/linuxcnc-ethercat/src] Error 2
make[3]: *** [sub-make] Error 2
make[2]: *** [all] Error 2
make[2]: Leaving directory `/usr/src/linux-headers-3.4-9-rtai-686-pae'
make[1]: *** [lcec.ko] Error 2
make[1]: Leaving directory `/home/etv/linuxcnc-ethercat/src'
make: *** [all] Error 2
etv@etv:~/linuxcnc-ethercat/src$
Any ideas what the problem is?
Please Log in to join the conversation.
10 years 1 month ago #79838
by Cpk_Rbt
These lines stick out as some likely suspects.
Make sure your system time is correct (run date in a terminal and see what it outputs)
Check the date/time on the files
You might be able to get around any time discrepancies by updating the timestamps of all the files to match your system time
Replied by Cpk_Rbt on topic Stuck with installation of Eathercat-Master
steva wrote: make[1]: Warning: File `lcec_conf' has modification time 2.4e+04 s in the future
make[1]: warning: Clock skew detected. Your build may be incomplete.
These lines stick out as some likely suspects.
Make sure your system time is correct (run date in a terminal and see what it outputs)
Check the date/time on the files
Code:
ls -l --full-time
You might be able to get around any time discrepancies by updating the timestamps of all the files to match your system time
Code:
touch -c *
Please Log in to join the conversation.
10 years 1 month ago #79841
by Cpk_Rbt
Replied by Cpk_Rbt on topic Stuck with installation of Eathercat-Master
The current git revision of linuxcnc-ethercat comes with one file mis-named. configure.mk should be config.mk
Code:
mv configure.mk config.mk
Please Log in to join the conversation.
10 years 1 month ago #79849
by steva
Replied by steva on topic Stuck with installation of Eathercat-Master
I have new issue:
etv@etv:~/linuxcnc-ethercat/src$ make
make[1]: Entering directory `/home/etv/linuxcnc-ethercat/src'
user.mk:10: warning: overriding commands for target `install'
/usr/share/linuxcnc/Makefile.modinc:95: warning: ignoring old commands for target `install'
make[1]: Nothing to be done for `all'.
make[1]: Leaving directory `/home/etv/linuxcnc-ethercat/src'
make[1]: Entering directory `/home/etv/linuxcnc-ethercat/src'
realtime.mk:37: warning: overriding commands for target `install'
/usr/share/linuxcnc/Makefile.modinc:95: warning: ignoring old commands for target `install'
make EXTRA_CFLAGS="-Os -g -I. -I/usr/realtime-3.4-9-rtai-686-pae/include -I. -I/usr/realtime-3.4-9-rtai-686-pae/include -I/usr/include/i386-linux-gnu -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=0 -fno-math-errno -funsafe-math-optimizations -fno-rounding-math -fno-signaling-nans -fcx-limited-range -mhard-float -DRTAI=3 -fno-fast-math -mieee-fp -fno-unsafe-math-optimizations -DRTAPI -D_GNU_SOURCE -Drealtime -D__MODULE__ -I/usr/include/linuxcnc -Wframe-larger-than=2560" KBUILD_EXTRA_SYMBOLS="/usr/realtime-3.4-9-rtai-686-pae/modules/linuxcnc/Module.symvers /usr/realtime-3.4-9-rtai-686-pae/modules/ethercat/Module.symvers" -C /usr/src/linux-headers-3.4-9-rtai-686-pae SUBDIRS=`pwd` CC=gcc V=0 modules
make[2]: Entering directory `/usr/src/linux-headers-3.4-9-rtai-686-pae'
CC [M] /home/etv/linuxcnc-ethercat/src/lcec_main.o
/home/etv/linuxcnc-ethercat/src/lcec_main.c: In function ‘lcec_request_lock’:
/home/etv/linuxcnc-ethercat/src/lcec_main.c:915:3: error: implicit declaration of function ‘rtapi_mutex_get’ [-Werror=implicit-function-declaration]
/home/etv/linuxcnc-ethercat/src/lcec_main.c: In function ‘lcec_release_lock’:
/home/etv/linuxcnc-ethercat/src/lcec_main.c:920:3: error: implicit declaration of function ‘rtapi_mutex_give’ [-Werror=implicit-function-declaration]
cc1: some warnings being treated as errors
make[5]: *** [/home/etv/linuxcnc-ethercat/src/lcec_main.o] Error 1
make[4]: *** [_module_/home/etv/linuxcnc-ethercat/src] Error 2
make[3]: *** [sub-make] Error 2
make[2]: *** [all] Error 2
make[2]: Leaving directory `/usr/src/linux-headers-3.4-9-rtai-686-pae'
make[1]: *** [lcec.ko] Error 2
make[1]: Leaving directory `/home/etv/linuxcnc-ethercat/src'
make: *** [all] Error 2
etv@etv:~/linuxcnc-ethercat/src$
etv@etv:~/linuxcnc-ethercat/src$ make
make[1]: Entering directory `/home/etv/linuxcnc-ethercat/src'
user.mk:10: warning: overriding commands for target `install'
/usr/share/linuxcnc/Makefile.modinc:95: warning: ignoring old commands for target `install'
make[1]: Nothing to be done for `all'.
make[1]: Leaving directory `/home/etv/linuxcnc-ethercat/src'
make[1]: Entering directory `/home/etv/linuxcnc-ethercat/src'
realtime.mk:37: warning: overriding commands for target `install'
/usr/share/linuxcnc/Makefile.modinc:95: warning: ignoring old commands for target `install'
make EXTRA_CFLAGS="-Os -g -I. -I/usr/realtime-3.4-9-rtai-686-pae/include -I. -I/usr/realtime-3.4-9-rtai-686-pae/include -I/usr/include/i386-linux-gnu -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=0 -fno-math-errno -funsafe-math-optimizations -fno-rounding-math -fno-signaling-nans -fcx-limited-range -mhard-float -DRTAI=3 -fno-fast-math -mieee-fp -fno-unsafe-math-optimizations -DRTAPI -D_GNU_SOURCE -Drealtime -D__MODULE__ -I/usr/include/linuxcnc -Wframe-larger-than=2560" KBUILD_EXTRA_SYMBOLS="/usr/realtime-3.4-9-rtai-686-pae/modules/linuxcnc/Module.symvers /usr/realtime-3.4-9-rtai-686-pae/modules/ethercat/Module.symvers" -C /usr/src/linux-headers-3.4-9-rtai-686-pae SUBDIRS=`pwd` CC=gcc V=0 modules
make[2]: Entering directory `/usr/src/linux-headers-3.4-9-rtai-686-pae'
CC [M] /home/etv/linuxcnc-ethercat/src/lcec_main.o
/home/etv/linuxcnc-ethercat/src/lcec_main.c: In function ‘lcec_request_lock’:
/home/etv/linuxcnc-ethercat/src/lcec_main.c:915:3: error: implicit declaration of function ‘rtapi_mutex_get’ [-Werror=implicit-function-declaration]
/home/etv/linuxcnc-ethercat/src/lcec_main.c: In function ‘lcec_release_lock’:
/home/etv/linuxcnc-ethercat/src/lcec_main.c:920:3: error: implicit declaration of function ‘rtapi_mutex_give’ [-Werror=implicit-function-declaration]
cc1: some warnings being treated as errors
make[5]: *** [/home/etv/linuxcnc-ethercat/src/lcec_main.o] Error 1
make[4]: *** [_module_/home/etv/linuxcnc-ethercat/src] Error 2
make[3]: *** [sub-make] Error 2
make[2]: *** [all] Error 2
make[2]: Leaving directory `/usr/src/linux-headers-3.4-9-rtai-686-pae'
make[1]: *** [lcec.ko] Error 2
make[1]: Leaving directory `/home/etv/linuxcnc-ethercat/src'
make: *** [all] Error 2
etv@etv:~/linuxcnc-ethercat/src$
Please Log in to join the conversation.
Time to create page: 0.093 seconds
