УкраїнськаEnglishmRussian
Вхід/Новий
У темі багато повідомлень

Problems of Adaption


Автор Повідомлення
Повідомлення створено: 20. 08. 2009 [13:55]
Unaie
Unai Ezta
Автор теми
Зареєстрован(а) с: 30.06.2009
Повідомлення: 42
roman wrote:

With script all work fine:
JAVASCRIPT
if( R_old != R && R != EVAL_REAL ) Special.FLibSYS.floatSplitWord(R,R1,R2); 
R_old = R = (R1==EVAL_INT || R2==EVAL_INT) ? EVAL_REAL : Special.FLibSYS.floatMergeWord(R1,R2);



No change for me. (I put this code in DAQ Template)
When Oscada exits it writes to PLC R1=1, R2=1
And, when Oscada is running, I cannot change values in PLC, Oscada always reestablish old value.

I think is not a javascript code problem. I think DAQ module writes OUTPUT LINKs each cycle with last value in memory, so if you in PLC change a register, DAQ module detects a change and reestablish old value. Besides this, if you use OUTPUT LINKs with Block Based Calc, when Oscada starts it writes to PLC the old values DAQ module has in buffer.
Повідомлення створено: 20. 08. 2009 [15:22]
roman
Roman Savochenko
Moderator
Contributor
Developer
Зареєстрован(а) с: 12.12.2007
Повідомлення: 3747
From SVN updated?

Learn, learn and learn better than work, work and work.
Повідомлення створено: 20. 08. 2009 [16:52]
Unaie
Unai Ezta
Автор теми
Зареєстрован(а) с: 30.06.2009
Повідомлення: 42
roman wrote:

From SVN updated?


SVN updated a week ago. Have you changed anything these days?

I think something is failing with OUTPUT LINKs in DAQ Module. Usuallly a SCADA should not write to a PLC if not explicitly set a value.
However, in a Block (Block Based Calc) if you link parameters to modbus (Parameters defined in JAVA LIKE CALC as OUTPUT), when Oscada starts it gets from a buffer the last values these parameters had, perhaps a year ago, and write them to PLC again.








Повідомлення створено: 20. 08. 2009 [17:03]
roman
Roman Savochenko
Moderator
Contributor
Developer
Зареєстрован(а) с: 12.12.2007
Повідомлення: 3747
Updated today.

> P.S. I add writing to PLC only if value is new and not equal EVAL.

Learn, learn and learn better than work, work and work.



23453