avinsinanan
New Member
Hello I am using TURBO C to read an input valuie from the Parallel Port.
I am putting Assembly language in Turbo C. However the printf statement is not printing the value in the regsiter. WHy?
Here is the code -
# include <stdio.h>
#define PORT_ADDRESS 0x379
void main()
{
for(int i=0;;i++)
{
asm {
MOV DX , 0379H
IN AX,DX
}
printf(DX);
}
}
Why isn't it working?
Thanks
I am putting Assembly language in Turbo C. However the printf statement is not printing the value in the regsiter. WHy?
Here is the code -
# include <stdio.h>
#define PORT_ADDRESS 0x379
void main()
{
for(int i=0;;i++)
{
asm {
MOV DX , 0379H
IN AX,DX
}
printf(DX);
}
}
Why isn't it working?
Thanks