I need to read data format RTU modbus INT32-M10K

Forum Home Forums Communicating with Devices Modbus I need to read data format RTU modbus INT32-M10K

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #1657
    Setsero
    Participant

    I have communication via Modbus RTU, formatted (int 4 bytes) and the data they get is not real because the team format INT32-M10K, as I get the data from that format.

    excuse the translation of the English

    #1660
    Mikhail
    Moderator

    The approach is
    1. Receive data in UInt16 (4 Bytes)
    2. Create a formula in the configuration database (SCADA-Administrator, Formulas table) which decodes the data.
    3. Use the formula for your input channels in the Formula field.

    Do you have an algorithm how to convert INT32-M10K to normal integers or floats?

    #1661
    Setsero
    Participant

    thanks for your quick response.
    the algorithm for obtaining data INT32-M10K
    is:
    Example (Signed):
    Value ‐12345678 is passed in signed 32‐bit Modulus‐10000 format. Both high and
    low are signed.
     Registerhigh: ‐1234 = FB2E Hex
     Registerlow: ‐5678 = E9D2 Hex
     Value = ‐1234 x 10000 + ‐5678 = ‐12345678
    Modbus register map

    Label—–Address—-Number of register—-Format
    kWh del—-40089————2————-INT32-M10K

    I divided into two registers so

    Label———-Address—-Number of register——–Format
    kWh del high—-40089————1————–short (2 bytes)
    kWh del low—–40090————1————–short (2 bytes)

    SCADA-Administrator, Formulas table

    kWh del high Cnl*10000
    kWh del Val(n)+Val()

    (n) is the number of impout channel kWh del low

    • This reply was modified 7 years, 6 months ago by Setsero.
    #1664
    Mikhail
    Moderator

    Does it work for the current time?

Viewing 4 posts - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.