Skip to content

Instantly share code, notes, and snippets.

@kwahoo2
Created January 14, 2015 19:46
Show Gist options
  • Save kwahoo2/e1a95a4eac7b3fd4b694 to your computer and use it in GitHub Desktop.
Save kwahoo2/e1a95a4eac7b3fd4b694 to your computer and use it in GitHub Desktop.
#include <stdio.h>
#include <sys/io.h>
#include <sys/perm.h>
#define BASEPORT 0x378
int main(void)
{
int inp = 0;
ioperm(BASEPORT+1,1,1); //rejestr statusu
int i;
for (i=0; i<10000000; i++)
{
inp = inb(BASEPORT+1);
//printf("%X ",inp);
}
return 0;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment