Borland C++ reference

outp

raw OCR

Outputs a byte to a hardware port.

Defined in header <conio.h>

Syntax

#include <conio.h>
int outp(unsigned    portid, int value);

Portability

DOSUNIXWindowsANSI CC++ only
■■

Remarks

outp is a macro that writes the low byte of value to the output port specified by portid.

If outp is called when conio.h has been included, it will be treated as a macro that expands to inline code. If you don't include conio.h, or if you do include conio.h and #undef the macro outp, you'll get the outp function.

Return value

outp returns value.

See also

Example

 #include <stdio.h>
■#include <conio.h>

 int main(void)
 {
   unsigned  port = 0;
    int value;
   value  = outp(port, 'C');
   printf ("Value %c sent to port number %d\n",  value, port);
    return 0;

Differences from modern implementations

Nothing recorded yet.

Modern references

These are search links, not yet checked by hand.