• Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Register
    • Login

    Reading the ModBus bus with the Patron

    Scheduled Pinned Locked Moved Other Peripherals
    4 Posts 2 Posters 1.9k Views 1 Watching
    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.
    • Vesa KauppinenV
      Vesa Kauppinen
      last edited by

      Hi,

      I have tested to read the Kamstrup 803 meter on the Patron M527 via Modbus.

      However, I don't get any results from mbpoll.

      root@M527-sn60:~# mbpoll /dev/extcomm/0/1 -m rtu -P none -d 8 -s 1 -b 19200 -a 44
      mbpoll 1.4-12 - FieldTalk(tm) Modbus(R) Master Simulator
      Copyright © 2015-2019 Pascal JEAN, https://github.com/epsilonrt/mbpoll
      This program comes with ABSOLUTELY NO WARRANTY.
      This is free software, and you are welcome to redistribute it
      under certain conditions; type 'mbpoll -w' for details.
      
      Protocol configuration: Modbus RTU
      Slave configuration...: address = [44]
                              start reference = 1, count = 1
      Communication.........: /dev/extcomm/0/1,      19200-8N1 
                              t/o 1.00 s, poll rate 1000 ms
      Data type.............: 16-bit register, output (holding) register table
      
      -- Polling slave 44... Ctrl-C to stop)
      Read output (holding) register failed: Connection timed out
      -- Polling slave 44... Ctrl-C to stop)
      Read output (holding) register failed: Connection timed out
      -- Polling slave 44... Ctrl-C to stop)
      Read output (holding) register failed: Connection timed out
      

      Same result on mbpoll /dev/extcomm/0/0 -m rtu -P none -d 8 -s 1 -b 19200 -a 44

      Br,
      Vesa

      1 Reply Last reply
      Reply Quote 0
      • A
        AVsetula
        last edited by AVsetula

        Hello Vesa,

        Only some Patron ports are available using the deprecated /dev/extcomm/Y/X notation.
        I recommend using the ports from the table in this article: Patron serial port mapping

        To verify communication with all our Modbus devices, I recommend asking the holding register 1003, which is available for all Modbus devices Unipi and whith contains a unique identifier, according to which the device can also be recognized.

        Best regards,
        Antonin

        Vesa KauppinenV 1 Reply Last reply
        Reply Quote 0
        • Vesa KauppinenV
          Vesa Kauppinen @AVsetula
          last edited by

          Hi,

          How can i ask the holding register 1003 with mbpoll?

          @AVsetula said in Reading the ModBus bus with the Patron:

          To verify communication with all our Modbus devices, I recommend asking the holding register 1003, which is available for all Modbus devices Unipi and whith contains a unique identifier, according to which the device can also be recognized.

          Thank you!

          /Vesa

          A 1 Reply Last reply
          Reply Quote 0
          • A
            AVsetula @Vesa Kauppinen
            last edited by

            Hi @Vesa-Kauppinen,

            From Unipi Patron I/O boards by:

            • Section 1: mbpoll -m tcp 127.0.0.1 -a 0 -0 -1 -r 1003 -p 502
            • Section 2: mbpoll -m tcp 127.0.0.1 -a 0 -0 -1 -r 1103 -p 502
            • Section 3: mbpoll -m tcp 127.0.0.1 -a 0 -0 -1 -r 1203 -p 502

            And from Unipi Extension using ttyNS0 port:

            • mbpoll -m rtu /dev/ttyNS0 -b 19200 -P none -0 -1 -r 1003 -a 15

            Best regards,
            Antonin

            1 Reply Last reply
            Reply Quote 0

            Hello! It looks like you're interested in this conversation, but you don't have an account yet.

            Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

            With your input, this post could be even better 💗

            Register Login
            • First post
              Last post