You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@plc4x.apache.org by GitBox <gi...@apache.org> on 2023/01/06 10:35:51 UTC

[GitHub] [plc4x] nmgwr opened a new issue, #731: [Feature Request]: Can the s7-200-cn plc support it?

nmgwr opened a new issue, #731:
URL: https://github.com/apache/plc4x/issues/731

   ### What would you like to happen?
   
   Can the s7-200-cn plc support it?
   ![Uploading image.png…]()
   
   
   ### Programming Languages
   
   - [X] plc4j
   - [ ] plc4go
   - [ ] plc4c
   - [ ] plc4net
   
   ### Protocols
   
   - [ ] AB-Ethernet
   - [ ] ADS /AMS
   - [ ] BACnet/IP
   - [ ] CANopen
   - [ ] DeltaV
   - [ ] DF1
   - [ ] EtherNet/IP
   - [ ] Firmata
   - [ ] KNXnet/IP
   - [ ] Modbus
   - [ ] OPC-UA
   - [X] S7


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@plc4x.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [plc4x] nmgwr commented on issue #731: [Feature Request]: Can the s7-200-cn plc support it?

Posted by GitBox <gi...@apache.org>.
nmgwr commented on issue #731:
URL: https://github.com/apache/plc4x/issues/731#issuecomment-1373469256

   The s7 200 smart is indeed supported by the test of the development branch I used. S7 200 cn reports the following error:
   
   
   
   java.io.IOException: Connection reset by peer
   	at java.base/sun.nio.ch.FileDispatcherImpl.read0(Native Method) ~[na:na]
   	at java.base/sun.nio.ch.SocketDispatcher.read(SocketDispatcher.java:39) ~[na:na]
   	at java.base/sun.nio.ch.IOUtil.readIntoNativeBuffer(IOUtil.java:276) ~[na:na]
   	at java.base/sun.nio.ch.IOUtil.read(IOUtil.java:233) ~[na:na]
   	at java.base/sun.nio.ch.IOUtil.read(IOUtil.java:223) ~[na:na]
   	at java.base/sun.nio.ch.SocketChannelImpl.read(SocketChannelImpl.java:356) ~[na:na]
   	at io.netty.buffer.PooledByteBuf.setBytes(PooledByteBuf.java:258) ~[netty-buffer-4.1.77.Final.jar:4.1.77.Final]
   	at io.netty.buffer.AbstractByteBuf.writeBytes(AbstractByteBuf.java:1132) ~[netty-buffer-4.1.77.Final.jar:4.1.77.Final]
   	at io.netty.channel.socket.nio.NioSocketChannel.doReadBytes(NioSocketChannel.java:357) ~[netty-transport-4.1.77.Final.jar:4.1.77.Final]
   	at io.netty.channel.nio.AbstractNioByteChannel$NioByteUnsafe.read(AbstractNioByteChannel.java:151) ~[netty-transport-4.1.77.Final.jar:4.1.77.Final]
   	at io.netty.channel.nio.NioEventLoop.processSelectedKey(NioEventLoop.java:722) ~[netty-transport-4.1.77.Final.jar:4.1.77.Final]
   	at io.netty.channel.nio.NioEventLoop.processSelectedKeysOptimized(NioEventLoop.java:658) ~[netty-transport-4.1.77.Final.jar:4.1.77.Final]
   	at io.netty.channel.nio.NioEventLoop.processSelectedKeys(NioEventLoop.java:584) ~[netty-transport-4.1.77.Final.jar:4.1.77.Final]
   	at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:496) ~[netty-transport-4.1.77.Final.jar:4.1.77.Final]
   	at io.netty.util.concurrent.SingleThreadEventExecutor$4.run(SingleThreadEventExecutor.java:995) ~[netty-common-4.1.77.Final.jar:4.1.77.Final]
   	at io.netty.util.internal.ThreadExecutorMap$2.run(ThreadExecutorMap.java:74) ~[netty-common-4.1.77.Final.jar:4.1.77.Final]
   	at io.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30) ~[netty-common-4.1.77.Final.jar:4.1.77.Final]
   	at java.base/java.lang.Thread.run(Thread.java:829) ~[na:na]
   
   org.apache.plc4x.java.api.exceptions.PlcConnectionException: org.apache.plc4x.java.api.exceptions.PlcConnectionException: java.util.concurrent.ExecutionException: org.apache.plc4x.java.api.exceptions.PlcIoException: Connection terminated by remote
   	at org.apache.plc4x.java.utils.connectionpool.PooledPlcDriverManager.getConnection(PooledPlcDriverManager.java:122)
   	at org.apache.plc4x.java.utils.connectionpool.PooledPlcDriverManager.getConnection(PooledPlcDriverManager.java:101)
   	at com.nmgwr.plc4xdemo.demo.Demo.run(Demo.java:33)
   	at org.springframework.boot.SpringApplication.callRunner(SpringApplication.java:762)
   	at org.springframework.boot.SpringApplication.callRunners(SpringApplication.java:752)
   	at org.springframework.boot.SpringApplication.run(SpringApplication.java:315)
   	at org.springframework.boot.SpringApplication.run(SpringApplication.java:1306)
   	at org.springframework.boot.SpringApplication.run(SpringApplication.java:1295)
   	at com.nmgwr.plc4xdemo.Plc4xDemoApplication.main(Plc4xDemoApplication.java:10)
   Caused by: org.apache.plc4x.java.api.exceptions.PlcConnectionException: java.util.concurrent.ExecutionException: org.apache.plc4x.java.api.exceptions.PlcIoException: Connection terminated by remote
   	at org.apache.plc4x.java.spi.connection.DefaultNettyPlcConnection.connect(DefaultNettyPlcConnection.java:144)
   	at org.apache.plc4x.java.PlcDriverManager.getConnection(PlcDriverManager.java:78)
   	at org.apache.plc4x.java.utils.connectionpool.PooledPlcDriverManager.access$1(PooledPlcDriverManager.java:1)
   	at org.apache.plc4x.java.utils.connectionpool.PooledPlcDriverManager$1.create(PooledPlcDriverManager.java:90)
   	at org.apache.plc4x.java.utils.connectionpool.PooledPlcDriverManager$1.create(PooledPlcDriverManager.java:1)
   	at org.apache.commons.pool2.BaseKeyedPooledObjectFactory.makeObject(BaseKeyedPooledObjectFactory.java:82)
   	at org.apache.commons.pool2.impl.GenericKeyedObjectPool.create(GenericKeyedObjectPool.java:780)
   	at org.apache.commons.pool2.impl.GenericKeyedObjectPool.borrowObject(GenericKeyedObjectPool.java:439)
   	at org.apache.commons.pool2.impl.GenericKeyedObjectPool.borrowObject(GenericKeyedObjectPool.java:350)
   	at org.apache.plc4x.java.utils.connectionpool.PooledPlcDriverManager.getConnection(PooledPlcDriverManager.java:116)
   	... 8 more
   Caused by: java.util.concurrent.ExecutionException: org.apache.plc4x.java.api.exceptions.PlcIoException: Connection terminated by remote
   	at java.base/java.util.concurrent.CompletableFuture.reportGet(CompletableFuture.java:395)
   	at java.base/java.util.concurrent.CompletableFuture.get(CompletableFuture.java:1999)
   	at org.apache.plc4x.java.spi.connection.DefaultNettyPlcConnection.connect(DefaultNettyPlcConnection.java:135)
   	... 17 more
   Caused by: org.apache.plc4x.java.api.exceptions.PlcIoException: Connection terminated by remote
   	at org.apache.plc4x.java.spi.connection.DefaultNettyPlcConnection.lambda$1(DefaultNettyPlcConnection.java:127)
   	at io.netty.util.concurrent.DefaultPromise.notifyListener0(DefaultPromise.java:578)
   	at io.netty.util.concurrent.DefaultPromise.notifyListeners0(DefaultPromise.java:571)
   	at io.netty.util.concurrent.DefaultPromise.notifyListenersNow(DefaultPromise.java:550)
   	at io.netty.util.concurrent.DefaultPromise.notifyListeners(DefaultPromise.java:491)
   	at io.netty.util.concurrent.DefaultPromise.setValue0(DefaultPromise.java:616)
   	at io.netty.util.concurrent.DefaultPromise.setSuccess0(DefaultPromise.java:605)
   	at io.netty.util.concurrent.DefaultPromise.trySuccess(DefaultPromise.java:104)
   	at io.netty.channel.DefaultChannelPromise.trySuccess(DefaultChannelPromise.java:84)
   	at io.netty.channel.AbstractChannel$CloseFuture.setClosed(AbstractChannel.java:1164)
   	at io.netty.channel.AbstractChannel$AbstractUnsafe.doClose0(AbstractChannel.java:755)
   	at io.netty.channel.AbstractChannel$AbstractUnsafe.close(AbstractChannel.java:731)
   	at io.netty.channel.AbstractChannel$AbstractUnsafe.close(AbstractChannel.java:620)
   	at io.netty.channel.nio.AbstractNioByteChannel$NioByteUnsafe.closeOnRead(AbstractNioByteChannel.java:105)
   	at io.netty.channel.nio.AbstractNioByteChannel$NioByteUnsafe.handleReadException(AbstractNioByteChannel.java:130)
   	at io.netty.channel.nio.AbstractNioByteChannel$NioByteUnsafe.read(AbstractNioByteChannel.java:177)
   	at io.netty.channel.nio.NioEventLoop.processSelectedKey(NioEventLoop.java:722)
   	at io.netty.channel.nio.NioEventLoop.processSelectedKeysOptimized(NioEventLoop.java:658)
   	at io.netty.channel.nio.NioEventLoop.processSelectedKeys(NioEventLoop.java:584)
   	at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:496)
   	at io.netty.util.concurrent.SingleThreadEventExecutor$4.run(SingleThreadEventExecutor.java:995)
   	at io.netty.util.internal.ThreadExecutorMap$2.run(ThreadExecutorMap.java:74)
   	at io.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30)
   	at java.base/java.lang.Thread.run(Thread.java:829)
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@plc4x.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [plc4x] nmgwr commented on issue #731: [Feature Request]: Can the s7-200-cn plc support it?

