Cartier

Enter a string

26 posts in this topic

Good afternoon all,

I'm new with Visilogic and Unitronics. I'm doing my first application and I would like to do this steps:

  1. Ask a login (string) via the HMI
  2. Validate it by clicking on a button "validate"
  3. Display the login saved in a string box to check it's well saved

The problem is that I don't know how to ask the operator to enter, via the HMI, a string. 

Thanks in advance for your help.

0

Share this post


Link to post
Share on other sites

Look on that toolbar that runs vertically between the two primary panes in VisiLogic. When you have an HMI screen displayed on the right side, you will have nearly everything you need for adding display elements to you HMI screen. One of the icons will say "ASCII String" (Near the top, under "Text") when you hover over it with the mouse. Click that icon (not click and hold) then draw the box on the screen to the size you want (you can change it easily afterwards).

There is also a dedicated Password entry box a little further down, under "Numeric".

0

Share this post


Link to post
Share on other sites

Thanks for your quick answer. I'm going to test this tomorrow.

0

Share this post


Link to post
Share on other sites

Good Morning all, I've an other problem:

I try to control an analog output. I increment it during 20sec and I desincrement it during 20sec. Then, the output is set to 0.

The output is well incremented but it doens't desincrement.. Whereas to desincrement, the output stays to the max value and after 20sec is set to 0.

To see the code, download the screen attached.

Thanks in advance for your help !

 

 

Capture.PNG

0

Share this post


Link to post
Share on other sites

Does something turn off MB 71 when the output reaches max value? If not, you are incrementing then decrementing on each PLC cycle, thus leaving the output unchanged.

0

Share this post


Link to post
Share on other sites

No nothing turns  MB 71 off when the output max value is reached. 

But if I add this, the temporisation won't be active, so TD17 will be 0 and the analog output won't decrease.. Is that correct or not ?

 

Thanks for your help.

0

Share this post


Link to post
Share on other sites

You have several alternatives. You can use latched bits and SET & RESET them appropriately or you might see if a TE timer would serve your purposes better (with slightly different triggering logic), or there might be other options depending on your overall logic.

0

Share this post


Link to post
Share on other sites

Glad to hear and thanks for letting us know.

0

Share this post


Link to post
Share on other sites

Still problems..

The outputs' values don't change.

Is it an electrical mistake or my ladder isn't correct ?

 

Thanks in advance.

Capture.PNG

0

Share this post


Link to post
Share on other sites

And How to store the value of an input ? Because immediate "Read input" just store it and doesn't save it..


Thanks in advance.

0

Share this post


Link to post
Share on other sites

Is there some reason you need Immediate Reads and Writes instead of the regular kind?

0

Share this post


Link to post
Share on other sites

 

5 hours ago, Cartier said:

The outputs' values don't change.

HI Cartier,

make sure you are actually calling the routine/sub this is in.  Visilogic will show the red power lines even if the routine is not being called, and thus not actually running.  It is an annoying quirk of the program.

cheers,   Aus

0

Share this post


Link to post
Share on other sites

Wow.. What is the regular kind for inputs/outputs ? It's the main routine 

0

Share this post


Link to post
Share on other sites

I see it's justerelays and contacts.. I'm going to try

 

0

Share this post


Link to post
Share on other sites
8 minutes ago, Cartier said:

What is the regular kind for inputs/outputs ? It's the main routine 

Just use contacts for digital inputs and coils for digital outputs.

0

Share this post


Link to post
Share on other sites

Thanks normal coils have solved my problems. 

I've some other problems with analog outputs but I'll try to correct them tomorrow.

Analog output 0 (0-10V) is associated to MI 0. If MI 0 is set to max-value (about 30000), I should have 10V on analog output 0, isn't?

Is code bellow correct ? START and STOP are buttons.

Thanks for your help.

Capture.PNG

0

Share this post


Link to post
Share on other sites
Just now, Cartier said:

Analog output 0 (0-10V) is associated to MI 0. If MI 0 is set to max-value (about 30000), I should have 10V on analog output 0, isn't?

No! You need to know if the analog output is 10-bit, 12-bit, or 14-bit. If 10-bit, the value of MI 0 should be 0-1023, if 12-bit, 0-4095, and if 14-bit, 0-16383.

You don't need to write to the analog output, just assign a value to MI 0.

0

Share this post


Link to post
Share on other sites

By the way, there are a large number of example projects included with your VisiLogic installation which show you how to do common tasks. There is also a very extensive Help file with examples. Further, there are You Tube videos, made by Unitronics personnel to teach the basics of VisiLogic programming. (I'm not trying to discourage you from posting here, but you may find those resources very helpful)

0

Share this post


Link to post
Share on other sites
15 hours ago, Flex727 said:

By the way, there are a large number of example projects included with your VisiLogic installation which show you how to do common tasks. There is also a very extensive Help file with examples. Further, there are You Tube videos, made by Unitronics personnel to teach the basics of VisiLogic programming. (I'm not trying to discourage you from posting here, but you may find those resources very helpful)

Hi Flex727,

Thanks for your suggestions. In fact, those resouces are very helpful but I don't manage to see why my analog output doesn't work..

I've a module I/0 snap-in E3XB with 12 bits analog outputs. To test my analog output, I've created a new project where analog output 0 (0-10V) is associated to MI 0.

If I set MI 0 to 4095, I should have 10V on analog output 0 but it's not the case.

As you said me before, I don't use immediate "Write Analog Ouput".

0

Share this post


Link to post
Share on other sites

Do you have 24V power connected to your E3XB snap-in module?

0

Share this post


Link to post
Share on other sites

It's probably a hardware configuration problem.  Post your code.

Joe T.

0

Share this post


Link to post
Share on other sites

Hi,

The problem was due to a mistake in the electrical wiring..

Now I communicate with the SD Card and I save the datas in an Excel file.

I try to configure the file's title because I want it similar to this form : Var1_Var2/Var3/Var4_Var5

Var1 => ML

Var2 => MI

Var3 => ML

Var4 => MI

Var5 => DW

 

How can I do it ? Can you give me the main/best way to do it ?

 

Thanks in advance for your help.

0

Share this post


Link to post
Share on other sites

Project finished but I've a last problem : Is it possible to charachters (in text bow) with  accents ?

Thanks for all your help.

Cheers

0

Share this post


Link to post
Share on other sites

In the top-left corner of the on-screen text entry keyboard are two arrow keys. Pressing one of them repeatedly will cycle through all the available characters.

0

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now