From owner-freebsd-hackers@FreeBSD.ORG Sat Jan 10 00:32:54 2004 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id B759516A4CE for ; Sat, 10 Jan 2004 00:32:54 -0800 (PST) Received: from Vitsch.net (b74143.upc-b.chello.nl [212.83.74.143]) by mx1.FreeBSD.org (Postfix) with ESMTP id A581E43D55 for ; Sat, 10 Jan 2004 00:32:52 -0800 (PST) (envelope-from Danovitsch@Vitsch.net) Received: from FreeBSD.Danovitsch.LAN (b83007.upc-b.chello.nl [212.83.83.7]) by Vitsch.net (8.12.3p2/8.11.3) with ESMTP id i0A8WSXe031866; Sat, 10 Jan 2004 09:32:33 +0100 (CET) (envelope-from Danovitsch@Vitsch.net) Content-Type: text/plain; charset="iso-8859-1" From: "Daan Vreeken [PA4DAN]" To: Vladimir Terziev Date: Sat, 10 Jan 2004 09:32:48 +0100 User-Agent: KMail/1.4.3 References: <20040109180305.18c23192.vlady@sun-fish.com> In-Reply-To: <20040109180305.18c23192.vlady@sun-fish.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Message-Id: <200401100932.48758.Danovitsch@Vitsch.net> cc: FreeBSD-hackers@FreeBSD.org Subject: Re: UNIX / BSD parallel port programming documentation X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 10 Jan 2004 08:32:54 -0000 On Friday 09 January 2004 17:03, Vladimir Terziev wrote: > Hi hackers, > > =09I have to develop small server which has to manage custom microcontr= oller > via parallel port interface. > =09Does anyone know good manual/documentation about UNIX / BSD parallel= port > programming ? Most of it should already be on your system, have a look at the man-pages= =2E If you want to use the ppbus interface to control the port : man lpt(4), ppbus(4) and ppi(4) If you want to directly address the ports registers yourself without usin= g the=20 driver interface : man io(4) and have a look at /usr/include/machine/cpufunc.h On FreeBSD you need to have opened /dev/io before your program is allowed= to=20 do direct IO to any device, and on Linux you need to successfully call=20 ioperm() first. grtz, Daan