Jump to content

Storing a signed constant?


Recommended Posts

Hello colleagues!

I'm using my Samba 43 to create a simple timer. It counts seconds (SB 3) when there is a signal on a particular input. When it reaches a certain amount of hours it resets. I want to set the amount of hours on HMI. 

Just an idea:

2020_12_11_08_38_53_MOC.vlp_Unitronics_VisiLogic_OPLC_IDE_Ladder_Application_Main_Module._M.jpg.8d6ba732ef7aa528c11b38d52ca70575.jpg... I put ML 0 to B**(D# 24)

Is there a chance to store a signed constant? Or how is this usually made?

I tried with storing counters instead of signed constants? but it still doesnt work.

Any ideas?

Thank you, KR

Link to comment
Share on other sites

  • MVP 2023

We can help you better once you have some of the basics under your belt. Unitronics has a lots of tutorials and videos on YouTube. There are also lots of example projects that came with your VisiLogic installation. Further, browsing the Help file can be very useful for learning. For YouTube videos, you might start here:

 

Link to comment
Share on other sites

  • MVP 2023

To answer your question, you are totally going down the wrong path.  In network two you're using an ASCII to NUM block, which converts ASCII (typically from a serial device like a scale or a barcode reader) to a number.

1 hour ago, MrEngineer said:

When it reaches a certain amount of hours it resets. I want to set the amount of hours on HMI. 

So is this as simple as displaying a number on the HMI?  If this is so, then you do need to do as Flex recommends and watch some videos to acquaint you with the software.  You would use the STORE block to store one number to an MI and then use a numeric display element to show it.

Is it also possible that your Unitronics dealer could help get you going?

Joe T.

Link to comment
Share on other sites

Thank you guys for the help!

I watched lots of youtube tutorials to learn the basics of VisiLogic. I know how everything is done. The problem I'm having is about the setting a signed constant. If there is a way to set a signed constant on HMI - thats the connection I cannot find.

But as you recommended I'll watch the tutorials again to see if I missed something.

KR

Link to comment
Share on other sites

55.png.bca7cedae1d6ec0253e9d659041b8ccc.png

Thats what I meant (an operand).

Let's say you want to count hours. And when it reaches a specific amount of hours it resets. That specific amount of hours is set by the user. 

The "equal" comparing tool in visilogic only works if you put two operands of the same type. When a user sets the specific amount hours how to store that amount on that place:

1267614534_Breznaslova.png.5ab0cfc8dedd5fe51aa7a415a146815e.png

 

Link to comment
Share on other sites

  • MVP 2023

In that case you do not want a signed constant there. You want another MI that you enter the value on the HMI screen. A constant is just that -constant. You cannot change it at run time.

When you double click on your signed constant (the one there with the red box around it), select the "Direct" tab, then you can enter an MI to use there and on your HMI screen.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...