Menu

20 Byte outputs via explicit messages

tomgr
2020-04-20
2020-08-13
  • tomgr

    tomgr - 2020-04-20

    I've recently downloaded this library and I think it's a great project.

    I am trying to use it to communicate with the Murr IO system Cube67.
    The input instance has 42 bytes and I can read every adrress I need, but I have some troubles by outputs...

    The output instance has 20 bytes, according to the example "Explicit Messaging: Write digital outputs to Ethernet/IP Device" I try to set the outputs. This is working great, so I can set the first eight output bits.
    But if I need to set the others? How can I adrress the remaining 19 bytes?

    Could you give me an advice please?

     
    • Rossmann Engineering

      I think this is an addressing issue with the Murr Modules. Unfortunatelly I don't have that Hardware to properly test it.

      If you already solved it you are welcome to share your solution, otherwise we can remote connect to your device to test?

       
      • tomgr

        tomgr - 2020-07-29

        Hello, thanks for your reply.

        With your example "Explicit Messaging: Write digital outputs to Ethernet/IP Device" I reach only on first Byte, how can I address the rest?
        For example I will set the bit 1.5, how can I do that?

         
        • Rossmann Engineering

          Hi, thats a very hardware related question which is impossible for me to answer without access to the Hardeare and some documentation.

           
          • tomgr

            tomgr - 2020-08-12

            OK. So let's forget about Murr and assume the Wago assembly from your sample code. For example, if the coupler has multiple output cards.
            How do you set any higher byte than the first?

            For inputs I used this:

            byte[] digitalInputs = eeipClient.AssemblyObject.getInstance(0x6c);

                        Console.WriteLine("State of Digital Input 3.4: " + (EEIPClient.ToBool(digitalInputs[3], 4)));
                        Console.WriteLine("State of Digital Input 3.5: " + (EEIPClient.ToBool(digitalInputs[3], 5)));
            

            But I have no idea for the outputs...

            Thx... ;-)

             
            • Rossmann Engineering

              Hi, thats the same with the digital outputs. In the Example on the website I am using the "setInstance" Method which initializes an Array (in this case with the length "1") If you would have to set the Output no. 9 you would have to use an Array with the length "2"

               
              • tomgr

                tomgr - 2020-08-13

                hi, and can I have a wish... can you please write the necessary line of code?
                Because I didn't find the definition of array size anywhere ... only in byte usage?

                 

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.