avrdude-dev
[Top][All Lists]
Advanced

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

Re: [avrdude-dev] Adding a new programmer type to AVRDUDE


From: Doug Brown
Subject: Re: [avrdude-dev] Adding a new programmer type to AVRDUDE
Date: Tue, 19 Jan 2010 18:28:10 +1000

Hi Joerg,

Thanks for the reply.

I'll try to take notes anyway so I don't forget what I'm doing -
AVRDUDE is new for me (I'm yet to use it). Should I have some inane
questions, do I just spray them at everyone on avrdude-dev or is there
some other way this is done?

The programmer uses is an HID class device and data in transferred
over interrupt endpoints; libusb-win32 can't hack this (it's v. easy
to use the win32 API tho). I take it that libusb is the way to go for
the *nixes though.

Regards,
Doug

2010/1/18 Joerg Wunsch <address@hidden>
>
> As Doug Brown wrote:
>
> > Is there any documentation or a guide for which functions to implement (&
> > what the functions are required to do) for integrating a new programm in
> > AVRDUDE?
>
> Unfortunately not.  I recently added a "Developers' corner" to the Web
> pages, so if you are about to add a new programmer, please record all
> your steps somehow, so we could eventually take your notes as the base
> for a description there.
>
> > e.g. A USB programmer that has the following features:
> > * Programmable VDD
> >  * Programmable VPP/RESET
> >  * Programmable SPI Clock Rate
>
> That's probably going to be something like a single "set attribute"
> command or such.  You can have a look at the stk500v2.c code to see
> how STK500/STK600 do handle this.
>
> > * Uses interrupt transfers (64 byte) and can send raw SPI In/Out (up to 56
> > bytes) per transaction
>
> The current usb_libusb.c implementation uses only bulk transfers, as
> it basically abstracts a simple datastream (used to be RS-232 data,
> and have only been moved to a USB interface then).
>
> > * Delays requests can also be inserted in the datastream.
>
> That is likely going to be another command only, so it's private to
> your implementation.
>
> > What functions (from struct PROGRAMMER) need to be implemented to
> > allow the programmer to be used (I guess as an AVR prog, EE prog &
> > SPI bridge)?
>
> Virtually everything in your case, I'm afraid.  The policy is that
> everything that has no per-programmer implementation gets replaced by
> a generic function (usually found in avr.c), which essentially
> implements plain old ISP based on the "cmd" method, feeding all the
> ISP bytes in and out manually (as it used to be done with the bitbang
> adapters AVRDUDE has been starting with).
>
> --
> cheers, J"org               .-.-.   --... ...--   -.. .  DL8DTL
>
> http://www.sax.de/~joerg/                        NIC: JW11-RIPE
> Never trust an operating system you don't have sources for. ;-)
>
>
> _______________________________________________
> avrdude-dev mailing list
> address@hidden
> http://lists.nongnu.org/mailman/listinfo/avrdude-dev




reply via email to

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