Click or drag to resize

IDirectMemoryAccessService Interface

PLC memory client service.

Namespace:  Demo3D.PLC.Comms.Memory
Assembly:  PLC (in PLC.dll) Version: 15.0.2.11458
Syntax
C#
public interface IDirectMemoryAccessService

The IDirectMemoryAccessService type exposes the following members.

Properties
  NameDescription
Public propertyAddressType
The type of address expected by this service. The type must implement IAddress.
Public propertyPduSize
Get the PDU size (or -1).
Public propertyRequestOverhead
A measure in bytes of the overhead of creating a new "read" request (or -1).
Top
Methods
  NameDescription
Public methodGetPreferredAddress
Returns the preferred access to the address space. The underlying protocol may prefer the user to access more data than addressed.
Public methodGetPreferredParameters
Parameters to be applied to accesses.
Public methodGetRequiredAddress
Returns the required access to the address space. The underlying protocol may require the user to access more data than addressed.
Public methodInternalReadV
Vectored block read to the peer.
Public methodInternalWriteV
Vectored block write to the peer.
Top
Extension Methods
  NameDescription
Public Extension MethodReadV
Vectored read request.
(Defined by DirectMemoryAccessService.)
Public Extension MethodWriteV
Vectored write request.
(Defined by DirectMemoryAccessService.)
Top
Remarks

This interface is intended to simplify the implementation of new memory-based protocols/connections, and not as a primary method of accessing the PLC. Consider using IMemoryService instead to access memory in a PLC.

IMemoryService has several advantages when accessing PLC memory. By accessing memory through GetAddress(IAddress, AccessParameters, Object) it forces the caller to be explicit about the addresses that are being accessed. This allows algorithms to build in-core memory caches, and to implement automatic notification when memory in the PLC changes. It also silently widens and batches memory read accesses to improve protocol performance.

Addresses passed to this services methods need not be exactly AddressType, but their AddressSpace must match.

See Also