SANGE elec IO

More
09 Jun 2025 12:53 #330013 by deltafox24
SANGE elec IO was created by deltafox24
Hi everyone,
I bought this device: SG-ELC-ADIO-DI16-DO16-PNP.
I wrote a custom XML file for it, but for some reason, after I load it, there's a 90% chance that EtherCAT crashes with an error.
I suspect that it might be slowing down the entire system, or maybe I wrote the XML incorrectly.Here’s what I wrote:
 <slave idx="4" type="generic" vid="EE000002" pid="00010205" configPdos="true" >
            <dcConf assignActivate="0000" sync0Cycle="0" sync0Shift="0"/>
        
            <syncManager idx="0" dir="out">
                <pdo idx="1a00">
                    <pdoEntry idx="3101" subIdx="1" bitLen="8" halType="complex">
                        <complexEntry bitLen="1" halPin="out-00" halType="bit"/>
                        <complexEntry bitLen="1" halPin="out-01" halType="bit"/>
                        <complexEntry bitLen="1" halPin="out-02" halType="bit"/>
                        <complexEntry bitLen="1" halPin="out-03" halType="bit"/>
                        <complexEntry bitLen="1" halPin="out-04" halType="bit"/>
                        <complexEntry bitLen="1" halPin="out-05" halType="bit"/>
                        <complexEntry bitLen="1" halPin="out-06" halType="bit"/>
                        <complexEntry bitLen="1" halPin="out-07" halType="bit"/>
                    </pdoEntry>
                </pdo>
                <pdo idx="1a01">
                    <pdoEntry idx="3101" subIdx="2" bitLen="8" halType="complex">
                        <complexEntry bitLen="1" halPin="out-08" halType="bit"/>
                        <complexEntry bitLen="1" halPin="out-09" halType="bit"/>
                        <complexEntry bitLen="1" halPin="out-10" halType="bit"/>
                        <complexEntry bitLen="1" halPin="out-11" halType="bit"/>
                        <complexEntry bitLen="1" halPin="out-12" halType="bit"/>
                        <complexEntry bitLen="1" halPin="out-13" halType="bit"/>
                        <complexEntry bitLen="1" halPin="out-14" halType="bit"/>
                        <complexEntry bitLen="1" halPin="out-15" halType="bit"/>
                    </pdoEntry>
                </pdo>
            </syncManager>
        
            <syncManager idx="2" dir="in">
                <pdo idx="1600">
                    <pdoEntry idx="3001" subIdx="1" bitLen="8" halType="complex">
                        <complexEntry bitLen="1" halPin="in-00" halType="bit"/>
                        <complexEntry bitLen="1" halPin="in-01" halType="bit"/>
                        <complexEntry bitLen="1" halPin="in-02" halType="bit"/>
                        <complexEntry bitLen="1" halPin="in-03" halType="bit"/>
                        <complexEntry bitLen="1" halPin="in-04" halType="bit"/>
                        <complexEntry bitLen="1" halPin="in-05" halType="bit"/>
                        <complexEntry bitLen="1" halPin="in-06" halType="bit"/>
                        <complexEntry bitLen="1" halPin="in-07" halType="bit"/>
                    </pdoEntry>
                </pdo>
                <pdo idx="1601">
                    <pdoEntry idx="3001" subIdx="2" bitLen="8" halType="complex">
                        <complexEntry bitLen="1" halPin="in-08" halType="bit"/>
                        <complexEntry bitLen="1" halPin="in-09" halType="bit"/>
                        <complexEntry bitLen="1" halPin="in-10" halType="bit"/>
                        <complexEntry bitLen="1" halPin="in-11" halType="bit"/>
                        <complexEntry bitLen="1" halPin="in-12" halType="bit"/>
                        <complexEntry bitLen="1" halPin="in-13" halType="bit"/>
                        <complexEntry bitLen="1" halPin="in-14" halType="bit"/>
                        <complexEntry bitLen="1" halPin="in-15" halType="bit"/>
                    </pdoEntry>
                </pdo>
            </syncManager>
        </slave>

And I’m also attaching the original XML file.
Attachments:

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

More
09 Jun 2025 22:38 - 09 Jun 2025 22:52 #330055 by Hakan
Replied by Hakan on topic SANGE elec IO
Run the "lcec_configgen" command and compare.
Also check for relevant error messages from the command "sudo dmesg"
Edit, and according to the xml you attached, output 8 to 15 is in syncmanager 1, but you'll see that.
Last edit: 09 Jun 2025 22:52 by Hakan.

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

