Why does the PCD go into halt when using temporary data (TEQU)?
FAQ #101293
The PCD goes into HALT when temporary data size has NOT been defined and an entry "TempData ILLEGAL" gets added to the PCD history.
This error occurs when no temporary data size has been defined.
Description:
Each COB (each task) which calls blocks that use temporary data should contain a "DEFTMP M x" instruction to define the amount of temporary data memory to be assigned to the task, where 'x' is in K bytes. S-Asm normally generates this instruction automatically if it knows that the COB uses temporary data, but because the COB is coded in Fupla and not in IL, and the temp data is accessed from a $COBSEG block, the instruction is not generated, so you must add it manually.
Solution:
The solution is to add the line "DEFTMP M ..." to the $COBSEG directive in the IL file (example):
$COBSEG
CFB TestFB
R 0
R 1
DEFTMP M 2
$ENDCOBSEG
Categories
PCD3 / Mxxx
PG5 2.0 / SEdit (IL programming)
PCD2 / M5xxx
Last update: 30.05.2015 19:58
First release: 08.09.2009 11:39
Views: 6891