INSERT function - How to?

h20pt

Member
Join Date
May 2010
Location
Portugal
Posts
31
Hello

I'm starting to use s7-1200 and i would like to know how can i creat a string from char's through the INSERT function.
I already wrote the IN1, IN2 and P values that i need but i don't know which OUT value/data type to use. I tried to use "%DB2000" but obviously it said it's not the right data format for the output.
On the s7-200 i used to use the STR_COPY funcion and a VB on the output but it's not working on the s7-1200.
The goal of this is to "print" a message on the touch panel in string format.
Can anyone help?

Thanks in advance.
 
Last edited:
Please? :(

I know this is something really easy, but i'm still in the beginning of learning (as we all were once) and i guess this should not be that hard to explain.
I just need to know wich type of data/format to use on the OUTPUT of the INSERT function..
 
Sorry, H20pt, but I am not familar with that Siemens PLC. Which Siemens software program is used for programming the S7-1200?
 
The program i use is the STEP 7 BASIC V10.5 SP2.
Anyway i can find out wich is the correct data format to use? :(
That's really stoping my project from moving on..
 
Hi!
Point on INSERT and push F1 for help.
You will learn that it is string format.
Here's an example, you can define strings in the temp area of the calling block or in a datablock.

Kalle

That's just what i was looking for!
I knew the format was string, but i didn't know how to use it and that i had to create data blocks.

untitled.jpg


Is this way correct?
I will also need to show this strings on a HMI interface. How can i accomplish that?

Thank you so much for you help.
 
untitled.jpg


I've created a I/O field on the HMI wich i configured to be only an output with the string format.
Then i grabbed the corresponding data block using the tag searching field.
Will this work?

Thanks
 
Yes it should work, but I never remember if it is INPUT or OUTPUT.

You can start "simulate runtime"/"with tag simulator" and check it.

FYI, I have next to zero experience with the TIA10.5.

Kalle
 
Field is input if it is meant to input data to variable. If its meant to display data, its output as it outputs something from variable to screen.
 
Yes it should work, but I never remember if it is INPUT or OUTPUT.

You can start "simulate runtime"/"with tag simulator" and check it.

FYI, I have next to zero experience with the TIA10.5.

Kalle

I will test it, but i'm pretty sure it's OUTPUT, since i want to "output" text to the HMI interface.
Anyway, thank you so much for your help! ;)

Field is input if it is meant to input data to variable. If its meant to display data, its output as it outputs something from variable to screen.

Thank you for clarifying :)
I'm sure it will be helpful for someone else.

Thanks for all the help. (y)
 
OK, but some time in my carriere I have been working with a system with opposite definitions (could it be Coros 2000?). So that has confused my brain for ever after. So is it, and so it will be...;)

Kalle
 
Hi again, h20pt!

I just looked at you screenshots. Have you studied the 'Text list' possibilities in the HMI? The text list refers to the value of a tag (f.x. a byte). More tags can refer to the same text list - it is 'reusable'. IMO it's worth an hour studying.

The same is valid for graphics list.

Kalle
 

Similar Topics

I'm new to ST so go easy. Studio 5000 L33ER PLC I'm trying to take 2 strings, merge them into 1 string. with a space between the 2 strings...
Replies
3
Views
2,248
Hello everyone. Currently I am using Eplan p8 and faced (while creating a panel) with a challenge in finding a device called DIN mounting rail...
Replies
10
Views
3,411
Hello guys, I am working with a CompactLogix, which communicates over Ethernet/IP with a pin marker. Basically, The PLC sends the texts to be...
Replies
6
Views
1,389
Hi, I have some remote IO connected to my S7-317-2 PN/DP system. I have 1 particular profinet remote IO which is not important to the system, and...
Replies
9
Views
2,982
I am using VbScript in Indusoft to insert data into a MySql database. Immediately after inserting a row, I need to know what that row number is...
Replies
24
Views
5,289
Back
Top Bottom