我在98下可以用的读端口的汇编程序在2000下怎么就不能用了呢,我该怎么该才能用,有谁愿意帮我,谢谢。

解决方案 »

  1.   

    The CreateFile function creates or opens the following objects and returns a handle that can be used to access the object: Consoles 
    Communications resources 
    Directories (open only) 
    Disk devices (Windows NT/2000 only) 
    Files 
    Mailslots 
    Pipes 
    HANDLE CreateFile(
      LPCTSTR lpFileName,                         // file name
      DWORD dwDesiredAccess,                      // access mode
      DWORD dwShareMode,                          // share mode
      LPSECURITY_ATTRIBUTES lpSecurityAttributes, // SD
      DWORD dwCreationDisposition,                // how to create
      DWORD dwFlagsAndAttributes,                 // file attributes
      HANDLE hTemplateFile                        // handle to template file
    );
      

  2.   

    这里找不到答案吗?来这里试试看!
    这里有问必答
    http://systemer.51.net/cgi-bin/leoboard.cgi
    希望你能在这里找到你满意的答案
      

  3.   

    到 VC/MFC 硬件/系统  的精华区去看看,有您要的东东,下载个WinIO即可
      

  4.   

    Windows 2000是不允许直接访问硬件的,除非你进入了Kernel Mode。可以自己写个驱动程序,通过驱动程序去访问端口,或者使用现成的WinIO。