Moving Objects in WinCC or WinCC Flex

userxyz

Member
Join Date
May 2002
Location
any
Posts
2,768
Hi,

I have a carpet production line of 250 meters. In this production, one or more painted carpets are running trough the whole line.

I need to visualize the 250 meters traject and showing where the carpet is located (distance from the beginpoint with a length of.., something like that).

example: ------------------^^^^^^^^^^^-----------------^^^^^^+

250 meters, + is my beginpoint and ^ is carpet.


I showed the thing on WinCC Flexible, but, a bargraph starts from zero, one processvalue, I need 2 values.. so bargraph is not good...?



Can I visualise something like this ? And what should I use, WinCC 6 or WinCC Flexible ?

I even seen 3D systems on HMI ???
 
I would design an array of rectangles. And then animate each rectangle with color animation. The number of rectangles should be so many that a relatively finegrained resolution is achieved.
You then link the animation tags to an array in the PLC, and in the PLC you then control exactly where there is a carpet and where there is no carpet. You can have several pieces of carpet at the same time.
The downer is that you must specify the array number for each rectangle manually. If you have 100 rectangles then you have to edit the array number 100 times.
 
...

Are you crazy ?

:)

JesperMP said:
I would design an array of rectangles. And then animate each rectangle with color animation. The number of rectangles should be so many that a relatively finegrained resolution is achieved.
You then link the animation tags to an array in the PLC, and in the PLC you then control exactly where there is a carpet and where there is no carpet. You can have several pieces of carpet at the same time.
The downer is that you must specify the array number for each rectangle manually. If you have 100 rectangles then you have to edit the array number 100 times.
 
You may have to bite the bullet.
There is no other smart way to achieve what you want with WinCC Flexible.
It would take me 5 minutes to create the graphics, and 10 minutes to edit the addresses. Tedious work, but not at all that hard.
 
Hey

Okay, you're right, allready done


I have 88 blocks


JesperMP said:
You may have to bite the bullet.
There is no other smart way to achieve what you want with WinCC Flexible.
It would take me 5 minutes to create the graphics, and 10 minutes to edit the addresses. Tedious work, but not at all that hard.
 
but euhm

but, now ...

I have an array in DB82 of 88 bools.

But now...

How can I write in a very short way (STL or SCL) something like a running light...

And to implement in my project... the data is located in registers

Code:
 FUNCTION_BLOCK FB80
VAR_INPUT
INPUT :BOOL;
RUN: BOOL;
RESET: BOOL;
INDS: BOOL;
PULS_LENGTE: REAL;
END_VAR
VAR_IN_OUT
REG_BEGIN: ARRAY[1..4] OF REAL;
REG_EIND: ARRAY[1..4] OF REAL;
END_VAR
VAR
Store_FP: BOOL;
Store_PULS: BOOL;			   
END_VAR 
	
VAR_TEMP
FP: BOOL; 
ivar: INT;
PLS: BOOL;
PULS: INT; 
END_VAR

BEGIN
FP:= INPUT AND (NOT Store_FP);														 // FLANK OVERGANG NAAR LOPER									  
PLS:= INDS AND (NOT Store_PULS);													   // FLANK VAN PULSSENSOR
IF PLS THEN																			// BOOL NAAR INT VOOR CALCULATIE
	PULS:= 1;	
ELSE
	PULS:= 0;
END_IF;
IF FP THEN																			 // BIJ OVERGANG VAN TAPIJT NAAR LOPER (EINDE TAPIJT) SCHUIVEN WE BEIDE REGISTERS DOOR NAAR INDEX 2
	FOR ivar:= 1 TO 3 DO
		REG_BEGIN [5-ivar]:= REG_BEGIN [4-ivar];											   
	END_FOR;
	
	FOR ivar:= 1 TO 3 DO
		REG_EIND [5-ivar]:= REG_EIND [4-ivar];
	END_FOR;
END_IF; 
IF INPUT THEN																		  // INDEX 1 VAN BEIDE REGISTERS OP 0 HOUDEN TIJDENS LOPER
	REG_BEGIN [1]:= 0;
	REG_EIND [1]:= 0;
