Re: [NTLK] Card info utility needed

From: Paul Guyot (pguyot_at_kallisys.net)
Date: Sun Sep 08 2002 - 21:57:23 PDT


On Sun, 8 Sep 2002, Mike O'Brien wrote:
> One of the most popular questions on this list is and has been for many
> years:
> "Will this XYZ brand card work with the ABC driver?" People have gone
> so far
> as to take pictures of the front and back sides of cards that work,
> just so others
> can tell if their cards will work or not. This applies to wired and
> wireless Ethernet
> cards, modem cards, what have you.
>
> What we need is a utility that shows on the Newton screen the Card Info
> section
> of ANY card you plug into it. Type, brand, model, anything the card's
> driver would
> look at. That way, driver writers could say, "The such-and-so fields
> of CardInfo have
> to say this-that-or-the-other in order for this driver to work."
> Remember, different
> brands of wired Ethernet card worked, so long as the Card Info area
> said it was
> a 3C509.

Okay. I think there is a little bit of confusion and a good idea here.

First, there is a specificity of Lantern API (aka Newton Device) that is
usually used for network cards (it provides communication with the system
regarding power management, appletalk, communication with NIE and other
cool services, what is left to developer is card configuration and
send/receive packets, it would be stupid to not use it).

This framework will only load an ethernet driver if (a) the card is an
ethernet card and (b) the product string matches what the driver
registered.

So if the product string doesn't match, the card won't work.

The product string and other information that a generic tool could get are
in fact PCMCIA information. This information is parsed by the system and
you can find many things like kind of card, the voltage it can work in,
etc. But it's not sufficient to know if a driver will work or not. You can
have good assumption that it will provided that the product string is
registered, but you cannot be sure.

Ethernet driver developers will build their driver to register product
strings for card that are known to work. So if you put the card in, the
ethernet slip will open (there is a driver that has no slip, btw).

Now, I wonder if it is interesting to write a tool that will check if a
given driver has registered the product string for a given card because
it's simpler to install the driver and just insert the card.

GetCardInfo was actually written to extend the NE2000 sample driver to
work with more cards. There is vaguely a concept of a project of a
Universal driver where you could tell the driver to try your card (because
there are so many NE2K cards around). GetCardInfo can also be used with a
patch to hack a driver to force it working with a given card. But if the
developer didn't add a product string, it is probably on purpose and he
cannot guarantee that it will work.

BTW, ATA Support doesn't use the product string. It looks if the card
seems to be an ATA card and then starts talking ATA to it.

HTH,

Paul

-- 
NPDS: http://newton.kallisys.net:8080/
Apache: http://www.kallisys.com/
-- 
Read the List FAQ/Etiquette: http://www.newtontalk.net/faq.html
Read the Newton FAQ: http://www.chuma.org/newton/faq/
This is the NewtonTalk mailing list - http://www.newtontalk.net/


This archive was generated by hypermail 2.1.5 : Mon May 26 2003 - 12:59:20 PDT