equal
deleted
inserted
replaced
29 void printUsage() |
29 void printUsage() |
30 { |
30 { |
31 cerr |
31 cerr |
32 << "Usage: ethercat <COMMAND> [OPTIONS]" << endl |
32 << "Usage: ethercat <COMMAND> [OPTIONS]" << endl |
33 << "Commands:" << endl |
33 << "Commands:" << endl |
|
34 << " data Output binary domain process data." << endl |
34 << " domain Show domain information." << endl |
35 << " domain Show domain information." << endl |
35 << " list (ls, slaves) List all slaves (former 'lsec')." << endl |
36 << " list (ls, slaves) List all slaves (former 'lsec')." << endl |
36 << " pdos List Pdo mapping of given slaves." << endl |
37 << " pdos List Pdo mapping of given slaves." << endl |
37 << " xml Generate slave information xml." << endl |
38 << " xml Generate slave information xml." << endl |
38 << "Global options:" << endl |
39 << "Global options:" << endl |
141 getOptions(argc, argv); |
142 getOptions(argc, argv); |
142 |
143 |
143 try { |
144 try { |
144 master.open(masterIndex); |
145 master.open(masterIndex); |
145 |
146 |
146 if (command == "domain") { |
147 if (command == "data") { |
|
148 master.outputData(domainIndex); |
|
149 } else if (command == "domain") { |
147 master.showDomains(domainIndex); |
150 master.showDomains(domainIndex); |
148 } else if (command == "list" || command == "ls" || command == "slaves") { |
151 } else if (command == "list" || command == "ls" || command == "slaves") { |
149 master.listSlaves(); |
152 master.listSlaves(); |
150 } else if (command == "pdos") { |
153 } else if (command == "pdos") { |
151 master.listPdos(slavePosition); |
154 master.listPdos(slavePosition); |