Port-Mapped I/O and Memory-Mapped I/O is the key method to connect from CPU to I/O Peripherals. Do you need to write applications to access Memory-mapped IO addresses using Delphi/C++? Don’t know where to start? Don’t worry, WINSOFT helped us with a component to do the job quickly.
Features:
- Access to I/O and memory-mapped ports on 32 and 64-bit Windows
- PnP device drivers built using Microsoft KMDF WDK framework
- Easy of use, component is fully auto configurable
- Block data transfer enables high-speed data transfer
- DirectAccess mode provides the fastest access to I/O ports (32-bit Windows only)
Versions Supported: Delphi/C++ Builder 5 – 10.4 and Lazarus 2.0.8
Platforms: Windows;
Installation Steps:
Prerequisites: Ensure 11.2 MB minimum free space available in the system.
- Download IOPort Setup and Right-click Open.
- Read the Information Window about features, installation, and copyright. Click Next.
- Browse for the custom destination folder to install and click Next.
- Browse for the custom Start Menu folder and click Next. You can ignore creating by clicking the checkbox Don’t create a Start Menu folder option.
- Review your folder settings and click Install. You can click Back to change your folder settings.
- Once Installation Progress is done click Finish.
- Ensure the IOPort files are shown in the chosen Start Menu Folder by clicking Windows Start Menu.
Installation Steps Demo: IOPort Installation Demo:
Key concepts:
- Memory-mapped I/O is mapped into the same address space as program memory and/or user memory and is accessed in the same way.
- Port mapped I/O uses a separate, dedicated address space and is accessed via a dedicated set of microprocessor instructions.
How to build applications using IOPort component:
- Open Rad Studio 10.4.1 and Create a Windows VCL Application. Navigate to Components bar -> System. Check the IOPort Component installed as shown.
2. Drag and Drop the TIOPort component or by adding IOPort.pas into your unit and create these components by code.
TIOPort: Enables to access Windows I/O and memory-mapped ports.
- Active: Enables or disables access to I/O ports..
- DirectAccess: Enables the fastest I/O port access using undocumented Windows functions. Allows direct access to I/O ports from the application instead of calling the device driver for each I/O access. Direct access is supported on 32-bit Windows only.
- Port[Index: DWord]: For reading and writing a byte/word/double word from/to the specified I/O port.
- Register[Index: DWord]: For reading and writing a byte/word/double word/quadword from/to the specified memory-mapped port.
- ReadByteBuff/WriteByteBuff: Method to Read/Write a number of bytes/words/double words from the specified I/O port to a memory buffer.
3. Get the physical memory addresses for Memory mapped IO.
4. Use Methods such as ReadByteRegisterBuf/WriteByteRegisterBuf to read/write a number of bytes/words/double words/quad words from the specified memory-mapped port to a memory buffer.
Sample Application Demo:
Conclusion: Easily you can build Applications using WINSOFT IOPort component to access Windows I/O and Memory-mapped ports and save your effort.
Check out the full WINSOFT IOPort for Access in Delphi and C++Builder Applications.