Solved

outpw/outport

Posted on 1997-01-28
1
692 Views
Last Modified: 2008-03-10
I am attempting to access a card on the ISA bus using Borland C++ 3.1's outpw() and outport() commands, but in both cases the I/O write line goes low (active low) twice while the address is still valid causing the wrong values to be latched because the data is no longer valid on the second strobe. However, that only happens when I attempt to do 16 bit transfers, eight bit transfers work like a charm. Am I doing something wrong or is this simply how the two byte transfer works and I simply have to design around it. Please reply by email.
0
Comment
Question by:robertsb110896
1 Comment
 

Accepted Solution

by:
michaelf earned 50 total points
Comment Utility
Hi.
Actually it is not about C++ or borland, but
just about ISA bus. ISA bus designed to work
with old style 8-bit devices as well as 16-bit
devices. And I/O device (slave) must tell
CPU (master) wether it is capable to accept /
transmit 16 bit data or just 8 bit.
If it is 8-bit device and program is using
16-bit I/O instructions (using Borland
outpw(), for example) CPU will transfer
data byte by byte: first low order byte
to the specified port, then high order
byte to the port with address greater by
one. I believe it is your case.

If you want to receve 16 bit of data
at once, you have to assert special
signal that tells that it is 16-bit
slave device. I do not have ISA bus
description with me, but according
to the brief table I do have it is
"I/O 16 chip select : D2". You have to
check it using complete ISA bus
description.
  Regards,
      MichaelF

0

Featured Post

Free Trending Threat Insights Every Day

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

Join & Write a Comment

Introduction This article is a continuation of the C/C++ Visual Studio Express debugger series. Part 1 provided a quick start guide in using the debugger. Part 2 focused on additional topics in breakpoints. As your assignments become a little more …
C++ Properties One feature missing from standard C++ that you will find in many other Object Oriented Programming languages is something called a Property (http://www.experts-exchange.com/Programming/Languages/CPP/A_3912-Object-Properties-in-C.ht…
The goal of the tutorial is to teach the user how to use functions in C++. The video will cover how to define functions, how to call functions and how to create functions prototypes. Microsoft Visual C++ 2010 Express will be used as a text editor an…
The viewer will learn how to use the return statement in functions in C++. The video will also teach the user how to pass data to a function and have the function return data back for further processing.

762 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

Need Help in Real-Time?

Connect with top rated Experts

7 Experts available now in Live!

Get 1:1 Help Now