SetDeviceConfig
Note:
B.25 SetDeviceConfig
Note:
Note:
B.26 GetDeviceConfig
Appendix B CX-Server Communications Control
The return Boolean value, bValid, is set to True if no errors were detected.
However, this does not necessarily mean that all the parameters used were
valid or appropriate for the PLC being used.
This is a function that can be used to set any element of CX-Server device
configuration. All the data is passed in textual form. This function is for
advanced users only.
This method does not interpret or verify the data passed, and it is possible to
pass invalid data that will prevent a device communicating. Care should be
taken to ensure that all data passed is valid. This method should not be used
while a PLC is open and communicating.
Example:
Device = "PLC1"
Section = "NET"
Entry = "IPADDR"
Setting = "10.0.0.1"
bValid = CXServer.SetDeviceConfig
Entry, Setting
The return Boolean value, bValid, is set to True if no errors were detected.
However, this does not necessarily mean that all the parameters used were
valid or appropriate for the device being used.
Only the following Section, Entry and Setting parameter value combinations
are currently supported:
•
Section = "ADDRESS", Entry = "DNA", Setting = "0"..Setting = "255" -
this can be used to set the network number
•
Section = "ADDRESS", Entry = "DA1", Setting = "0"..Setting = "255" - this
can be used to set the node number
•
Section = "ADDRESS", Entry = "UNIT", Setting = "0"..Setting = "255" -
this can be used to set the unit number
•
Section = "ADDRESS", Entry = "IPADDR", Setting = "0.0.0.0"..Setting =
"255.255.255.255" - this can be used to set the Ethernet IP address
Other parameter values may work, but should only be used on Omron advice.
This is a function that can be used to read any element of the CX-Server
device configuration. All the data is passed (and received) in textual form. This
function is for advanced users only.
Example:
Dim Setting
Device = "PLC1"
Section = "NET"
Entry = "IPADDR"
Setting = CXServer.GetDeviceConfig
Entry
Currently
supported
SetDeviceConfig method.
parameter
values
Device,
Section,
Device,
Section,
are
as
described
for
the
137