Solved

About board addressing

Posted on 1998-06-10
1
130 Views
Last Modified: 2010-04-04
I want to address a data adquisition board (CIO-DIO96) on 300H (the board is addressing to 300H throught switchers) and I have tried it with pointers but it is not possible due to the PC memory mapping.
I want to know how could do it.
0
Comment
Question by:JGT
1 Comment
 

Accepted Solution

by:
jhun earned 100 total points
ID: 1351959
Here is a small funtions that reads from a io port:

function ReadFromPort ( adress: word): byte;
begin
   asm
     mov       dx, adress
     in            al, dx      { data from port }
   end;
end;

Because the result of a pascal function with result type is passed in al no futher action is nessecary to pass back the result. If you want to write to the port, replace the in al, dx with out dx, al

Gr. John

0

Featured Post

Free Tool: Postgres Monitoring System

A PHP and Perl based system to collect and display usage statistics from PostgreSQL databases.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

The uses clause is one of those things that just tends to grow and grow. Most of the time this is in the main form, as it's from this form that all others are called. If you have a big application (including many forms), the uses clause in the in…
In my programming career I have only very rarely run into situations where operator overloading would be of any use in my work.  Normally those situations involved math with either overly large numbers (hundreds of thousands of digits or accuracy re…
A short tutorial showing how to set up an email signature in Outlook on the Web (previously known as OWA). For free email signatures designs, visit https://www.mail-signatures.com/articles/signature-templates/?sts=6651 If you want to manage em…
I've attached the XLSM Excel spreadsheet I used in the video and also text files containing the macros used below. https://filedb.experts-exchange.com/incoming/2017/03_w12/1151775/Permutations.txt https://filedb.experts-exchange.com/incoming/201…

679 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question