How to use inpout32.dll in Visual C++ ?

Status
Not open for further replies.

eng.

Junior Member level 3
Joined
Jul 15, 2004
Messages
31
Helped
1
Reputation
2
Reaction score
1
Trophy points
1,288
Activity points
243
inpout32 problem

i am writting a c program for controlling lcd module using visual c++
using inpout32.dll from **broken link removed** but i don't
know how to use this dll . the samples with it is vb not vc.
i searched but didn't find any useful information.
can anyone help me?
Thanks in advance.
 

Re: inpout32 problem

here example for using visual c++ and inpout32.dll

8)
 

Re: inpout32 problem

thanks , but sorry i wasn't clear in my question .
i was asking for a c++ code under visual studio compiler
not visual c++. so if anyone knows how to load this dll for a
console app. i will be glad
 

Re: inpout32 problem

To use it in console app, based on: LoadLibrary & GetProcAddress
The author release all source code: **broken link removed**
To check its 'test applications' which offered an example C code in console with Borland free command-line C/C++ compiler.
 

Re: inpout32 problem

Thanks , i used the provided vc code but i don't know why including
stdafx.h i tried to remove this incluse but i received an error . i have
also included the source code.
Regards and thank you in advance

/////////////////////////////start////////////////////////////////

#include "stdafx.h"
#include "stdio.h"
#include "conio.h"

/* ----Prototypes of Inp and Outp--- */

short _stdcall Inp32(short PortAddress);
void _stdcall Out32(short PortAddress, short data);

/* --------------------------------- */

int main()
{
Out32(0x378,22);
int x=Inp32(0x378);
printf("%d\n",x);
getch();

}
//////////////////////////////end//////////////////////////////////
 

Status
Not open for further replies.
Cookies are required to use this site. You must accept them to continue using the site. Learn more…