January 2012 4.8 Reading or Changing Machine Parameters via PLC Modules 391
Module 9430 Temporarily change the numeric value of a machine
parameter
Use this module to enter a numeric value in the machine parameter given. The
value of the machine parameter is overwritten in the run-time memory. The
machine parameter in the *.cfg file is not overwritten. The overwritten
parameters are only in effect until the next time the control is started.
The NC software prescribes when a machine parameter can be changed. This
information is included in the description of each parameter in the Technical
Manual under "Reaction" or in the help display of the configuration editor under
"Behavior."
Constraints:
The module can only be called in a spawn or submit job.
The module can only be called while the PLC has control over the machine.
Call:
PS B/W/D/K/S<Name of the configuration object>
e.g. "CfgPositionLimits"
PS B/W/D/K/S<Key name>
Key name of the config object, e.g. "PX"
Transfer empty string if config object has no key name
PS B/W/D/K/S<Name of the machine parameter>
e.g. "swLimitSwitchNeg"
PS B/W/D/K <Index>
Index of the parameter within an array (list field)
0: Parameter without array (list field)
PS B/W/D/K <Factor>
Division factor for conversion to a floating-point number
Enter 1 to receive integer parameter values
PS B/W/D/K <Value of the machine parameter>
CM 9430
PL B/W/D <Error>
See "Return codes of PLC Modules 9430 to 9433, 9436,
9438 (error stack)" on page 397.
Error recognition:
Marker Value Meaning
NN_GenApiModule
Error (M4203)
0 No error; data was changed
1 Error code in
NN_GenApiModuleErrorCode (W1022)
NN_GenApiModule
ErrorCode (W1022)
1 Parameter out of value range
2 Parameter invalid or does not exist, or
other error
3 Invalid string number
6 Changing this value not allowed
13 Error while communicating with the config
server
20 Module was not started from a spawn or
submit job