OSDN Git Service
(root)
/
unagi
/
old-svn-converted.git
/ blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
history
|
raw
|
HEAD
client 0.6.2 release
[unagi/old-svn-converted.git]
/
client
/
tag
/
0.6.2
/
paralellport.h
1
/*
2
famicom ROM cartridge utility - unagi
3
¥Ñ¥é¥ì¥ë¥Ý¡¼¥È¶¦ÍÄêµÁ
4
*/
5
#ifndef _PARALELL_PORT_INLINE_H_
6
#define _PARALELL_PORT_INLINE_H_
7
#include "giveio.h"
8
#include <windows.h>
9
#define ASM_ENABLE (0)
10
enum{
11
PORT_DATA = 0x0378,
12
PORT_BUSY,
13
PORT_CONTROL
14
};
15
16
int _inp(int);
17
#if ASM_ENABLE==0
18
void _outp(int, int);
19
#else
20
static inline void _outp(int address, int data){
21
asm(
22
" movl %0,%%edx\n"
23
" movl %1,%%eax\n"
24
" out %%al,%%dx\n"
25
:: "q"(address), "q"(data): "%edx", "%eax"
26
);
27
}
28
#endif
29
30
#endif