<?ZBNF-www.vishia.org version="1.0" encoding="iso-8859-1" ?>
$comment=(*...*).
$endlineComment=//.
$keywords::=TYPE|END_STRUCT|END_VAR|VAR_INPUT.
SclStruct::=
[ TYPE [<$?typeIdent>|UDT<#?>]
STRUCT
{ <variable> }
END_STRUCT
END_TYPE
|
DATA_BLOCK [<$?>|UDT<#?>]
[ (* <*|*)?> *) ]
STRUCT
{ <variable> }
END_STRUCT
[ BEGIN <*|END_DATA_BLOCK?> ]
END_DATA_BLOCK
|
FUNCTION_BLOCK [<$?>|FB<#?>]
[ (* <*|*)?> *) ] ##FBcomment
{ VAR_INPUT [{ <variable> }] END_VAR
| VAR_OUTPUT [{ <variable> }] END_VAR
| VAR_IN_OUT [{ <shortPtr> }] END_VAR
| VAR [{ (* <*|*)?comment> *) | <variable> }] END_VAR
| VAR_TEMP [{ <variable> }] END_VAR
}
BEGIN <*|END_FUNCTION_BLOCK?>
END_FUNCTION_BLOCK
]
\e.
shortPtr::=<$?name> : <$?type> ;.
variable::=
{<$?name> ?,} [ AT <$?atName>] :
[ STRUCT { <variable?structVariable> } END_STRUCT
| [ ARRAY \[ <#?arrayStartIx> \.\. <#?arrayEndIx> \] OF ]
<$?type> [\[ <#?stringlen> \]] [ := <*;?assignment>]
]
;
[//[<*|(@oam|(WinCC|\n?comment>[({WinCC<?winCC>|@oam<?oam> ?, } [: [+<?additional>] <$?otherRepresentation> :
<$?otherType> ] ) ]<*\n?comment2>]]
.
##it doesn't work, should save string.
type::=[BOOL|BYTE|INT|WORD|REAL].