Ethercat - newbie guidelines
19 Jan 2022 18:54 #232470
by bw4257
Replied by bw4257 on topic Ethercat - newbie guidelines
I've been following this thread with much interest, and have been working through a similar process, however I have not been able to spin a motor yet. At this point, I'm pretty confused and am hoping to get a little advice/direction, as to what to try next. My setup is the following:
RPI4 running as an EtherCAT master - this seems to work fine
3 AMC Servo Drivers (FD060-10-EM), attached to 3 servo motors - they are tuned and I can move them through AMC's setup software. The manual states that these drives are CiA402 compliant.
I'm using the linuxcnc-cia402 config, discussed in this thread, but get errors. I think that my ethercat-conf.xml might be causing the problems, but I'm not sure.
I'll attach all the relevant files, and would greatly appreciate any suggestions.
I ran the following
linuxcnc cia402.ini > error.txt
Regards,
bw
RPI4 running as an EtherCAT master - this seems to work fine
3 AMC Servo Drivers (FD060-10-EM), attached to 3 servo motors - they are tuned and I can move them through AMC's setup software. The manual states that these drives are CiA402 compliant.
I'm using the linuxcnc-cia402 config, discussed in this thread, but get errors. I think that my ethercat-conf.xml might be causing the problems, but I'm not sure.
I'll attach all the relevant files, and would greatly appreciate any suggestions.
I ran the following
linuxcnc cia402.ini > error.txt
Regards,
bw
Please Log in or Create an account to join the conversation.
19 Jan 2022 19:05 #232473
by rodw
Replied by rodw on topic Ethercat - newbie guidelines
Please remove slave 3 from your xml.
In my config, I have a seperate rtelligent I/O device as slave 3 which seems you do not seem to have
The dmesg error seems to be looking for this non existent device.
Keep us informed, Its great to see this is working for you.
In my config, I have a seperate rtelligent I/O device as slave 3 which seems you do not seem to have
The dmesg error seems to be looking for this non existent device.
Keep us informed, Its great to see this is working for you.
The following user(s) said Thank You: bw4257
Please Log in or Create an account to join the conversation.
19 Jan 2022 19:46 - 19 Jan 2022 20:10 #232475
by bw4257
Replied by bw4257 on topic Ethercat - newbie guidelines
That helps, but now I get the following error about statuswword:
LINUXCNC - 2.8.2Machine configuration directory is '/home/pi/linuxcnc/configs/linuxcnc-cia402'Machine configuration file is 'cia402.ini'Starting LinuxCNC...Found file(REL): ./cia402.halNote: Using POSIX realtime./cia402.hal:58: Pin 'lcec.0.0.cia-statusword' does not existShutting down and cleaning up LinuxCNC...Note: Using POSIX realtimeLinuxCNC terminated with an error. You can find more information in the log: /home/pi/linuxcnc_debug.txtand /home/pi/linuxcnc_print.txtas well as in the output of the shell command 'dmesg' and in the terminal
I'm guessing this has to do with the xml file not matching the device(s). Is the xml file supplied/used in this thread specific to a device?
The attached xml file is from AMC, but I'm kinda confused what to do with it...feel like I need to insert it's content into the loaded xml file 3 times, with idx=0, idx=1, idx=3 entries, or something like that.
running the command: ethercat xml > AMC.xml
produces the other attached file.
Again, I'm kinda confused about the content of these xml files...
LINUXCNC - 2.8.2Machine configuration directory is '/home/pi/linuxcnc/configs/linuxcnc-cia402'Machine configuration file is 'cia402.ini'Starting LinuxCNC...Found file(REL): ./cia402.halNote: Using POSIX realtime./cia402.hal:58: Pin 'lcec.0.0.cia-statusword' does not existShutting down and cleaning up LinuxCNC...Note: Using POSIX realtimeLinuxCNC terminated with an error. You can find more information in the log: /home/pi/linuxcnc_debug.txtand /home/pi/linuxcnc_print.txtas well as in the output of the shell command 'dmesg' and in the terminal
I'm guessing this has to do with the xml file not matching the device(s). Is the xml file supplied/used in this thread specific to a device?
The attached xml file is from AMC, but I'm kinda confused what to do with it...feel like I need to insert it's content into the loaded xml file 3 times, with idx=0, idx=1, idx=3 entries, or something like that.
running the command: ethercat xml > AMC.xml
produces the other attached file.
Again, I'm kinda confused about the content of these xml files...
Last edit: 19 Jan 2022 20:10 by bw4257.
Please Log in or Create an account to join the conversation.
19 Jan 2022 20:06 - 19 Jan 2022 20:11 #232476
by bw4257
Replied by bw4257 on topic Ethercat - newbie guidelines
sorry, double posted....see previous for the complete thought.
Last edit: 19 Jan 2022 20:11 by bw4257.
Please Log in or Create an account to join the conversation.
19 Jan 2022 20:52 #232480
by bw4257
Replied by bw4257 on topic Ethercat - newbie guidelines
I think I'm seeing the light at the end of the tunnel.
The pdoEntries in the ethercat-conf.xml, don't match the entries in the cia402.hal files
rodw...thanks for the help.
I'll post an update when I get this all sorted out.
The pdoEntries in the ethercat-conf.xml, don't match the entries in the cia402.hal files
rodw...thanks for the help.
I'll post an update when I get this all sorted out.
Please Log in or Create an account to join the conversation.
19 Jan 2022 20:59 #232481
by rodw
Replied by rodw on topic Ethercat - newbie guidelines
Yes, everything needs to be set to your drives.
typing ethercat slaves will list the slaves and their numbers (starting at 0)
Each of these slaves needs an entry in your xml file
type ethercat slaves -v
This lists more detailed info
Then in your XML file enter the VID and PID (Vendor ID and ProductID) that is reported for each slave
Note that CIA402 allows vendor specific registers so you will need to consult your drives documentation or query it with a tool like twincat
I think CIA402 will standardize the registers >= 6000 used in my config, Below that number may not work for you.
Also be aware of the byte order when sending strings like <sdoDataRaw data="F4 01"/>
we need to send the strings in low byte, high byte order so the number above is actually 0x01F4
This where I used a binary to hex to decimal converter I found on Google. There are many.
typing ethercat slaves will list the slaves and their numbers (starting at 0)
Each of these slaves needs an entry in your xml file
type ethercat slaves -v
This lists more detailed info
Then in your XML file enter the VID and PID (Vendor ID and ProductID) that is reported for each slave
<slave idx="0" type="generic" vid="00000a88" pid="0a880004" configPdos="true">
Note that CIA402 allows vendor specific registers so you will need to consult your drives documentation or query it with a tool like twincat
I think CIA402 will standardize the registers >= 6000 used in my config, Below that number may not work for you.
Also be aware of the byte order when sending strings like <sdoDataRaw data="F4 01"/>
we need to send the strings in low byte, high byte order so the number above is actually 0x01F4
This where I used a binary to hex to decimal converter I found on Google. There are many.
Please Log in or Create an account to join the conversation.
31 Jan 2022 23:01 #233673
by bw4257
Replied by bw4257 on topic Ethercat - newbie guidelines
Just wanted to post an update and let the group know that I was successful in turning some servo motors with EtherCAT.
Ultimately, revisiting the following thread/example lead me to success:
forum.linuxcnc.org/ethercat/42048-notes-...aspberry-pi-4#206936
For all those that get here, and are stuck...revisit your drives RPDO and TPDO and make sure that these and the cia402 and xml configs all match exactly.
rodw, db1981 and Hakan...you all are greatly appreciated
Ultimately, revisiting the following thread/example lead me to success:
forum.linuxcnc.org/ethercat/42048-notes-...aspberry-pi-4#206936
For all those that get here, and are stuck...revisit your drives RPDO and TPDO and make sure that these and the cia402 and xml configs all match exactly.
rodw, db1981 and Hakan...you all are greatly appreciated
The following user(s) said Thank You: rodw
Please Log in or Create an account to join the conversation.
- kisslaci10
- Offline
- New Member
Less
More
- Posts: 6
- Thank you received: 0
24 Jul 2022 23:56 #248207
by kisslaci10
Replied by kisslaci10 on topic Ethercat - newbie guidelines
Hi,
I would like to ask for some help.
I did use linuxcnc before to a small router with parallel port and with a TB6560 stepper driver but I am still very much a novice.
I was recently given a sanmotion RS2 ethercat AC servo amplifier and I plan to convert a small manual lathe to cnc but as I started to read about how to use linuxcnc with ethercat I have a feeling that:
- either I haven't scratched the surface what linuxcnc can do,
- or I am about to attach a quantum computer controlled ram air turbine drive to my crappy little lathe.
I think both.
I am very much willing to invest the necessary time to read, learn and maybe eventually complete a set up but I would appreciate if someone could warn me that I am about to run and crash to a concrete wall as what I would like is not possible.
So please could someone let me know if linuxcnc is able or can be made to be able to control this servo amplifier?
Can I use linuxcnc with this ethercat drive on one axis and a step/dir controlled stepper drive via parallel port on the other axis?
Maybe with spindle rpm control and encoder speed feedback also via parallel port?
Thanks!
P.S. Sorry for my English.
I would like to ask for some help.
I did use linuxcnc before to a small router with parallel port and with a TB6560 stepper driver but I am still very much a novice.
I was recently given a sanmotion RS2 ethercat AC servo amplifier and I plan to convert a small manual lathe to cnc but as I started to read about how to use linuxcnc with ethercat I have a feeling that:
- either I haven't scratched the surface what linuxcnc can do,
- or I am about to attach a quantum computer controlled ram air turbine drive to my crappy little lathe.
I think both.
I am very much willing to invest the necessary time to read, learn and maybe eventually complete a set up but I would appreciate if someone could warn me that I am about to run and crash to a concrete wall as what I would like is not possible.
So please could someone let me know if linuxcnc is able or can be made to be able to control this servo amplifier?
Can I use linuxcnc with this ethercat drive on one axis and a step/dir controlled stepper drive via parallel port on the other axis?
Maybe with spindle rpm control and encoder speed feedback also via parallel port?
Thanks!
P.S. Sorry for my English.
Please Log in or Create an account to join the conversation.
25 Jul 2022 00:28 #248209
by rodw
Replied by rodw on topic Ethercat - newbie guidelines
If its a CIA402 compatible drive ( I think it is), it will be pretty straightforward if you follow this howto.
forum.linuxcnc.org/ethercat/45336-etherc...-step-by-step#246380
I have not tried this myself for a while but I think it should still work...
The main thing is to get ethercat installed and listing your drive (which should appear as a slave)
forum.linuxcnc.org/ethercat/45336-etherc...-step-by-step#246380
I have not tried this myself for a while but I think it should still work...
The main thing is to get ethercat installed and listing your drive (which should appear as a slave)
Please Log in or Create an account to join the conversation.
- kisslaci10
- Offline
- New Member
Less
More
- Posts: 6
- Thank you received: 0
26 Jul 2022 12:33 #248319
by kisslaci10
Replied by kisslaci10 on topic Ethercat - newbie guidelines
Yes, upon further reading the manual of the drive it seems that it is indeed compatible with CIA402.
Thank you for the help!
Thank you for the help!
Please Log in or Create an account to join the conversation.
Time to create page: 0.094 seconds