Posted by GitBox <gi...@apache.org>.
nmgwr commented on issue #731:
URL: https://github.com/apache/plc4x/issues/731#issuecomment-1373463246

   https://github.com/s7connector/s7connector
   I tried to use this driver to read and write, but there are bugs in this driver


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@plc4x.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [plc4x] chrisdutz commented on issue #731: [Feature Request]: Can the s7-200-cn plc support it?

Posted by GitBox <gi...@apache.org>.
chrisdutz commented on issue #731:
URL: https://github.com/apache/plc4x/issues/731#issuecomment-1373482494

   If you want to use the S7200 smart thing ... you need to tell the driver about the type of plc, so it will not ask the PLC. Because in case of the S7200 it just hangs up (which you are seeing in your exception) ... so please add: 
   `?controller-type=S7_200`
   To your connection string.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@plc4x.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [plc4x] chrisdutz commented on issue #731: [Feature Request]: Can the s7-200-cn plc support it?

Posted by GitBox <gi...@apache.org>.
chrisdutz commented on issue #731:
URL: https://github.com/apache/plc4x/issues/731#issuecomment-1373455681

   Well ... so far we haven't implemented a S7 protocol via serial ... in theory it should be possible to do so, but I would say that out-of-the-box the current driver doesn't support this.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@plc4x.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [plc4x] chrisdutz commented on issue #731: [Feature Request]: Can the s7-200-cn plc support it?

