avrdude-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [avrdude-dev] Fwd: avrdude.conf - ftdi-section


From: Joerg Wunsch
Subject: Re: [avrdude-dev] Fwd: avrdude.conf - ftdi-section
Date: Thu, 3 Nov 2011 08:48:40 +0100
User-agent: Mutt/1.5.20 (2009-06-14)

As Jason Hecker wrote:

> I think you are doing it wrong.  Try and copy or use an existing FTDI
> programmer definition in the config file and get AVRDUDE to access the
> FTDI part with the USB VID:PID, not via /dev/ttyUSB as SPI is not a
> serial/RS232 protocol.

Well, I think the avrftdi code should follow the existing -P
conventions.  It seems, the parameter passed by -P is currently not
used at all.  What I'd like to see is the following handling:

If no -P option is given, assume -P usb.  (This might need changes
outside avrftdi, it's possible that the generic code currently passes
the name of the default parallel port device.)

If -P usb is given, proceed using the way that is implemented right
now, except for the -v handling (see below).

If -P usb:<serno> is given, try matching <serno> against the trailing
digits of the serial number.  With one -v option, print any serial
numbers of devices that match VID:PID so the user gets an idea which
serial numbers are available.

I -P <something else> is given, reject <something else> as being
inapprpopriate, telling that this programmer can only be talked to
through direct USB access.

Looking at the code, I'm not exactly sure which parts of this list are
already done and which aren't.  I think, at least the "announce all
serial numbers found" feature is missing.  Given that libftdi handles
that differently than the standard libusb search sequence, I'm fine to
announce the entire list of serial numbers only in the "not matched"
case.  (The standard libusb code would announce each serial number
found when traversing the bus, and stop printing them on a match.)
-- 
cheers, J"org               .-.-.   --... ...--   -.. .  DL8DTL

http://www.sax.de/~joerg/                        NIC: JW11-RIPE
Never trust an operating system you don't have sources for. ;-)



reply via email to

[Prev in Thread] Current Thread [Next in Thread]