You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
thrownewOmronException("Failed to Negotiate a TCP Connection with Omron PLC '"+base.RemoteHost+":"+base.Port+"' - TCP Negotiation Message Length was too Short");
159
+
thrownewOmronException("Failed to Negotiate a TCP Connection with Omron PLC '"+RemoteHost+":"+Port+"' - TCP Negotiation Message Length was too Short");
thrownewOmronException("Failed to Negotiate a TCP Connection with Omron PLC '"+base.RemoteHost+":"+base.Port+"' - TCP Negotiation Message contained an Invalid Local Node ID");
166
+
thrownewOmronException("Failed to Negotiate a TCP Connection with Omron PLC '"+RemoteHost+":"+Port+"' - TCP Negotiation Message contained an Invalid Local Node ID");
thrownewOmronException("Failed to Negotiate a TCP Connection with Omron PLC '"+base.RemoteHost+":"+base.Port+"' - TCP Negotiation Message contained an Invalid Remote Node ID");
173
+
thrownewOmronException("Failed to Negotiate a TCP Connection with Omron PLC '"+RemoteHost+":"+Port+"' - TCP Negotiation Message contained an Invalid Remote Node ID");
170
174
}
171
175
172
176
_remoteNodeId=tcpNegotiationMessage[7];
173
177
}
174
178
catch(OmronExceptione)
175
179
{
176
-
thrownewOmronException("Failed to Negotiate a TCP Connection with Omron PLC '"+base.RemoteHost+":"+base.Port+"'",e);
180
+
thrownewOmronException("Failed to Negotiate a TCP Connection with Omron PLC '"+RemoteHost+":"+Port+"'",e);
thrownewOmronException("Failed to Receive FINS Message from Omron PLC '"+base.RemoteHost+":"+base.Port+"' - The TCP Message Length was Invalid");
281
+
thrownewOmronException("Failed to Receive FINS Message from Omron PLC '"+RemoteHost+":"+Port+"' - The TCP Message Length was Invalid");
262
282
}
263
283
264
284
if(receivedData[11]==3||receivedData[15]!=0)
265
285
{
266
286
switch(receivedData[15])
267
287
{
268
288
case1:
269
-
thrownewOmronException("Failed to Receive FINS Message from Omron PLC '"+base.RemoteHost+":"+base.Port+"' - Omron TCP Error: The FINS Identifier (ASCII Code) was Invalid.");
289
+
thrownewOmronException("Failed to Receive FINS Message from Omron PLC '"+RemoteHost+":"+Port+"' - Omron TCP Error: The FINS Identifier (ASCII Code) was Invalid.");
270
290
271
291
case2:
272
-
thrownewOmronException("Failed to Receive FINS Message from Omron PLC '"+base.RemoteHost+":"+base.Port+"' - Omron TCP Error: The Data Length is too Long.");
292
+
thrownewOmronException("Failed to Receive FINS Message from Omron PLC '"+RemoteHost+":"+Port+"' - Omron TCP Error: The Data Length is too Long.");
273
293
274
294
case3:
275
-
thrownewOmronException("Failed to Receive FINS Message from Omron PLC '"+base.RemoteHost+":"+base.Port+"' - Omron TCP Error: The Command is not Supported.");
295
+
thrownewOmronException("Failed to Receive FINS Message from Omron PLC '"+RemoteHost+":"+Port+"' - Omron TCP Error: The Command is not Supported.");
276
296
277
297
case20:
278
-
thrownewOmronException("Failed to Receive FINS Message from Omron PLC '"+base.RemoteHost+":"+base.Port+"' - Omron TCP Error: All Connections are in Use.");
298
+
thrownewOmronException("Failed to Receive FINS Message from Omron PLC '"+RemoteHost+":"+Port+"' - Omron TCP Error: All Connections are in Use.");
279
299
280
300
case21:
281
-
thrownewOmronException("Failed to Receive FINS Message from Omron PLC '"+base.RemoteHost+":"+base.Port+"' - Omron TCP Error: The Specified Node is already Connected.");
301
+
thrownewOmronException("Failed to Receive FINS Message from Omron PLC '"+RemoteHost+":"+Port+"' - Omron TCP Error: The Specified Node is already Connected.");
282
302
283
303
case22:
284
-
thrownewOmronException("Failed to Receive FINS Message from Omron PLC '"+base.RemoteHost+":"+base.Port+"' - Omron TCP Error: Attempt to Access a Protected Node from an Unspecified IP Address.");
304
+
thrownewOmronException("Failed to Receive FINS Message from Omron PLC '"+RemoteHost+":"+Port+"' - Omron TCP Error: Attempt to Access a Protected Node from an Unspecified IP Address.");
285
305
286
306
case23:
287
-
thrownewOmronException("Failed to Receive FINS Message from Omron PLC '"+base.RemoteHost+":"+base.Port+"' - Omron TCP Error: The Client FINS Node Address is out of Range.");
307
+
thrownewOmronException("Failed to Receive FINS Message from Omron PLC '"+RemoteHost+":"+Port+"' - Omron TCP Error: The Client FINS Node Address is out of Range.");
288
308
289
309
case24:
290
-
thrownewOmronException("Failed to Receive FINS Message from Omron PLC '"+base.RemoteHost+":"+base.Port+"' - Omron TCP Error: The same FINS Node Address is being used by the Client and Server.");
310
+
thrownewOmronException("Failed to Receive FINS Message from Omron PLC '"+RemoteHost+":"+Port+"' - Omron TCP Error: The same FINS Node Address is being used by the Client and Server.");
291
311
292
312
case25:
293
-
thrownewOmronException("Failed to Receive FINS Message from Omron PLC '"+base.RemoteHost+":"+base.Port+"' - Omron TCP Error: All the Node Addresses Available for Allocation have been Used.");
313
+
thrownewOmronException("Failed to Receive FINS Message from Omron PLC '"+RemoteHost+":"+Port+"' - Omron TCP Error: All the Node Addresses Available for Allocation have been Used.");
294
314
295
315
default:
296
-
thrownewOmronException("Failed to Receive FINS Message from Omron PLC '"+base.RemoteHost+":"+base.Port+"' - Omron TCP Error: Unknown Code '"+receivedData[15]+"'");
316
+
thrownewOmronException("Failed to Receive FINS Message from Omron PLC '"+RemoteHost+":"+Port+"' - Omron TCP Error: Unknown Code '"+receivedData[15]+"'");
thrownewOmronException("Failed to Receive FINS Message from Omron PLC '"+base.RemoteHost+":"+base.Port+"' - The TCP Command Received '"+receivedData[11]+"' did not match Expected Command '"+(byte)command+"'");
322
+
thrownewOmronException("Failed to Receive FINS Message from Omron PLC '"+RemoteHost+":"+Port+"' - The TCP Command Received '"+receivedData[11]+"' did not match Expected Command '"+(byte)command+"'");
thrownewOmronException("Failed to Receive FINS Message from Omron PLC '"+base.RemoteHost+":"+base.Port+"' - The TCP Message Length was too short for a FINS Frame");
327
+
thrownewOmronException("Failed to Receive FINS Message from Omron PLC '"+RemoteHost+":"+Port+"' - The TCP Message Length was too short for a FINS Frame");
308
328
}
309
329
310
330
receivedData.RemoveRange(0,TCP_HEADER_LENGTH);
@@ -335,28 +355,32 @@ private async Task<ReceiveMessageResult> receiveMessageAsync(enTCPCommandCode co
335
355
336
356
if(receivedData.Count==0)
337
357
{
338
-
thrownewOmronException("Failed to Receive FINS Message from Omron PLC '"+base.RemoteHost+":"+base.Port+"' - No Data was Received after TCP Header");
358
+
thrownewOmronException("Failed to Receive FINS Message from Omron PLC '"+RemoteHost+":"+Port+"' - No Data was Received after TCP Header");
339
359
}
340
360
341
361
if(receivedData.Count<tcpMessageDataLength)
342
362
{
343
-
thrownewOmronException("Failed to Receive FINS Message within the Timeout Period from Omron PLC '"+base.RemoteHost+":"+base.Port+"'");
363
+
thrownewOmronException("Failed to Receive FINS Message within the Timeout Period from Omron PLC '"+RemoteHost+":"+Port+"'");
0 commit comments