Jump to content

Search the Community

Showing results for tags 'union'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • PLCs and Supporting Devices
    • General Topics - The Lounge
    • Allen Bradley / Rockwell Automation
    • Omron
    • Mitsubishi
    • Siemens
    • Modicon / Telemecanique / Schneider Electric
    • GE / Emerson
    • Automation Direct
    • Panasonic
    • Festo
    • Other PLCs
    • Download Comments

Categories

  • Allen Bradley
    • PLC Sample Code
    • HMI Sample Code
    • Demo Software
    • Manuals, Tutorials
  • GE
    • PLC Sample Code
    • HMI Sample Code
    • Demo Software
    • Manuals, Tutorials
  • Omron
    • PLC Sample Code
    • HMI Sample Code
    • Demo Software
    • Manuals
    • Tutorials and Quickstarts
    • Tech and Application Notes
    • Other Omron Products
    • Utilities
  • Mitsubishi
    • PLC Sample Code
    • HMI Sample Code
    • Demo Software
    • Manuals, Tutorials
  • Modicon
    • PLC Sample Code
    • HMI Sample Code
    • Demo Software
    • Manuals, Tutorials
  • Automation Direct
    • PLC Sample Code
    • HMI Sample Code
    • Demo Software
    • Manuals, Tutorials
  • Siemens
    • PLC Sample Code
    • HMI Sample Code
    • Demo Software
    • Manuals, Tutorials
  • Miscellaneous
    • Tutorials and Guides
    • Hugh Jack, Ph.D., PLC Books
    • Robots and Servos
    • Vision Systems
    • Other PLC Demo Software
    • Free Utilities

Product Groups

There are no results to display.


Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


WhatsApp


Telegram


Line


Discord


WeChat


Skype


Location


Interests

Found 2 results

  1. Hello! I am trying to get hold of the bits in a word, i have read that union is the way to go. My problem is that i cant figure out how union works. I have made a union between a word (16bit) and an array(0...15). The way I understood this was that the word now automaticly updates the array so that when the least significant bit in the word should update array[00] and so on. This is not happening. When I monitor the variables I can see the word change, but nothing happens with the array. Have I misunderstood the consept and what should I do to get hold of the bits?
  2. I am having problem converting a DWORD variable to a floating point decimal. I've tried using the DWORD_TO_REAL function. Having the hex value "41E9B814" as an input I was expecting to get "29.2148819" as an output. However, I'm getting "1.110194.." as the output. Any ideas?
×
×
  • Create New...