> In message <20001227205505.A1199@wzab.nasz.dom>, Wojciech Zabolotny > writes > >No way !!! The IO-permission mechanism in Windows uses the CPU hardware, so > >it does not depend on the language (ASM vs Pascal). When the user (not "ring > >0") program executes the "in" or "out" operation, an exception occures, the > >kernel check wether this port is "virtualized" and either performs the > >standard in/out or executes the dedicated procedure provided by the > >appropriate VxD driver... > >The only way to avoid this time consuming overhead is to write the device > >driver, which is a piece of code which executes in the "ring 0" (like the > >kernel). > >This is true not only for Windows but for all "true" operating systems like > >Uni*es (including Linux). However in Linux one may write the standard > >program executing with root privileges, which can perform direct I/O without > >loss of performance. > You're talking about Windows NT, it works fine under 95, 98, and ME, > considering NT is very much a minority operating system only a small > percentage of user would have a problem with this. My 32 bit PIC > programmer uses a driver DLL so it works with NT, otherwise I would use > direct access just like the 16 bit version. NOT TRUE! Win95/Win98/WinMe _DO_ trap port I/O for virtualization. It is just that for many cases (ie: parallel port) they simulate the I/O and allow it to complete. This is _SLOW_. Bob Ammerman RAm Systems (contract development of high performance, high function, low-level software) -- http://www.piclist.com hint: PICList Posts must start with ONE topic: [PIC]:,[SX]:,[AVR]: ->uP ONLY! [EE]:,[OT]: ->Other [BUY]:,[AD]: ->Ads