using System;
using System.Runtime.InteropServices;
public class PortAccess

{

[DllImport("inpout32.dll", EntryPoint="Out32")]
        public static extern void Output(int adress, int value);

[DllImport("inpout32.dll", EntryPoint="Inp32")] 
        public static extern int Input(int adress); 
}

//Output函数为给端口传送数据,Input是从端口读取数据 如:

PortAccess.Input( 888 );//从888(即0x378)端口读取数据

PortAccess.Output( 888, 4 )//把4从888端口输出

最新文章

  1. JDK自带工具列表
  2. push submodule
  3. Java命令提示符编译
  4. CodeForces - 420A (字符对称问题)
  5. 使用MediaPlayer播放音频-----之一
  6. 1709. Penguin-Avia(并查集)
  7. 经验之巧妙的应用Map
  8. ajax jquery return没有返回值
  9. 移动app接口编程技术-学习实现之PHP进阶 数组
  10. HDU 4247 A Famous ICPC Team
  11. JavaScript中return的用法和this的用法详解
  12. <魔域>按键精灵脚本
  13. MySQL CURTIME() 函数
  14. Html.ActionLink与Url.Action区别
  15. [P1879][USACO06NOV]玉米田Corn Fields (状态压缩)
  16. Linux命令(十八) 压缩或解压缩文件和目录 gzip gunzip
  17. MVC扩展生成CheckBoxList并水平排列
  18. OK335xS 256M 512M nand flash make ubifs hacking
  19. Python学习笔记(二)--变量和数据类型
  20. eslint 错误

热门文章

  1. js之10天内免登陆
  2. Redis学习总结之三——Redis客户端命令
  3. BD09坐标(百度坐标) WGS84(GPS坐标) GCJ02(国测局坐标) 的相互转换
  4. BZOJ4987:Tree (树形DP)
  5. BZOJ1026 SCOI2009 windy数 【数位DP】
  6. 《selenium2 python 自动化测试实战》(15)——调用js控制滚动条等操作
  7. direct2D图片处理
  8. iOS App多语言国际化
  9. OpenStack_Swift源代码分析——Ring的rebalance算法源代码具体分析
  10. oralce之 10046对Hash Join分析