HMI Pad Forums Old forum General (old) Clever use of SM-ONE

This topic contains 0 replies, has 0 voices, and was last updated by  John 8 years, 7 months ago. This post has been viewed 1075 times

Viewing 1 post (of 1 total)
  • Author
    Posts
  • #19846

    John
    Keymaster

      An user figured out how to enable the free ScadaMobile ONE to write up to 16 binary values on a PLC. He placed 16 buttons on a page and linked a single PLC tag to them by using an expression. Et Voila!, all of sudden the one tag constrained SM-ONE turned out to be capable to independently activate up to 16 lamps.

      This was the trick:

      For the buttons he just did this:

      bit0 BOOL LOCAL label=”Bit 0″; style=”button”; write_access=0;
      bit1 BOOL LOCAL label=”Bit 1″; style=”button”; write_access=0;
      bit2 BOOL LOCAL label=”Bit 2″; style=”button”; write_access=0;

      and so on.

      For the PLC value he used an expression like this (example to actuate on bits from 0 to 5):

      the_value INT HR1 value=bit0+2*(bit1+2*(bit2+2*(bit3+2*(bit4+2*(bit5))))) ;

      So when any of the buttons is pushed, SM-ONE will activate the same bit of HR1 in the PLC. Isn’t that clever?.

      But wait, if you use a 32 bit long type such as a DINT, you can extend that to up to 32 boolean values!. Now, that’s already beyond what older Lite version was able to do, and for free!. I can’t wait to hear about what other imaginative solutions users will find to squeeze even more the single tag available in ONE!

      Enjoy!

      John

    Viewing 1 post (of 1 total)

    You must be logged in to reply to this topic.

    Copyright © SweetWilliam, S.L 2009-2013. All rights reserved.
    Science and Technology Park of the University of Girona, Emili Grahit, 91 (NarcĂ­s Monturiol building, Office P3-B03) 17003-Girona. Phone +34972183244