Posted by GitBox <gi...@apache.org>.
chrisdutz commented on issue #731:
URL: https://github.com/apache/plc4x/issues/731#issuecomment-1373479664

   Well the "host" and "port" on the above code snippet implicates a network connection ... the picture you sent indicates a serial communication. And yes... from a quick look at the "open issues" that project does seem to have quit a number of unattended issues ... I assume it's abandoned.
   
   And regarding "me wanting to support" ... Today I finally burried my company (c-ware) ... My plans were to make a living based on PLC4X consulting, but the industry wasn't willing to pay for anything. So I have shifted my priorities. I do on PLC4X, what I need for my dayjob at Rivian or what I'm simply interested in. 
   
   I am interested in helping the community and the project alive, but I'm no longer simply implementing features, just because they were asked for. 
   
   So I am happy to assist you with implementing this feature, but I'm not going to do it for you. (Mabe someone else will do that)


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@plc4x.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [plc4x] nmgwr commented on issue #731: [Feature Request]: Can the s7-200-cn plc support it?

Posted by GitBox <gi...@apache.org>.
nmgwr commented on issue #731:
URL: https://github.com/apache/plc4x/issues/731#issuecomment-1373464930

   ![image](https://user-images.githubusercontent.com/32054165/210997983-af710318-929b-4fd3-b70e-e717e414bb3c.png)
   type is S200


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@plc4x.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [plc4x] nmgwr commented on issue #731: [Feature Request]: Can the s7-200-cn plc support it?

Posted by GitBox <gi...@apache.org>.
nmgwr commented on issue #731:
URL: https://github.com/apache/plc4x/issues/731#issuecomment-1373494086

   String connectionString = "s7://192.168.33.203?remote-rack=0&remote-slot=1&controller-type=S7_200";
   
   this is my connectionString.
   
   Anyway, I would like to thank you for your reply. Plc4x is a great project! I will use it in my project. As for s7 200 cn, I will think of other ways. Thank you.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@plc4x.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [plc4x] nmgwr commented on issue #731: [Feature Request]: Can the s7-200-cn plc support it?

Posted by GitBox <gi...@apache.org>.
nmgwr commented on issue #731:
URL: https://github.com/apache/plc4x/issues/731#issuecomment-1373452869

   ![image](https://user-images.githubusercontent.com/32054165/210990935-61ea979b-f780-4253-a51b-42e604b6074e.png)
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@plc4x.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [plc4x] nmgwr commented on issue #731: [Feature Request]: Can the s7-200-cn plc support it?

Posted by GitBox <gi...@apache.org>.
nmgwr commented on issue #731:
URL: https://github.com/apache/plc4x/issues/731#issuecomment-1373465751

   If you want to support the s7 200 cn in the future, I hope I can help you!


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@plc4x.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [plc4x] nmgwr closed issue #731: [Feature Request]: Can the s7-200-cn plc support it?

Posted by GitBox <gi...@apache.org>.
nmgwr closed issue #731: [Feature Request]: Can the s7-200-cn plc support it?
URL: https://github.com/apache/plc4x/issues/731


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@plc4x.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org