More
10 Jun 2025 18:44 #330101 by deltafox24
Replied by deltafox24 on topic SANGE elec IO
thanks for the tip, i got the lcec_configgen file
   <slave idx="4" type="generic" vid="0xee000002" pid="0x00010205" name="D5">
      <!--SG-ELC-ADIO-DI16-DO16-PNP(Digital 16-Input/16-Output)-->
      <syncManager idx="0" dir="out">
        <pdo idx="1a00">
          <!--Output Group 0-->
          <pdoEntry idx="3101" subIdx="01" bitLen="8" halPin="output-00-07-" halType="BLANK"/>
        </pdo>
      </syncManager>
      <syncManager idx="1" dir="out">
        <pdo idx="1a01">
          <!--Output Group 1-->
          <pdoEntry idx="3101" subIdx="02" bitLen="8" halPin="output-08-15-" halType="BLANK"/>
        </pdo>
      </syncManager>
      <syncManager idx="2" dir="in">
        <pdo idx="1600">
          <!--Input Group 0-->
          <pdoEntry idx="3001" subIdx="01" bitLen="8" halPin="input-00-07-" halType="BLANK"/>
        </pdo>
        <pdo idx="1601">
          <!--Input Group 1-->
          <pdoEntry idx="3001" subIdx="02" bitLen="8" halPin="input-08-15-" halType="BLANK"/>
        </pdo>
      </syncManager>
    </slave>

Based on it, I modified my XML file in this way
  <!-- IO -->
<slave idx="4" type="generic" vid="EE000002" pid="00010205" configPdos="true">
  <dcConf assignActivate="0000" sync0Cycle="0" sync0Shift="0"/>

 
  <syncManager idx="0" dir="out">
    <pdo idx="1a00">
      <pdoEntry idx="3101" subIdx="1" bitLen="8" halType="complex">
        <complexEntry bitLen="1" halPin="out-00" halType="bit"/>
        <complexEntry bitLen="1" halPin="out-01" halType="bit"/>
        <complexEntry bitLen="1" halPin="out-02" halType="bit"/>
        <complexEntry bitLen="1" halPin="out-03" halType="bit"/>
        <complexEntry bitLen="1" halPin="out-04" halType="bit"/>
        <complexEntry bitLen="1" halPin="out-05" halType="bit"/>
        <complexEntry bitLen="1" halPin="out-06" halType="bit"/>
        <complexEntry bitLen="1" halPin="out-07" halType="bit"/>
      </pdoEntry>
    </pdo>
  </syncManager>

 
  <syncManager idx="1" dir="out">
    <pdo idx="1a01">
      <pdoEntry idx="3101" subIdx="2" bitLen="8" halType="complex">
        <complexEntry bitLen="1" halPin="out-08" halType="bit"/>
        <complexEntry bitLen="1" halPin="out-09" halType="bit"/>
        <complexEntry bitLen="1" halPin="out-10" halType="bit"/>
        <complexEntry bitLen="1" halPin="out-11" halType="bit"/>
        <complexEntry bitLen="1" halPin="out-12" halType="bit"/>
        <complexEntry bitLen="1" halPin="out-13" halType="bit"/>
        <complexEntry bitLen="1" halPin="out-14" halType="bit"/>
        <complexEntry bitLen="1" halPin="out-15" halType="bit"/>
      </pdoEntry>
    </pdo>
  </syncManager>

 
  <syncManager idx="2" dir="in">
    <pdo idx="1600">
      <pdoEntry idx="3001" subIdx="1" bitLen="8" halType="complex">
        <complexEntry bitLen="1" halPin="in-00" halType="bit"/>
        <complexEntry bitLen="1" halPin="in-01" halType="bit"/>
        <complexEntry bitLen="1" halPin="in-02" halType="bit"/>
        <complexEntry bitLen="1" halPin="in-03" halType="bit"/>
        <complexEntry bitLen="1" halPin="in-04" halType="bit"/>
        <complexEntry bitLen="1" halPin="in-05" halType="bit"/>
        <complexEntry bitLen="1" halPin="in-06" halType="bit"/>
        <complexEntry bitLen="1" halPin="in-07" halType="bit"/>
      </pdoEntry>
    </pdo>
    <pdo idx="1601">
      <pdoEntry idx="3001" subIdx="2" bitLen="8" halType="complex">
        <complexEntry bitLen="1" halPin="in-08" halType="bit"/>
        <complexEntry bitLen="1" halPin="in-09" halType="bit"/>
        <complexEntry bitLen="1" halPin="in-10" halType="bit"/>
        <complexEntry bitLen="1" halPin="in-11" halType="bit"/>
        <complexEntry bitLen="1" halPin="in-12" halType="bit"/>
        <complexEntry bitLen="1" halPin="in-13" halType="bit"/>
        <complexEntry bitLen="1" halPin="in-14" halType="bit"/>
        <complexEntry bitLen="1" halPin="in-15" halType="bit"/>
      </pdoEntry>
    </pdo>
  </syncManager>
</slave>

but still after using the IO module, I get an error when lifting the zed axis.


 

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

More
11 Jun 2025 07:00 #330125 by Hakan
Replied by Hakan on topic SANGE elec IO
Doesn't immediately sound related. Would expect a digital IO from the unit to be involved
and not only movement of an axis.

There are some ways to troubleshoot
- any error or info message, if any, in a popup window from the hmi
- any error or info output from linuxcnc in the terminal window where it is started
- the last say 20 line from the command "sudo dmesg" especially when ethercat related 
and one then need to match that with the configuration
- hal file
- ini file
- ethercat-conf.xml
Sometimes the error is obvious, more often the info doesn't directly identify the problem.
You can have a go and look at the info and see if you can spot where it goes wrong, and why.
I can have a look too but then I need all listed info.
 

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

Time to create page: 0.100 seconds
Powered by Kunena Forum