You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@plc4x.apache.org by sr...@apache.org on 2018/06/28 15:36:39 UTC

[incubator-plc4x] branch master updated (a7cc186 -> fff1b70)

This is an automated email from the ASF dual-hosted git repository.

sruehl pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-plc4x.git.


    from a7cc186  modbus: added some logging and pdu todo
     new 4fe91d0  fixed small typo
     new fff1b70  added logging for incoming tcp payload

The 2 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 .../java/org/apache/plc4x/java/modbus/netty/Plc4XModbusProtocol.java   | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)


[incubator-plc4x] 01/02: fixed small typo

Posted by sr...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

sruehl pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-plc4x.git

commit 4fe91d0516c2194d4e4d704c38981cb4d85e926f
Author: Sebastian Rühl <sr...@apache.org>
AuthorDate: Thu Jun 28 17:33:17 2018 +0200

    fixed small typo
---
 .../java/org/apache/plc4x/java/modbus/netty/Plc4XModbusProtocol.java    | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/plc4j/protocols/modbus/src/main/java/org/apache/plc4x/java/modbus/netty/Plc4XModbusProtocol.java b/plc4j/protocols/modbus/src/main/java/org/apache/plc4x/java/modbus/netty/Plc4XModbusProtocol.java
index 6a4a2aa..b6852b1 100644
--- a/plc4j/protocols/modbus/src/main/java/org/apache/plc4x/java/modbus/netty/Plc4XModbusProtocol.java
+++ b/plc4j/protocols/modbus/src/main/java/org/apache/plc4x/java/modbus/netty/Plc4XModbusProtocol.java
@@ -53,7 +53,7 @@ public class Plc4XModbusProtocol extends MessageToMessageCodec<ModbusTcpPayload,
     @Override
     protected void encode(ChannelHandlerContext ctx, PlcRequestContainer<PlcRequest, PlcResponse> msg, List<Object> out) throws Exception {
         LOGGER.trace("(<--OUT): {}, {}, {}", ctx, msg, out);
-        // Reset tranactionId on overflow
+        // Reset transactionId on overflow
         transactionId.compareAndSet(Short.MAX_VALUE + 1, 0);
         PlcRequest request = msg.getRequest();
         if (request instanceof PlcReadRequest) {


[incubator-plc4x] 02/02: added logging for incoming tcp payload

Posted by sr...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

sruehl pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-plc4x.git

commit fff1b7074a1939d7d29fd3f5625c4b6eff7fa763
Author: Sebastian Rühl <sr...@apache.org>
AuthorDate: Thu Jun 28 17:36:35 2018 +0200

    added logging for incoming tcp payload
---
 .../java/org/apache/plc4x/java/modbus/netty/Plc4XModbusProtocol.java     | 1 +
 1 file changed, 1 insertion(+)

diff --git a/plc4j/protocols/modbus/src/main/java/org/apache/plc4x/java/modbus/netty/Plc4XModbusProtocol.java b/plc4j/protocols/modbus/src/main/java/org/apache/plc4x/java/modbus/netty/Plc4XModbusProtocol.java
index b6852b1..b54810f 100644
--- a/plc4j/protocols/modbus/src/main/java/org/apache/plc4x/java/modbus/netty/Plc4XModbusProtocol.java
+++ b/plc4j/protocols/modbus/src/main/java/org/apache/plc4x/java/modbus/netty/Plc4XModbusProtocol.java
@@ -137,6 +137,7 @@ public class Plc4XModbusProtocol extends MessageToMessageCodec<ModbusTcpPayload,
     @Override
     protected void decode(ChannelHandlerContext ctx, ModbusTcpPayload msg, List<Object> out) throws Exception {
         LOGGER.trace("(-->IN): {}, {}, {}", ctx, msg, out);
+        LOGGER.debug("{}: transactionId: {}, unitId: {}, modbusPdu:{}", msg, msg.getTransactionId(), msg.getUnitId(), msg.getModbusPdu());
         // TODO: implement me
         short transactionId = msg.getTransactionId();
         PlcRequestContainer<PlcRequest, PlcResponse> plcRequestContainer = requestsMap.get(transactionId);