Setting M258 IP Address via HMI - SoMachine V4.1

GSNITZ

Member
Join Date
Jun 2017
Location
TULSA
Posts
30
I'm working to expand the capabilities of an existing product which employs the M258 controller.

Currently, we have to use the post configuration file to adjust the IP address of the M258 controller; this process is not very easy for field technicians to employ. It also means that if the customer makes any network topology change, the customer would also have to update the post-configuration file.

The goal is to create a way to update the M258 controller's IP address using the HMI. My thought is to transfer the IP address to the M258 controller from the HMI via Modbus. Once the IP address has been stored, I want to run a function on the M258 which updates it's IP address to match the values saved from the HMI.

I have recently employed this same strategy to update the serial communications parameters for the M258's MBS port. With a little help, I'm sure we can accomplish the same for the ethernet settings.

Thanks in advance!
 
Reviewing M258 System Functions I found:

ETH_R: Ethernet Port Read Only System Variables
The following table describes the parameters fo the ETH_R System Variable (ETH_R_STRUCT type):

  • i_byIPAddress[0...3]
  • i_bySubNetMask[0..3]
  • i_byGateway[0..3]

Which are all ARRAY[0..3] OF BYTE .

Using these I can compare my current IP settings to the ones supplied by the HMI.

Unfortunately, it appears all ETH_R variables are Read-Only, and the only ETH_W variables does not appear to be helpful (q_wResetCounter) for my purposes.
 
Reviewing the M258 Programming Guide I found:

Setup Post Configuration Page

Which allows one to modify the Post-Configuration file using a web browser; this is a viable work-around but I'm still hunting for an HMI based solution.
 
The SoMachine help contains a useful gem:

Function changeIPAddress

Inputs:
  • xExecute
  • xSave
  • xeChannel
  • i_abyIPAddress
  • i_abyIPMask
  • i_abyIPGateway
Outputs:
  • xDone
  • xBusy
  • xError
  • xSaved
  • q_abyIPAddress
  • q_abyIPMask
  • q_abyIPGateway
 
One feature that I am trying to add in is to compare the current system IP against the new IP requested from the HMI. I thought that either ETH_R.i_byIPAddress or changeIPAddress.q_abyIPAddress would perform this function, but it appears they are both returning Null. I think both of these only report the non-fixed IP address. Any suggestions on this front would be appreciated.
 
Thought I would close the loop here for anyone looking in the future.

The changeIPAddress function appears to only work when used in a function block diagram. When I tried using it in a structured text format, it would not execute. I have an open case with Schneider Support regarding this to see if there is a way to use it in a structured text format.
 

Similar Topics

Good morning fellow sea captains and wizards, I am being asked to do the above and obtain 4 values from each slave, I know about the MRX and MWX...
Replies
32
Views
841
SELECTED NEW FILE SELECTED PROCESSOR TYPE SELECTED I/O CONFIGURATIONS IM UNABLE TO CONFIGURE MY I/O’S. I HAVE A PAPER COPY OF A PROGRAM AND I...
Replies
0
Views
81
Does Rockwell still offer reset codes for old school Master Disk floppy's? In a bind and need to reset the activation disk soon and to be pointed...
Replies
9
Views
230
Hello, I am in possession of a WAGO PFC 200 750-8216 which I was successfully able to set up as a Modbus RTU Master to a slave device using...
Replies
0
Views
87
Hello. I am trying to use a Prosoft AN-X4 to improve the communications for a new panelview plus 7. This is going from a SLC-500 through DH+ to a...
Replies
9
Views
291
Back
Top Bottom