Home Forum Progea Community Forum Movicon HMI solution for WinCE Set a bit from a DWORD variable

Stai visualizzando 2 post - dal 1 a 2 (di 2 totali)
  • Autore
    Post
  • #145339
    jhonut
    Partecipante

    Hello,
    I use Movicon 11.5 where I have 10 DWORD variables and for all of them I want to set bit number 24 to true when a button is pressed. I have seen this example, but I’m confused how to use it on my button. Any ideas how could I set my dword’s bits in an easier way?

    Many thanks in advance!

    #145348
    MODERATOR
    Amministratore del forum

    Hi ,

    It is possible bring in a byte, word or double word and split it in to individual bits.

    In the Movicon objects and resources, (except the scripts), you can always use this simple way, working on the variable syntax “Variablename.Bitnumber” (eg wordexample.0 for use the first bit of a word variable called “wordexample” to access individual bits).

    wordexample.0 > first bit
    wordexample.1 > second bit
    ….
    wordexample.15

    You can use this syntax in all the objects like buttons, lamps displays …

    Best Regards

Stai visualizzando 2 post - dal 1 a 2 (di 2 totali)
  • Devi essere connesso per rispondere a questo topic.