Jump to content
OMRON Forums

Question about "system ethercat" command


kjcho
 Share

Recommended Posts

Hi,

 

I'm using 'system ethercat' command since this thread has been written.

 

I want to write PPMAC variables but PPMAC variables can't be input system command, like this...

p1=500

system ethercat -m0 -p0 -t int16 download 0x607D 0 p1

 

Of course, ecatsdo command works fine.

But I couldn't fix sdo problem yet... so I must use system ethercat command.

p1=500

p0=ecatsdo(0,0,$607D,1,p1,0)

 

How can I PPMAC variables with system commands??

Please let me know

 

Thanks.

Link to comment
Share on other sites

  • Replies 5
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

You cannot use pmac variables with the system command. The system command forwards a string to be operated on by the operating system.

 

Hi,

 

I'm using 'system ethercat' command since this thread has been written.

 

I want to write PPMAC variables but PPMAC variables can't be input system command, like this...

p1=500

system ethercat -m0 -p0 -t int16 download 0x607D 0 p1

 

Of course, ecatsdo command works fine.

But I couldn't fix sdo problem yet... so I must use system ethercat command.

p1=500

p0=ecatsdo(0,0,$607D,1,p1,0)

 

How can I PPMAC variables with system commands??

Please let me know

 

Thanks.

Link to comment
Share on other sites

  • 2 weeks later...

Hi, kycho.

 

You can use pmac variables with the system command.

 

Did you try like this?

 

p1=500

system"ethercat -m0 -p0 -t int16 download 0x607D 0 %d", p1

 

please check the code above.

 

Hi, sjlee.

 

Thank you for answer, but it didn't work...

 

system"ethercat -m0 -p0 -t int16 download 0x607D 0 %d", p1

sh: ethercat -m0 -p0 -t int16 download 0x607D 0 %d,: command not found

Link to comment
Share on other sites

If your command is correct,

 

please test code below.

 

if you want to use system command with argument in terminal (on-line command),

as I know,

you should use with cx or cpx command.

 

p1=500

cx system"ethercat -m0 -p0 -t int16 download 0x607D 0 %d", p1

 

try it, and please check again.

Link to comment
Share on other sites

It works!

Thank you!!

 

 

If your command is correct,

 

please test code below.

 

if you want to use system command with argument in terminal (on-line command),

as I know,

you should use with cx or cpx command.

 

p1=500

cx system"ethercat -m0 -p0 -t int16 download 0x607D 0 %d", p1

 

try it, and please check again.

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
 Share


×
×
  • Create New...