On Sunday, July 17, 2011 11:00:29 AM Stephen Wille Padnos did opine:

> gene heskett wrote:
> > On Saturday, July 16, 2011 10:46:42 AM andy pugh did opine:
> >> On 16 July 2011 05:39, Farzin Kamangar<farzin.kaman...@gmail.com>  
wrote:
> >>> � � � � � � � �Can you give me some information how can I go ahead
> >>> for EMC? Do I need to write a driver for that? Where is the
> >>> interface data of EMC and PCI hardware?
> >> 
> >> Typically you just use inb() and outb() in a driver.
> >> I wrote one for an ISA card a few weeks ago, and it was fairly easy.
> >> http://www.linuxcnc.org/component/option,com_kunena/Itemid,20/func,vi
> >> ew/ catid,38/id,10910/lang,english/
> > 
> > Isn't there another function, (ioport?) a sort of a locking mechanism
> > that allows the user exclusive access to the hardware, and a
> > correspond release call to be executed when the user is finished with
> > the hardware?
> > 
> > I screwed around with a pci based card with a pile of 8255's in it
> > about 7-8 years ago (before I discovered emc) and had to wrap my
> > stepper motor exercise code inside that pair of calls before it would
> > work.  Or is that pci specific?
> > 
> > My wet ram could be spoiling, its rather old to be without
> > refrigeration. ;-)
> 
> I think you're talking about iopl() or ioperm().  Those are needed for
> your program to gain the privilege of directly accessing IO ports.  This
> is only needed in userspace programs, since kernel modules (like the
> whole kernel) run in protected/privileged mode.
> 
> To actually do the reads/writes, you use inb/outb, inw/outw, inl/outl.
> 
> - Steve
> 
Right Steve.

Cheers, gene
-- 
"There are four boxes to be used in defense of liberty:
 soap, ballot, jury, and ammo. Please use in that order."
-Ed Howdershelt (Author)
Lots of people drink from the wrong bottle sometimes.
                -- Edith Keeler, "The City on the Edge of Forever",
                   stardate unknown

------------------------------------------------------------------------------
AppSumo Presents a FREE Video for the SourceForge Community by Eric 
Ries, the creator of the Lean Startup Methodology on "Lean Startup 
Secrets Revealed." This video shows you how to validate your ideas, 
optimize your ideas and identify your business strategy.
http://p.sf.net/sfu/appsumosfdev2dev
_______________________________________________
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users

Reply via email to