Warning: file_get_contents(/data/phpspider/zhask/data//catemap/5/tfs/3.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Function Linux中的outb()函数调用是什么?_Function_Linux Kernel_Gpio_Hardware Port - Fatal编程技术网

Function Linux中的outb()函数调用是什么?

Function Linux中的outb()函数调用是什么?,function,linux-kernel,gpio,hardware-port,Function,Linux Kernel,Gpio,Hardware Port,有人能解释一下这个词的意思吗 outb(0x10,short_base+2); 我试着通过谷歌搜索找到答案,但没有用。系统调用在手册第2节中描述:man2outb void outb(unsigned char value, unsigned short int port); DESCRIPTION This family of functions is used to do low-level port input and output. The out* funct

有人能解释一下这个词的意思吗

outb(0x10,short_base+2);

我试着通过谷歌搜索找到答案,但没有用。

系统调用在手册第2节中描述:
man2outb

   void outb(unsigned char value, unsigned short int port);

DESCRIPTION
   This family of functions is used to do low-level port input and  output.
   The  out* functions do port output, the in* functions do port input; the
   b-suffix functions are byte-width and the w-suffix functions word-width;
   the _p-suffix functions pause until the I/O completes.

回答你的问题:

outb是具有相同名称的汇编指令的函数包装器,用于与端口映射设备通信,例如,I/O地址范围0x60-0x6F用于IBM PC兼容计算机中的键盘

现在,什么是端口映射IO

一种CPU到外围设备的通信方法,当处理器使用不同的地址总线与设备和存储器通信时使用,因此需要特殊的指令


内存映射I/O是当今另一种也是最常用的方法,它不需要特殊的指令,因为所有东西都位于同一个地址空间。

你在谷歌上搜索了什么?对“outb”的简单搜索给了我很多很好的点击率;谢谢你的回答:)