From owner-freebsd-hackers@FreeBSD.ORG Tue Feb 1 23:17:21 2005 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 2AA9816A4CE for ; Tue, 1 Feb 2005 23:17:21 +0000 (GMT) Received: from mail25.sea5.speakeasy.net (mail25.sea5.speakeasy.net [69.17.117.27]) by mx1.FreeBSD.org (Postfix) with ESMTP id C0F6A43D62 for ; Tue, 1 Feb 2005 23:17:20 +0000 (GMT) (envelope-from jmg@hydrogen.funkthat.com) Received: (qmail 22704 invoked from network); 1 Feb 2005 23:17:20 -0000 Received: from gate.funkthat.com (HELO hydrogen.funkthat.com) ([69.17.45.168]) (envelope-sender ) by mail25.sea5.speakeasy.net (qmail-ldap-1.03) with SMTP for ; 1 Feb 2005 23:17:20 -0000 Received: from hydrogen.funkthat.com (mdazwt@localhost.funkthat.com [127.0.0.1])j11NHKGH057943; Tue, 1 Feb 2005 15:17:20 -0800 (PST) (envelope-from jmg@hydrogen.funkthat.com) Received: (from jmg@localhost) by hydrogen.funkthat.com (8.12.10/8.12.10/Submit) id j11NHIHr057942; Tue, 1 Feb 2005 15:17:18 -0800 (PST) Date: Tue, 1 Feb 2005 15:17:18 -0800 From: John-Mark Gurney To: Milan Obuch Message-ID: <20050201231718.GE19624@funkthat.com> Mail-Followup-To: Milan Obuch , freebsd-hackers@freebsd.org References: <200501141015.37516.bsd@dino.sk> <200501191000.51574.bsd@dino.sk> <20050120235104.GV19624@funkthat.com> <200501210652.42328.bsd@dino.sk> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <200501210652.42328.bsd@dino.sk> User-Agent: Mutt/1.4.1i X-Operating-System: FreeBSD 4.2-RELEASE i386 X-PGP-Fingerprint: B7 EC EF F8 AE ED A7 31 96 7A 22 B3 D8 56 36 F4 X-Files: The truth is out there X-URL: http://resnet.uoregon.edu/~gurney_j/ X-Resume: http://resnet.uoregon.edu/~gurney_j/resume.html cc: freebsd-hackers@freebsd.org Subject: Re: Geode integrated peripherals support? X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list Reply-To: John-Mark Gurney List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 01 Feb 2005 23:17:21 -0000 Milan Obuch wrote this message on Fri, Jan 21, 2005 at 06:52 +0100: > On Friday 21 January 2005 00:51, John-Mark Gurney wrote: > > Milan Obuch wrote this message on Wed, Jan 19, 2005 at 10:00 +0100: > > > > [skip] > > > Great, could we cooperate? > > > > Sure, though Joerg Wunsch has been doing work w/ I2C more recently than > > me, so you might want to drop him an email. > > > > Is he on this list? I have no other idea how coould I reach him. joerg@FreeBSD.org... Check the cvs logs of the i2c stuff.. :) > > > I know there are two modes - bit banging software i2c bus and real > > > hardware controller. Which one would be easier to begin with? With geode, > > > both are possible. Pins designed for ACCESS.bus (at least the second, > > > there are two buses integrated) can be used as GPIO pins. > > > > The hardware I worked on was bit banging only, so I used that interface > > and it was surprisingly easy, since you just define an interface that > > will get called by the i2c bus to do the necessary toggling... Of course > > this is more cpu intensive since it requires timing and other things > > like that.. > > > > Maybe I will try to make bit banged version first. Just when I find all the > subtle details necessary to toggle pins... > > > Take a look at sys/dev/iicbus/iic*_if.m. Those are the two different > > programming interfaces. You of course just need to do one of the two... > > I did. Actually first I must figure how this all contributes to total > picture... I am on my way. I must first know the hardware part, which is not > that easy on the first stage, but I am reading through specs, some examples, > mostly in assembly. I am doing my homework :) > > [skip] > > > > You can take a look at lpbb for a simple example of the bit banging > > interface... sys/dev/ppbus/lpbb.c The other controllers also implement > > iicbus directly.. You can look at the modules/i2c/contollers/*/Makefile > > to see who uses iicbus_if.h to see examples that implement it.. > > > > On the other side - what is sys/dev/pcf directory for? I do not see those > files referenced elsewhere... Other than that, device pcf looks like the best > candidate to work with. I would like to use integrated controller, naturally. Hmmm.. those seem to be orphaned files... the pcf module seems to only use the i386/isa/pcf.c file... After looking at the cvs log for pcf.c: This is not yet ready for public consumption, but it basically works. Nicolas will bring over his ISA-specific fixes soon. and: Null commit: this is just a notification only that this file has been repo-copied over from src/sys/i386/isa/pcf.c which will be removed from the old location as soon as the new stuff here is ready for the masses. The intention is to work up the old pcf(4) driver to become machine independant, so it can be used for any PCF8584-controller I2C bus. So, basicly, that directory is a work in progress... -- John-Mark Gurney Voice: +1 415 225 5579 "All that I will do, has been done, All that I have, has not."