ELSE
	IF PLS AND RUN THEN
	REG_BEGIN [1]:= REG_BEGIN [1] + (PULS * PULS_LENGTE);							  // BEGINPUNT INDEX 1 MAG METEN TIJDENS TAPIJT
	END_IF;
	REG_EIND [1]:= 0;																  // EINDPUNT INDEX 1 OP 0 HOUDEN	
END_IF;
IF PLS AND RUN THEN																	// REGISTER HEEFT DYNAMISCHE LENGTEWAARDEN (INDEX 2 TOT 4)
	FOR ivar:= 2 TO 4 DO
		REG_BEGIN [ivar]:= REG_BEGIN [ivar] + (PULS * PULS_LENGTE);		 
		REG_EIND [ivar]:= REG_EIND [ivar] + (PULS * PULS_LENGTE);
	END_FOR;
END_IF;		
IF RESET THEN																		  // RESET DOOR NON-VALID WAARDEN NAAR REGISTER TE TRANSFEREREN
	FOR ivar:= 1 TO 4 DO
		REG_BEGIN [ivar]:= 1000;
		REG_EIND [ivar]:= 1000;
	END_FOR;
END_IF;
		
Store_FP:= INPUT;																	  // FLANKEN WEGSCHRIJVEN
Store_PULS:= INDS;
END_FUNCTION_BLOCK

Code:
 FUNCTION FC80: VOID
VAR_INPUT
AGG_PRE_DIST: REAL;	
AGG_DIST: REAL;
AGG_LENGTH: REAL;
AGG_AFT_DIST: REAL;
REG_BEGIN: ARRAY[1..4] OF REAL;
REG_EIND: ARRAY[1..4] OF REAL;
END_VAR   
   
VAR_OUTPUT
VRIJGAVE: BOOL;	   
END_VAR
VAR_TEMP
AGG_b: REAL;
AGG_e: REAL;
END_VAR	
   
BEGIN
AGG_b:= AGG_DIST - AGG_PRE_DIST;  
AGG_e:= AGG_DIST + AGG_LENGTH + AGG_AFT_DIST; 
IF AGG_b < REG_BEGIN [1] OR AGG_b < REG_BEGIN [2] AND AGG_e > REG_EIND [2] OR AGG_b < REG_BEGIN [3] AND AGG_e > REG_EIND [3]OR AGG_b < REG_BEGIN [4] AND AGG_e > REG_EIND [4] THEN
		VRIJGAVE:= TRUE;
   ELSE
	   VRIJGAVE:= FALSE;		 
END_IF;
	
END_FUNCTION
 
...

I really don't like the thing with all these objects...

isn't there a more simple way ?


Now I can see my registers and where the carpet is located with bargraphs. The upper bargraphs are the beginpoints and the lower bargraphs are the endpoints of my carpets.

There is no such thing as a bargraph with 2 process values ?

I don't like the way of 100 objects and shifting

No other ways to visualise this ?



JesperMP said:
The term you are looking for is "FIFO buffer". I even think that there is one in the standard library somewhere.
 
I think you are almost there. If you want to write your own FIFO buffer it is easy with SCL.
SCL pseudo code:

// FIFO with a boolean array:
IF biShiftOnePosition THEN
i := iFifoMax ;
biFifoOutput := biArrayFifo;
FOR i TO 2 DO
biArrayFifo := biArrayFifo[i-1]
END_FOR;
biArrayFifo[1] := biFifoInput
END_IF;

 

Similar Topics

I'm a Siemens person, and this is one of my first AB programs. The customer wants everything programmed in Ladder. I have a lot of data (3...
Replies
14
Views
216
Hello, I have a compact Logix plc and I have been task with configuring alarms into our SCADA when an Analog signal stops moving. The analog...
Replies
6
Views
238
Hello, i am a beginner with a Siemens Logo 8 PLC. I would determine the direction of an object if it passes a whole cycle of 2 input sensors. See...
Replies
2
Views
180
Can an AOP be removed from Logix? I seem to have some version weirdness from an E&H AOP and I need to see if reinstalling the AOP will correct it.
Replies
5
Views
964
I'm making a meal of this, my brain's not in gear. Also, I'm new to S7 TIA/WinCC so excuse my ignorance... See redacted pic. Pressing F7 (SAVE...
Replies
10
Views
3,215
Back
Top Bottom