Jump to content
OMRON Forums

EtherCAT: ecatsdo write fails from terminal, works from etherlab


andyf

Recommended Posts

I am trying to use ecatsdo command in the terminal. I can read an SDO just fine, but when I try to write it fails. If I ssh to the PMAC and use the etherlab utility (/opt/etherlab/bin/ethercat) I and write just fine.

 

Screenshot 1 shows terminal window ecatsdo read OK, but write fails

 

Screenshot 2 shows etherlab working for both read and write

 

Any ideas why ecatsdo might not be working? Is there a log somewhere I can look at?

pmac_terminal.thumb.jpg.4dce4f2e643dedb016a7c158bc2f7e81.jpg

etherlab.jpg.ad224cf38ad2122758707286de04d241.jpg

Link to comment
Share on other sites

  • 5 years later...
  • Replies 8
  • Created
  • Last Reply

Top Posters In This Topic

Curious about this topic as well. I can use the "ethercat download" command just find, however, trying to write an SDO using the ecatsdo function fails. My guess is it has something to do with permissions since the SDO index I'm writng to indicates it is rwr-r-
Link to comment
Share on other sites

  • 9 months later...

My EtherCAT slave is working well with my IPC MotionCore

but i'm trying to get data on slave using SDO

 

i tried the following in terminal and watch list

"L0=ecattypedsdo(0,3,1,$6060,0,0,1) L0"

and got "-nan"

 

than i tried to get data using /opt/etherlab/bin/ethercat

but got an error as following:

"

root@192.168.0.136:/opt/etherlab/bin# ethercat upload -m 0 -p 2 -t int8 0x6060 1

-bash: /opt/etherlab/bin/ethercat: cannot execute binary file: Exec format error

"

 

Slave num 2 and 3 are MackTron motors by Axor and working well with CSP mode.

 

It's PowerPmac IPC MotionCore with Sys.EcatType=1 (Actonics)

 

I tried when ECAT[0].enable=1 (enable) and also when ECAT[0].enable=0 (disable)

 

 

EDIT:

By checking the EtherCAT file info, I found out it was built for 32bit ARM CPU but the IPC MotionCore running Intel x86_64 CPU with OS Ubuntu i686 (32bit)

 

is it affecting the watch window command ecattypedsdo?

 

I believe that I should get a different build of this executable, how should I do it?

 

I checked the executable info as following:

"

root@192.168.0.136:/opt/etherlab/bin# file ./ethercat

./ethercat: ELF 32-bit LSB executable, ARM, EABI5 version 1 (SYSV), dynamically linked, interpreter /lib/ld-linux-armhf.so.3, for GNU/Linux 2.6.32, BuildID[sha1]=9caa83c5c319dcc87a78e1f31b56584283f604b8, not stripped

"

 

and also checked the CPU model and OS version as following:

"

root@192.168.0.136:/opt/etherlab/bin# cat /proc/cpuinfo | grep 'model name' | uniq

model name : Intel® Core i7-4700EQ CPU @ 2.40GHz

 

root@192.168.0.136:/opt/etherlab/bin# uname -a

Linux lx-ppmac 4.1.18-xenomai-2.6.5 #9 SMP Tue Oct 10 12:20:19 PDT 2017 i686 i686 i686 GNU/Linux

"

 

EDIT 2 :

* I tried in OP and PRE-OP modes and got the same results

* I tried also reading SDO from Pneumatic Outputs, Festo CTEU module, and got the same results

 

I am trying to use ecatsdo command in the terminal. I can read an SDO just fine, but when I try to write it fails. If I ssh to the PMAC and use the etherlab utility (/opt/etherlab/bin/ethercat) I and write just fine.

 

Screenshot 1 shows terminal window ecatsdo read OK, but write fails

 

Screenshot 2 shows etherlab working for both read and write

 

Any ideas why ecatsdo might not be working? Is there a log somewhere I can look at?

Link to comment
Share on other sites

  • 2 weeks later...

I suddenly succeed in getting some SDO information until I mistype an address and it stops working, I attached a picture to illustrate

 

it returned the following msg:

" Error: BgThread sem_timedwait(emIoctlFinish_sem) timed out "

 

I notice a suspicious configuration in my EtherCAT Configuration

 

in Slave configuration -> Advanced Option -> SDO Access is set to 0, what does it mean that, is timeout disabled? or access to SDO is disabled?

 

 

 

What firmware version is this?

I am able to use ecattypedsdo successfully to read/write $6060 on a 1S, from an IPC with firmware 2.2.0.1.

1284752747_gettinginfofromslavesdoandthanstops.jpg.684ac508e29af01ad2fac6c8fa2036e0.jpg

1540480269_PowerPmacIDEEtherCATslaveAdvancedOptionTimeoutSDOAccessequel0.thumb.png.9f18eca21ba6cf194d8aa1bd2e6e1471.png

Link to comment
Share on other sites

I am not able to duplicate this issue. Every time I try to read an SDO from a garbage address, I can immediately read from good adresses again aftwerwards. Maybe it is specific to this ethercat slave. You should be able to recover from this state by issueing "ecat reset" in the terminal.

 

As for the SDO access timeout, this is the time after we send out an SDO that we wait for a response. With a value of 0, the EC engineer shows that this uses the master default value. I have been having trouble getting the actual value.

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.

×
×
  • Create New...