• Recent
    • Tags
    • Popular
    • Register
    • Login

    Please Note This forum exists for community support for the Mango product family and the Radix IoT Platform. Although Radix IoT employees participate in this forum from time to time, there is no guarantee of a response to anything posted here, nor can Radix IoT, LLC guarantee the accuracy of any information expressed or conveyed. Specific project questions from customers with active support contracts are asked to send requests to support@radixiot.com.

    Radix IoT Website Mango 3 Documentation Website Mango 4 Documentation Website Mango 5 Documentation Website

    Direct connection to plc!!

    Modbus4J general discussion
    2
    9
    4.3k
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • J
      Jkhar
      last edited by

      Hi!
      I've alredy implement the TCP master and slave clases but now i want to conect to a PLC an get data from it. So this is not my area, i'm just a saftware developer, but i was wondering: Do I just need to implement a Master tcp object and point it to the plc's ip address and do the request??
      Any comments acepted. :?: :?: :?: :?: :?: :?:

      1 Reply Last reply Reply Quote 0
      • M
        mlohbihler
        last edited by

        That's pretty much it, yeah.

        Best regards,
        Matthew

        1 Reply Last reply Reply Quote 0
        • J
          Jkhar
          last edited by

          Thanks, just another cuestion: the Slave object that i create for test works like a simulator of a plc??

          1 Reply Last reply Reply Quote 0
          • M
            mlohbihler
            last edited by

            I guess you could say that. It would be more accurate though to say that it works like a Modbus slave.

            Best regards,
            Matthew

            1 Reply Last reply Reply Quote 0
            • J
              Jkhar
              last edited by

              Hi! again. i have a question: how do i point the TCPMaster to the ip address of the PLC? because with the tcpslave class i asign a SlaveId and with this i was making the request. But now is directly to the PLC....

              1 Reply Last reply Reply Quote 0
              • M
                mlohbihler
                last edited by

                When you create the TCP master you have to provide an IpParameters instance. The host value is the IP of your slave.

                Best regards,
                Matthew

                1 Reply Last reply Reply Quote 0
                • J
                  Jkhar
                  last edited by

                  ok, but when i send the request i pass the Slave id parameter, what about it??

                  1 Reply Last reply Reply Quote 0
                  • M
                    mlohbihler
                    last edited by

                    See the s/getValue methods in ModbusMaster. You can provide the slave id directly or use a ModbusLocator to encapsulate register details.

                    Best regards,
                    Matthew

                    1 Reply Last reply Reply Quote 0
                    • First post
                      Last post