Home

Attachments
SecurtyAgent.png (803 bytes)
There is a newer version of this page. You can find it here.

Currently under maintenance

Examples for Net Base Services library

All examples work with or without tls communication. If tls connection is required, the addon 'CODESYS Security Agend' is mandatory to create certificates. To open the securty agend click at the bottom right on the securty agend symbol:
Select Devices -> there you can create a new certificate for NBSServer and also for Client, if NBSServer or NBSClient information is not available, a download in advance is required.

Download project

Example for TCP Server <-> TCP Client

The project contains two devices, a CODESYS Control Win V3 and a CODESYS Control Win V3 x64, each with one application in it to simulate a Server - Client relationship. Set up in Client -> CLIENT_PRG the client common name and the appropriate ip address, as well as for Server -> SERVER_PRG. If tls communication is not necessary the variable myTLSContext can be removed (SERVER_PRG and CLIENT_PRG). Server application (myServer) should be enabled first.

Download project

Example for TCP Reader <-> TCP Processor <-> TCP Writer

This examples contains two devices, a CODESYS Control Win V3 and a CODESYS Control Win V3 x64, each with one application in it to simulate a Server - Client relationship. In client application there is a function block called TCP_Manipulator, which extends the NBS.TCP_Processor and in its method ProcessStream the tcp stream gets manipulated. Means the string value which is send from client to server and vice versa is changed every time the ProcessStream gets through. The ip addresses of server and client adapter can be set in POU-> GVL as well as the port. If tls communication is not necessary the variable myTLSContext can be removed (SERVER_PRG and CLIENT_PRG). Server application (myServer) should be enabled first.

Download project

Example for UDP Peer <-> IPeer.Receive, IPeer.Send

Download project

Example for UDP Receiver <-> UDP Processor <-> UDP Sender

System requirements and restrictions

System requirements and restrictions Info
Programming System CODESYS Development System Version 3.5.16.0 or higher
Runtime System CODESYS Control Version 3.5.16.0
Required Accessories -