diff --git a/plc4j/protocols/ads/src/main/java/org/apache/plc4x/java/ads/connection/AdsTcpPlcConnection.java b/plc4j/protocols/ads/src/main/java/org/apache/plc4x/java/ads/connection/AdsTcpPlcConnection.java index d25169db004..49ee16ebac1 100644 --- a/plc4j/protocols/ads/src/main/java/org/apache/plc4x/java/ads/connection/AdsTcpPlcConnection.java +++ b/plc4j/protocols/ads/src/main/java/org/apache/plc4x/java/ads/connection/AdsTcpPlcConnection.java @@ -75,9 +75,9 @@ protected ChannelHandler getChannelHandler(CompletableFuture sessionSetupC protected void initChannel(Channel channel) { // Build the protocol stack for communicating with the ads protocol. ChannelPipeline pipeline = channel.pipeline(); - pipeline.addLast(new Plc4x2AdsProtocol(targetAmsNetId, targetAmsPort, sourceAmsNetId, sourceAmsPort)); - pipeline.addLast(new Ads2PayloadProtocol()); pipeline.addLast(new Payload2TcpProtocol()); + pipeline.addLast(new Ads2PayloadProtocol()); + pipeline.addLast(new Plc4x2AdsProtocol(targetAmsNetId, targetAmsPort, sourceAmsNetId, sourceAmsPort)); } }; }