rtapi_io.3rtapi
1 .\" Copyright (c) 2014 Jeff Epler 2 .\" 3 .\" This is free documentation; you can redistribute it and/or 4 .\" modify it under the terms of the GNU General Public License as 5 .\" published by the Free Software Foundation; either version 2 of 6 .\" the License, or (at your option) any later version. 7 .\" 8 .\" The GNU General Public License's references to "object code" 9 .\" and "executables" are to be interpreted as the output of any 10 .\" document formatting or typesetting system, including 11 .\" intermediate and printed output. 12 .\" 13 .\" This manual is distributed in the hope that it will be useful, 14 .\" but WITHOUT ANY WARRANTY; without even the implied warranty of 15 .\" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 .\" GNU General Public License for more details. 17 .\" 18 .\" You should have received a copy of the GNU General Public 19 .\" License along with this manual; if not, write to the Free 20 .\" Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, 21 .\" USA. 22 .TH funct "3rtapi" "2014-06-28" "LinuxCNC Documentation" "RTAPI" 23 .SH NAME 24 25 rtapi_io.h \- RTAPI wrappers for linux kernel functionality 26 27 .SH SYNTAX 28 .HP 29 #include <rtapi_io.h> 30 .HP 31 unsigned char rtapi_inb(unsigned short int port); 32 .HP 33 unsigned short rtapi_inw(unsigned short int port); 34 .HP 35 unsigned int rtapi_inl(unsigned short int port); 36 .HP 37 unsigned void rtapi_inb(unsigned char value, unsigned short int port); 38 .HP 39 unsigned void rtapi_inw(unsigned short value, unsigned short int port); 40 .HP 41 unsigned void rtapi_inl(unsigned int value, unsigned short int port); 42 43 .SH DESCRIPTION 44 In kernel space, each rtapi_xxx or RTAPI_XXX identifier is mapped to the 45 underlying kernel functionality, if available. 46 47 In userspace, or in kernels where the underlying functionality is not provided 48 by a kernel, generally another implementation--possibly with reduced 49 functionality--is provided. (For example, the userspace implementation for 50 rtapi_device_register always succeeds) 51 .SH REALTIME CONSIDERATIONS 52 Call from init/cleanup code and from realtime tasks. These functions will 53 cause illegal instruction exceptions in userspace components, as well as in 54 uspace rtapi_app when it is not setuid root. 55 .SH RETURN VALUE 56 As in Linux. 57 .SH SEE ALSO