• 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

    Little endian

    Scheduled Pinned Locked Moved User help
    11 Posts 2 Posters 4.2k 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.
    • M Offline
      mlohbihler
      last edited by

      What do you want to have be LE? Data storage, transmission, a particular comm protocol? And why?

      Best regards,
      Matthew

      1 Reply Last reply Reply Quote 0
      • A Offline
        alberto
        last edited by

        Hi,

        the registers are transmitted as words of 16 bits, LSByte first, followed by MSByte.
        How to do the reverse in mango?

        thank you

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

          To be clear, i assume you are talking about Modbus. The implementation currently does not have an endian flag.

          Best regards,
          Matthew

          1 Reply Last reply Reply Quote 0
          • A Offline
            alberto
            last edited by

            Yes,

            the protocol is Modbus.
            So there is no chance?
            I use the latest version of m2m mango.
            If not, think that in future there will be?

            thanks

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

              Seems unlikely at the moment. The Modbus spec - such as it is - is clear on byte ordering as i recall, and honestly, you're the first to ask for little endian. Why do you need it?

              Best regards,
              Matthew

              1 Reply Last reply Reply Quote 0
              • A Offline
                alberto
                last edited by

                I use that because the slave provides the data in this format.
                The specifications of the device indicate that the protocol is Modbus RTU.
                Very strange.

                thanks

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

                  Yes, strange. Is this a relatively new model? I wonder if they're also swapping things like the CRC.

                  Best regards,
                  Matthew

                  1 Reply Last reply Reply Quote 0
                  • A Offline
                    alberto
                    last edited by

                    I really need to reverse the byte order of a variable.
                    I can do meta data source with a command like the following?

                    unsigned short int Endian_Word_Conversion(unsigned short int word) {
                    return ((word>>8)&0x00FF) | ((word<<8)&0xFF00) ;
                    }

                    where 'word' is, for example, p241.value or p241.other

                    any ideas?

                    thanks

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

                      Sure, you can do something like that.

                      Best regards,
                      Matthew

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