Home

mlamp
There is a newer version of this page. You can find it here.

Download project

Shared Memory

The shared memory can be used to exchange data within a target system when no direct
communication is possible, e.g. the data exchange with an external visualization.
How to create this shared memory and how to read and write to it is shown in this example.

Product description

Two applications are used for demonstration. Both must run on one target device.
The first one creates a shared memory and writes some values into it and the
second one reads from it.

Whenever direct communication within a target system is not possible, shared memory
can be used to exchange data.

More information

Write_App: This application creates a shared memory object and writes
some strings into the memory.

Read_App: This application tries to open the shared memory and read the data
in two different ways. On the one hand a data string of a given size is read.
On the other hand, the pointer to the first element is fetched and incremented until
the "End of Text" sign is reached. Afterwards the Memory is deleted.

Both applications have to be downloaded to the target device, by "Multiple Download"
or a separate download from each application.

To open a second CoDeSys Control, open the Windows "Start menu". Go to "3S CodeSys Control Win V3"
and open the "3S CodeSys Control Win V3". This is now running next to "CoDeSys Control Win Sys Tray".

System requirements and restrictions

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