//The below mentioned code is not working on my C compiler.The //errors im getting is :(1)Extra parameter in call to_ inport b_.
//(2)Too few parameters in call to "outport".(line 25)
//(3)Not an allowed type(line 25)
#include<stdio.h>
#include<conio.h>
#include<dos.h>
void main()
{
char data;
int choice;
clrscr();
printf("Enter the choice to send or receive from COM1::");
scanf("%d",&choice);
if(choice==1)
{
printf("Enter data to send::");
scanf("%c",data);
inportb(0x03f8,data);
}
else
{
data=outport(0x3f8);
printf("reding from COM1::%d",data);
}
getch();
}