Ethercat installation summary

More
12 Dec 2021 08:46 - 12 Dec 2021 08:47 #228906 by rodw
Severral of us are working on our own ethercat configs. and we have documented our efforts in git using some cia402 drives.

github.com/rodw-au/linuxcnc-cia402

We have briefly documented the steps required in this file.
github.com/rodw-au/linuxcnc-cia402/blob/...n%20instructions.txt

The config is working but may need a bit of cleaning up so feel free to clone it. 
As we work through this, we will update the config
Last edit: 12 Dec 2021 08:47 by rodw.

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

More
12 Dec 2021 09:16 #228908 by db1981
well done, good documentation .

at this point :

cd linuxcnc-ethercat/
you can do :

-make clean
-make install for an Rip Version,

or

-make clean
-sudo make install for an installed Version.

after this, you don't need to copy lcec_conf and lcec.so manually.
The following user(s) said Thank You: rodw

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

More
12 Dec 2021 12:14 - 12 Dec 2021 12:14 #228914 by rodw
Replied by rodw on topic Ethercat installation summary
Awesome, thanks for the feedback. Its a group effort. I've updated the document in git.
I've been hacking at the instructions all day and now three of us have got a result.

Any other feedback would be appreciated.

There are a few gotchas in the process. Main ones were:
1.not finding ecrt.h It did not happen to me but my mate got caught. I suspect it was due to 2.8 installed and 2.9 compiled.
2. the commit required in etherlabmaster
3. linux-headers missing n a default install.

It was very hard to find everything covered in one place so hopefully this will help others.
Last edit: 12 Dec 2021 12:14 by rodw.

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

More
31 Dec 2021 20:58 #230413 by Padstar
just wondering how do you solve the missing ecrt.h issue???

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

More
31 Dec 2021 22:07 #230416 by rodw
Replied by rodw on topic Ethercat installation summary
I'm not near an ethercat configured PC.
It is copied onto your PC so its just a case of having the correct include path for GCC
Or copy it to an existing search path.
My friend googled for the file and copied onto his PC but It is there.

Are you installing Linuxcnc  V 2.8 or V2.9?
If 2.8, i think you should: git checkout 2.8 after cloning linuxcnc. At a wild guess, I thought it might be the reason why its not found.

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

More
01 Jan 2022 14:31 #230453 by Padstar
thanks for that...

i've solved it by getting the ecrt.h file from the git, and the driver was able to build...

so on we go to get some cia402 hal goodness working...

wish me luck

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

More
01 Jan 2022 14:45 #230455 by tommylight


wish me luck

Good luck ! :)

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

More
01 Jan 2022 20:13 #230473 by rodw
Replied by rodw on topic Ethercat installation summary

thanks for that...

i've solved it by getting the ecrt.h file from the git, and the driver was able to build...

so on we go to get some cia402 hal goodness working...

wish me luck

Great. 
It does not look like I mentioned your XML should use the Vendor ID an Product ID from slaves -v

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

More
02 Jan 2022 17:49 #230559 by Padstar
ok, ok... so now I'm starting to feel like all i really know is that I'm not aware of what i dont know... this is mostly because i never seem to do anything that matches anyone else's setup...

so... here we go... let me give you details.. (this is purely so i can get a bit more help, as i'm failing fast.. and chewing through ideas and manuals but with only slow progress)

ive got a HP desktop (2 gb of ram, some spinning rust for storage)

ive got some beckhoff ethercat IO devices... some EL1008's and some EL2004's (oh and the EK1100)
and then the real fly in the ointment is the Servo is a Savch SDA2-e (ive got a few of them .. and i'd like to use them to all of there ability as i've used them before in PLC projects and they are perfectly good servos.. they are cia402 compliant.. they have a product id of 0x000007e6

now for now i'm trying to get a single axis setup up for a bit of jogging.. and some IO testing.. (and to help me write a bit of a manual for the savch drive.. )

but as you can only imagen i've not got a hal that will load..

ive been youtubin and have been trying to test a very minimal hal (see below)

# this is the hal that i've started for the ethercat
loadusr -W lcec_conf ethercat-conf.xml

loadrt lcec
addf lcec.read-all servo-thread
addf lcec.write-all servo-thread


and i get an error about the servo thread not being found..

and that's what I'm currently looking into ...

Pb

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

More
02 Jan 2022 19:16 #230565 by Hakan
Replied by Hakan on topic Ethercat installation summary
I just set up ethercat here and there were those problems with ecrt.h and -lethercat not found.

What I did in linuxcnc-ethercat was to add -I/opt/etherlab/include to RTFLAGS in /usr/share/linuxcnc/Makefile.modinc. ecrt.h belongs to etherlab but need help to find it. The other one is to add -L/opt/etherlab/lib to LDFLAGS in linuxcnc-ethercat/src/realtime.mk. Same there, need help to find the library.
One absolutely must do "make clean" after that to update the local make files. Then "make install"
This is with linuxcnc-uspace-dev from the apt. etherlabmaster and linuxcnc-ethercat from git.



 

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

Time to create page: 0.936 seconds
Powered by Kunena Forum